From 932e0269f5ae14c671f9c2946672a3762fcac041 Mon Sep 17 00:00:00 2001 From: Roy Golan Date: Wed, 17 Nov 2021 10:34:06 +0200 Subject: [PATCH] OCI: vendor dependencies Signed-off-by: Roy Golan --- go.mod | 2 + go.sum | 8 + .../inconshreveable/mousetrap/LICENSE | 13 + .../inconshreveable/mousetrap/README.md | 23 + .../inconshreveable/mousetrap/trap_others.go | 15 + .../inconshreveable/mousetrap/trap_windows.go | 98 + .../mousetrap/trap_windows_1.4.go | 46 + .../oracle/oci-go-sdk/v54/LICENSE.txt | 82 + .../oracle/oci-go-sdk/v54/NOTICE.txt | 1 + .../v54/common/auth/certificate_retriever.go | 261 + .../v54/common/auth/configuration.go | 110 + .../v54/common/auth/dispatcher_modifier.go | 41 + .../v54/common/auth/federation_client.go | 569 + ...nce_principal_delegation_token_provider.go | 83 + .../auth/instance_principal_key_provider.go | 146 + .../oracle/oci-go-sdk/v54/common/auth/jwt.go | 70 + .../auth/resouce_principal_key_provider.go | 231 + .../resource_principal_token_path_provider.go | 138 + .../v54/common/auth/resource_principals_v1.go | 373 + .../oci-go-sdk/v54/common/auth/utils.go | 97 + .../oci-go-sdk/v54/common/circuit_breaker.go | 235 + .../oracle/oci-go-sdk/v54/common/client.go | 630 + .../oracle/oci-go-sdk/v54/common/common.go | 339 + .../oci-go-sdk/v54/common/configuration.go | 659 + .../oracle/oci-go-sdk/v54/common/errors.go | 136 + .../oracle/oci-go-sdk/v54/common/helpers.go | 298 + .../oracle/oci-go-sdk/v54/common/http.go | 1070 ++ .../oci-go-sdk/v54/common/http_signer.go | 270 + .../oracle/oci-go-sdk/v54/common/log.go | 230 + .../oracle/oci-go-sdk/v54/common/regions.go | 173 + .../oracle/oci-go-sdk/v54/common/regions.json | 224 + .../oracle/oci-go-sdk/v54/common/retry.go | 1052 ++ .../oracle/oci-go-sdk/v54/common/version.go | 37 + ...elded_integrity_policy_request_response.go | 83 + ...rg_route_distribution_statement_details.go | 95 + ...g_route_distribution_statements_details.go | 29 + ...istribution_statements_request_response.go | 77 + .../v54/core/add_drg_route_rule_details.go | 63 + .../v54/core/add_drg_route_rules_details.go | 29 + .../add_drg_route_rules_request_response.go | 84 + ...image_shape_compatibility_entry_details.go | 29 + ...pe_compatibility_entry_request_response.go | 80 + .../add_ipv6_vcn_cidr_request_response.go | 87 + ...k_security_group_security_rules_details.go | 29 + ...y_group_security_rules_request_response.go | 77 + .../add_public_ip_pool_capacity_details.go | 33 + ...ublic_ip_pool_capacity_request_response.go | 87 + .../v54/core/add_security_rule_details.go | 172 + .../v54/core/add_vcn_cidr_details.go | 29 + .../v54/core/add_vcn_cidr_request_response.go | 90 + ...d_network_security_group_security_rules.go | 29 + .../advertise_byoip_range_request_response.go | 71 + .../v54/core/allowed_ike_ip_sec_parameters.go | 33 + .../v54/core/allowed_phase_one_parameters.go | 35 + .../v54/core/allowed_phase_two_parameters.go | 35 + ...ilan_bm_launch_instance_platform_config.go | 96 + .../v54/core/amd_milan_bm_platform_config.go | 96 + ...rome_bm_launch_instance_platform_config.go | 65 + .../v54/core/amd_rome_bm_platform_config.go | 65 + .../amd_vm_launch_instance_platform_config.go | 65 + .../v54/core/amd_vm_platform_config.go | 65 + .../v54/core/app_catalog_listing.go | 52 + .../app_catalog_listing_resource_version.go | 89 + ...log_listing_resource_version_agreements.go | 45 + ...atalog_listing_resource_version_summary.go | 39 + .../v54/core/app_catalog_listing_summary.go | 39 + .../v54/core/app_catalog_subscription.go | 52 + .../core/app_catalog_subscription_summary.go | 52 + .../v54/core/attach_boot_volume_details.go | 40 + .../attach_boot_volume_request_response.go | 84 + .../core/attach_emulated_volume_details.go | 93 + .../v54/core/attach_i_scsi_volume_details.go | 100 + .../attach_instance_pool_instance_details.go | 29 + ...instance_pool_instance_request_response.go | 94 + .../v54/core/attach_load_balancer_details.go | 40 + .../attach_load_balancer_request_response.go | 92 + .../attach_paravirtualized_volume_details.go | 96 + ...ttach_service_determined_volume_details.go | 93 + .../attach_service_id_request_response.go | 82 + .../v54/core/attach_vnic_details.go | 41 + .../v54/core/attach_vnic_request_response.go | 84 + .../v54/core/attach_volume_details.go | 142 + .../core/attach_volume_request_response.go | 84 + .../oci-go-sdk/v54/core/bgp_session_info.go | 129 + .../v54/core/block_volume_replica.go | 109 + .../v54/core/block_volume_replica_details.go | 34 + .../v54/core/block_volume_replica_info.go | 37 + ...lean_image_capability_schema_descriptor.go | 51 + .../oracle/oci-go-sdk/v54/core/boot_volume.go | 222 + .../v54/core/boot_volume_attachment.go | 89 + .../oci-go-sdk/v54/core/boot_volume_backup.go | 180 + .../v54/core/boot_volume_kms_key.go | 29 + .../v54/core/boot_volume_replica.go | 112 + .../v54/core/boot_volume_replica_details.go | 34 + .../v54/core/boot_volume_replica_info.go | 37 + .../v54/core/boot_volume_source_details.go | 74 + ..._source_from_boot_volume_backup_details.go | 44 + ..._volume_source_from_boot_volume_details.go | 44 + ...source_from_boot_volume_replica_details.go | 46 + ...virtual_circuit_public_prefixes_details.go | 29 + ...ircuit_public_prefixes_request_response.go | 70 + ...virtual_circuit_public_prefixes_details.go | 29 + ...ircuit_public_prefixes_request_response.go | 70 + .../core/byoip_allocated_range_collection.go | 29 + .../v54/core/byoip_allocated_range_summary.go | 32 + .../oracle/oci-go-sdk/v54/core/byoip_range.go | 141 + .../v54/core/byoip_range_collection.go | 29 + .../v54/core/byoip_range_summary.go | 59 + .../capacity_reservation_instance_summary.go | 45 + .../core/capture_console_history_details.go | 43 + ...apture_console_history_request_response.go | 84 + ..._boot_volume_backup_compartment_details.go | 29 + ...ume_backup_compartment_request_response.go | 77 + .../change_boot_volume_compartment_details.go | 29 + ...oot_volume_compartment_request_response.go | 77 + .../change_byoip_range_compartment_details.go | 29 + ...yoip_range_compartment_request_response.go | 81 + ...nge_cluster_network_compartment_details.go | 30 + ...er_network_compartment_request_response.go | 89 + ...apacity_reservation_compartment_details.go | 30 + ...eservation_compartment_request_response.go | 90 + ...e_capability_schema_compartment_details.go | 30 + ...ity_schema_compartment_request_response.go | 86 + .../core/change_cpe_compartment_details.go | 30 + ...change_cpe_compartment_request_response.go | 84 + ...hange_cross_connect_compartment_details.go | 30 + ...ss_connect_compartment_request_response.go | 84 + ...cross_connect_group_compartment_details.go | 30 + ...nect_group_compartment_request_response.go | 84 + ...e_dedicated_vm_host_compartment_details.go | 30 + ...ed_vm_host_compartment_request_response.go | 93 + ...change_dhcp_options_compartment_details.go | 30 + ...cp_options_compartment_request_response.go | 84 + .../core/change_drg_compartment_details.go | 30 + ...change_drg_compartment_request_response.go | 88 + ...connection_compartment_request_response.go | 84 + .../core/change_image_compartment_details.go | 29 + ...ange_image_compartment_request_response.go | 89 + .../change_instance_compartment_details.go | 29 + ...e_instance_compartment_request_response.go | 93 + ...tance_configuration_compartment_details.go | 30 + ...figuration_compartment_request_response.go | 89 + ...hange_instance_pool_compartment_details.go | 30 + ...tance_pool_compartment_request_response.go | 89 + ...ge_internet_gateway_compartment_details.go | 30 + ...et_gateway_compartment_request_response.go | 84 + ...e_ip_sec_connection_compartment_details.go | 30 + ...cal_peering_gateway_compartment_details.go | 30 + ...ng_gateway_compartment_request_response.go | 84 + .../change_nat_gateway_compartment_details.go | 29 + ...at_gateway_compartment_request_response.go | 84 + ...work_security_group_compartment_details.go | 30 + ...rity_group_compartment_request_response.go | 84 + .../change_public_ip_compartment_details.go | 30 + ..._public_ip_compartment_request_response.go | 84 + ...ange_public_ip_pool_compartment_details.go | 29 + ...ic_ip_pool_compartment_request_response.go | 81 + ..._peering_connection_compartment_details.go | 30 + ...connection_compartment_request_response.go | 84 + .../change_route_table_compartment_details.go | 30 + ...oute_table_compartment_request_response.go | 84 + ...hange_security_list_compartment_details.go | 30 + ...urity_list_compartment_request_response.go | 84 + ...nge_service_gateway_compartment_details.go | 30 + ...ce_gateway_compartment_request_response.go | 84 + .../core/change_subnet_compartment_details.go | 30 + ...nge_subnet_compartment_request_response.go | 88 + .../core/change_vcn_compartment_details.go | 30 + ...change_vcn_compartment_request_response.go | 88 + ...nge_virtual_circuit_compartment_details.go | 30 + ...al_circuit_compartment_request_response.go | 84 + .../core/change_vlan_compartment_details.go | 29 + ...hange_vlan_compartment_request_response.go | 90 + ...hange_volume_backup_compartment_details.go | 29 + ...ume_backup_compartment_request_response.go | 77 + .../core/change_volume_compartment_details.go | 29 + ...nge_volume_compartment_request_response.go | 77 + ...volume_group_backup_compartment_details.go | 29 + ...oup_backup_compartment_request_response.go | 77 + ...change_volume_group_compartment_details.go | 29 + ...lume_group_compartment_request_response.go | 77 + .../oci-go-sdk/v54/core/cluster_network.go | 100 + ...network_placement_configuration_details.go | 37 + .../v54/core/cluster_network_summary.go | 96 + .../v54/core/compute_capacity_reservation.go | 114 + ...city_reservation_instance_shape_summary.go | 32 + .../compute_capacity_reservation_summary.go | 72 + .../compute_global_image_capability_schema.go | 54 + ..._global_image_capability_schema_summary.go | 54 + ..._global_image_capability_schema_version.go | 84 + ...image_capability_schema_version_summary.go | 40 + .../core/compute_image_capability_schema.go | 119 + ...compute_image_capability_schema_summary.go | 111 + .../v54/core/compute_instance_details.go | 46 + .../connect_local_peering_gateways_details.go | 29 + ...local_peering_gateways_request_response.go | 74 + ...nect_remote_peering_connections_details.go | 33 + ...te_peering_connections_request_response.go | 74 + .../oci-go-sdk/v54/core/console_history.go | 91 + .../core/copy_boot_volume_backup_details.go | 43 + ...opy_boot_volume_backup_request_response.go | 97 + .../v54/core/copy_volume_backup_details.go | 44 + .../copy_volume_backup_request_response.go | 97 + .../core/copy_volume_group_backup_details.go | 44 + ...py_volume_group_backup_request_response.go | 87 + .../v54/core/core_blockstorage_client.go | 3393 ++++ .../v54/core/core_compute_client.go | 4887 ++++++ .../v54/core/core_computemanagement_client.go | 1925 +++ .../v54/core/core_virtualnetwork_client.go | 13456 ++++++++++++++++ .../oracle/oci-go-sdk/v54/core/cpe.go | 74 + .../v54/core/cpe_device_config_answer.go | 35 + .../v54/core/cpe_device_config_question.go | 38 + .../oci-go-sdk/v54/core/cpe_device_info.go | 32 + .../v54/core/cpe_device_shape_detail.go | 48 + .../v54/core/cpe_device_shape_summary.go | 33 + ...create_app_catalog_subscription_details.go | 48 + ...p_catalog_subscription_request_response.go | 84 + .../core/create_boot_volume_backup_details.go | 69 + ...ate_boot_volume_backup_request_response.go | 84 + .../v54/core/create_boot_volume_details.go | 136 + .../create_boot_volume_request_response.go | 84 + .../v54/core/create_byoip_range_details.go | 47 + .../create_byoip_range_request_response.go | 84 + .../core/create_cluster_network_details.go | 50 + ...e_cluster_network_instance_pool_details.go | 47 + ...create_cluster_network_request_response.go | 88 + ...te_compute_capacity_reservation_details.go | 56 + ...e_capacity_reservation_request_response.go | 92 + ...compute_image_capability_schema_details.go | 98 + ...mage_capability_schema_request_response.go | 84 + .../oci-go-sdk/v54/core/create_cpe_details.go | 59 + .../v54/core/create_cpe_request_response.go | 84 + .../v54/core/create_cross_connect_details.go | 74 + .../create_cross_connect_group_details.go | 49 + ...te_cross_connect_group_request_response.go | 84 + .../create_cross_connect_request_response.go | 84 + .../core/create_dedicated_vm_host_details.go | 60 + ...eate_dedicated_vm_host_request_response.go | 88 + .../v54/core/create_dhcp_details.go | 123 + .../create_dhcp_options_request_response.go | 84 + .../v54/core/create_drg_attachment_details.go | 109 + .../create_drg_attachment_request_response.go | 84 + .../oci-go-sdk/v54/core/create_drg_details.go | 43 + .../v54/core/create_drg_request_response.go | 84 + .../create_drg_route_distribution_details.go | 67 + ...drg_route_distribution_request_response.go | 84 + .../core/create_drg_route_table_details.go | 51 + ...create_drg_route_table_request_response.go | 84 + ...ate_i_p_sec_connection_request_response.go | 84 + .../v54/core/create_image_details.go | 127 + .../v54/core/create_image_request_response.go | 88 + .../create_instance_configuration_base.go | 139 + .../create_instance_configuration_details.go | 117 + ...nce_configuration_from_instance_details.go | 83 + ...instance_configuration_request_response.go | 84 + ...ate_instance_console_connection_details.go | 43 + ...nce_console_connection_request_response.go | 84 + .../v54/core/create_instance_pool_details.go | 60 + ...ce_pool_placement_configuration_details.go | 48 + .../create_instance_pool_request_response.go | 84 + .../core/create_internet_gateway_details.go | 49 + ...reate_internet_gateway_request_response.go | 84 + .../core/create_ip_sec_connection_details.go | 105 + ...create_ip_sec_connection_tunnel_details.go | 154 + ...reate_ip_sec_tunnel_bgp_session_details.go | 74 + ...ip_sec_tunnel_encryption_domain_details.go | 34 + .../v54/core/create_ipv6_details.go | 51 + .../v54/core/create_ipv6_request_response.go | 84 + .../create_local_peering_gateway_details.go | 54 + ..._local_peering_gateway_request_response.go | 84 + .../oci-go-sdk/v54/core/create_macsec_key.go | 34 + .../v54/core/create_macsec_properties.go | 34 + .../v54/core/create_nat_gateway_details.go | 54 + .../create_nat_gateway_request_response.go | 84 + .../create_network_security_group_details.go | 48 + ...network_security_group_request_response.go | 84 + .../v54/core/create_private_ip_details.go | 66 + .../create_private_ip_request_response.go | 84 + .../v54/core/create_public_ip_details.go | 83 + .../v54/core/create_public_ip_pool_details.go | 43 + .../create_public_ip_pool_request_response.go | 84 + .../core/create_public_ip_request_response.go | 84 + ...reate_remote_peering_connection_details.go | 46 + ...ote_peering_connection_request_response.go | 84 + .../v54/core/create_route_table_details.go | 49 + .../create_route_table_request_response.go | 84 + .../v54/core/create_security_list_details.go | 52 + .../create_security_list_request_response.go | 84 + .../core/create_service_gateway_details.go | 64 + ...create_service_gateway_request_response.go | 81 + .../v54/core/create_subnet_details.go | 119 + .../core/create_subnet_request_response.go | 84 + .../oci-go-sdk/v54/core/create_vcn_details.go | 74 + .../v54/core/create_vcn_request_response.go | 84 + .../core/create_virtual_circuit_details.go | 159 + ...e_virtual_circuit_public_prefix_details.go | 30 + ...create_virtual_circuit_request_response.go | 84 + .../v54/core/create_vlan_details.go | 77 + .../v54/core/create_vlan_request_response.go | 84 + .../v54/core/create_vnic_details.go | 141 + .../v54/core/create_volume_backup_details.go | 69 + ...volume_backup_policy_assignment_details.go | 32 + ...ckup_policy_assignment_request_response.go | 77 + .../create_volume_backup_policy_details.go | 55 + ...e_volume_backup_policy_request_response.go | 84 + .../create_volume_backup_request_response.go | 84 + .../v54/core/create_volume_details.go | 153 + .../create_volume_group_backup_details.go | 74 + ...te_volume_group_backup_request_response.go | 84 + .../v54/core/create_volume_group_details.go | 95 + .../create_volume_group_request_response.go | 84 + .../core/create_volume_request_response.go | 84 + .../oci-go-sdk/v54/core/cross_connect.go | 115 + .../v54/core/cross_connect_group.go | 98 + .../v54/core/cross_connect_location.go | 33 + .../v54/core/cross_connect_mapping.go | 105 + .../v54/core/cross_connect_mapping_details.go | 136 + ...ross_connect_mapping_details_collection.go | 29 + .../core/cross_connect_port_speed_shape.go | 34 + .../v54/core/cross_connect_status.go | 138 + .../oci-go-sdk/v54/core/dedicated_vm_host.go | 113 + ...edicated_vm_host_instance_shape_summary.go | 32 + .../dedicated_vm_host_instance_summary.go | 43 + .../core/dedicated_vm_host_shape_summary.go | 33 + .../v54/core/dedicated_vm_host_summary.go | 101 + .../v54/core/default_drg_route_tables.go | 46 + .../v54/core/default_phase_one_parameters.go | 35 + .../v54/core/default_phase_two_parameters.go | 35 + ...p_catalog_subscription_request_response.go | 77 + ...ete_boot_volume_backup_request_response.go | 76 + ...te_boot_volume_kms_key_request_response.go | 76 + .../delete_boot_volume_request_response.go | 76 + .../delete_byoip_range_request_response.go | 80 + ...e_capacity_reservation_request_response.go | 80 + ...mage_capability_schema_request_response.go | 76 + ...delete_console_history_request_response.go | 76 + .../v54/core/delete_cpe_request_response.go | 76 + ...te_cross_connect_group_request_response.go | 76 + .../delete_cross_connect_request_response.go | 76 + ...lete_dedicated_vm_host_request_response.go | 75 + .../delete_dhcp_options_request_response.go | 76 + .../delete_drg_attachment_request_response.go | 76 + .../v54/core/delete_drg_request_response.go | 76 + ...drg_route_distribution_request_response.go | 76 + ...delete_drg_route_table_request_response.go | 76 + ...ete_i_p_sec_connection_request_response.go | 76 + .../v54/core/delete_image_request_response.go | 76 + ...instance_configuration_request_response.go | 76 + ...nce_console_connection_request_response.go | 76 + ...elete_internet_gateway_request_response.go | 76 + .../v54/core/delete_ipv6_request_response.go | 76 + ..._local_peering_gateway_request_response.go | 76 + .../delete_nat_gateway_request_response.go | 76 + ...network_security_group_request_response.go | 76 + .../delete_private_ip_request_response.go | 76 + .../delete_public_ip_pool_request_response.go | 76 + .../core/delete_public_ip_request_response.go | 76 + ...ote_peering_connection_request_response.go | 76 + .../delete_route_table_request_response.go | 76 + .../delete_security_list_request_response.go | 76 + ...delete_service_gateway_request_response.go | 76 + .../core/delete_subnet_request_response.go | 76 + .../v54/core/delete_vcn_request_response.go | 76 + ...e_virtual_circuit_public_prefix_details.go | 29 + ...delete_virtual_circuit_request_response.go | 76 + .../v54/core/delete_vlan_request_response.go | 76 + ...ckup_policy_assignment_request_response.go | 76 + ...e_volume_backup_policy_request_response.go | 76 + .../delete_volume_backup_request_response.go | 76 + ...te_volume_group_backup_request_response.go | 76 + .../delete_volume_group_request_response.go | 76 + .../delete_volume_kms_key_request_response.go | 76 + .../core/delete_volume_request_response.go | 76 + .../detach_boot_volume_request_response.go | 76 + .../detach_instance_pool_instance_details.go | 38 + ...instance_pool_instance_request_response.go | 85 + .../v54/core/detach_load_balancer_details.go | 32 + .../detach_load_balancer_request_response.go | 92 + .../detach_service_id_request_response.go | 82 + .../v54/core/detach_vnic_request_response.go | 76 + .../core/detach_volume_request_response.go | 76 + .../oracle/oci-go-sdk/v54/core/device.go | 32 + .../oci-go-sdk/v54/core/dhcp_dns_option.go | 87 + .../oracle/oci-go-sdk/v54/core/dhcp_option.go | 74 + .../oci-go-sdk/v54/core/dhcp_options.go | 179 + .../v54/core/dhcp_search_domain_option.go | 55 + .../oracle/oci-go-sdk/v54/core/dpd_config.go | 55 + .../oracle/oci-go-sdk/v54/core/drg.go | 92 + .../oci-go-sdk/v54/core/drg_attachment.go | 175 + ...d_drg_route_distribution_match_criteria.go | 44 + .../v54/core/drg_attachment_info.go | 29 + .../drg_attachment_network_create_details.go | 97 + .../core/drg_attachment_network_details.go | 115 + .../drg_attachment_network_update_details.go | 87 + ...e_drg_route_distribution_match_criteria.go | 73 + .../v54/core/drg_redundancy_status.go | 68 + .../v54/core/drg_route_distribution.go | 121 + .../drg_route_distribution_match_criteria.go | 94 + .../core/drg_route_distribution_statement.go | 103 + .../oci-go-sdk/v54/core/drg_route_rule.go | 145 + .../oci-go-sdk/v54/core/drg_route_table.go | 102 + .../v54/core/egress_security_rule.go | 90 + .../v54/core/emulated_volume_attachment.go | 160 + .../v54/core/encryption_domain_config.go | 32 + .../v54/core/encryption_in_transit_type.go | 37 + ...num_integer_image_capability_descriptor.go | 54 + ...ring_image_capability_schema_descriptor.go | 54 + .../v54/core/export_image_details.go | 122 + .../v54/core/export_image_request_response.go | 96 + ..._image_via_object_storage_tuple_details.go | 65 + ...rt_image_via_object_storage_uri_details.go | 62 + .../v54/core/fast_connect_provider_service.go | 238 + .../core/fast_connect_provider_service_key.go | 42 + ...et_all_drg_attachments_request_response.go | 125 + ...ike_i_p_sec_parameters_request_response.go | 71 + ...log_listing_agreements_request_response.go | 80 + ...et_app_catalog_listing_request_response.go | 77 + ...sting_resource_version_request_response.go | 80 + ...t_block_volume_replica_request_response.go | 77 + ...boot_volume_attachment_request_response.go | 77 + ...get_boot_volume_backup_request_response.go | 77 + ...et_boot_volume_kms_key_request_response.go | 82 + ...et_boot_volume_replica_request_response.go | 77 + .../core/get_boot_volume_request_response.go | 77 + .../core/get_byoip_range_request_response.go | 77 + .../get_cluster_network_request_response.go | 77 + ...e_capacity_reservation_request_response.go | 77 + ...mage_capability_schema_request_response.go | 77 + ...ability_schema_version_request_response.go | 80 + ...mage_capability_schema_request_response.go | 80 + ...onsole_history_content_request_response.go | 83 + .../get_console_history_request_response.go | 77 + ..._device_config_content_request_response.go | 75 + .../get_cpe_device_shape_request_response.go | 74 + .../v54/core/get_cpe_request_response.go | 77 + ...et_cross_connect_group_request_response.go | 77 + ...ct_letter_of_authority_request_response.go | 74 + .../get_cross_connect_request_response.go | 77 + ...t_cross_connect_status_request_response.go | 74 + .../get_dedicated_vm_host_request_response.go | 77 + .../core/get_dhcp_options_request_response.go | 77 + .../get_drg_attachment_request_response.go | 77 + ..._drg_redundancy_status_request_response.go | 74 + .../v54/core/get_drg_request_response.go | 77 + ...drg_route_distribution_request_response.go | 77 + .../get_drg_route_table_request_response.go | 77 + ...t_provider_service_key_request_response.go | 80 + ...nnect_provider_service_request_response.go | 74 + ...nnection_device_config_request_response.go | 77 + ...nnection_device_status_request_response.go | 77 + ...get_i_p_sec_connection_request_response.go | 77 + ...onnection_tunnel_error_request_response.go | 77 + ..._sec_connection_tunnel_request_response.go | 80 + ...n_tunnel_shared_secret_request_response.go | 80 + .../v54/core/get_image_request_response.go | 77 + ...pe_compatibility_entry_request_response.go | 77 + ...instance_configuration_request_response.go | 77 + ...nce_console_connection_request_response.go | 74 + ...instance_pool_instance_request_response.go | 80 + ...ad_balancer_attachment_request_response.go | 77 + .../get_instance_pool_request_response.go | 77 + .../v54/core/get_instance_request_response.go | 77 + .../get_internet_gateway_request_response.go | 77 + ..._device_config_content_request_response.go | 75 + .../v54/core/get_ipv6_request_response.go | 77 + ..._local_peering_gateway_request_response.go | 77 + ...t_measured_boot_report_request_response.go | 77 + .../core/get_nat_gateway_request_response.go | 77 + ...network_security_group_request_response.go | 77 + ...et_networking_topology_request_response.go | 125 + .../core/get_private_ip_request_response.go | 77 + .../get_public_ip_by_ip_address_details.go | 30 + ...ublic_ip_by_ip_address_request_response.go | 77 + .../get_public_ip_by_private_ip_id_details.go | 29 + ...ic_ip_by_private_ip_id_request_response.go | 77 + .../get_public_ip_pool_request_response.go | 77 + .../core/get_public_ip_request_response.go | 77 + ...ote_peering_connection_request_response.go | 77 + .../core/get_route_table_request_response.go | 77 + .../get_security_list_request_response.go | 77 + .../get_service_gateway_request_response.go | 77 + .../v54/core/get_service_request_response.go | 77 + .../v54/core/get_subnet_request_response.go | 77 + .../get_subnet_topology_request_response.go | 128 + ..._device_config_content_request_response.go | 78 + ...nnel_cpe_device_config_request_response.go | 80 + .../get_upgrade_status_request_response.go | 74 + ...s_resolver_association_request_response.go | 77 + .../v54/core/get_vcn_request_response.go | 77 + .../core/get_vcn_topology_request_response.go | 128 + .../get_virtual_circuit_request_response.go | 77 + .../v54/core/get_vlan_request_response.go | 77 + .../get_vnic_attachment_request_response.go | 77 + .../v54/core/get_vnic_request_response.go | 77 + .../get_volume_attachment_request_response.go | 77 + ...olicy_asset_assignment_request_response.go | 90 + ...ckup_policy_assignment_request_response.go | 77 + ...t_volume_backup_policy_request_response.go | 77 + .../get_volume_backup_request_response.go | 77 + ...et_volume_group_backup_request_response.go | 77 + .../core/get_volume_group_request_response.go | 77 + .../get_volume_kms_key_request_response.go | 82 + .../v54/core/get_volume_request_response.go | 77 + ...ce_initial_credentials_request_response.go | 74 + .../v54/core/i_scsi_volume_attachment.go | 190 + .../oci-go-sdk/v54/core/icmp_options.go | 40 + .../oracle/oci-go-sdk/v54/core/image.go | 180 + .../image_capability_schema_descriptor.go | 105 + .../v54/core/image_memory_constraints.go | 32 + .../v54/core/image_ocpu_constraints.go | 32 + .../core/image_shape_compatibility_entry.go | 36 + .../core/image_shape_compatibility_summary.go | 36 + .../v54/core/image_source_details.go | 121 + ...source_via_object_storage_tuple_details.go | 73 + ...e_source_via_object_storage_uri_details.go | 67 + .../v54/core/ingress_security_rule.go | 89 + .../oracle/oci-go-sdk/v54/core/instance.go | 342 + .../core/instance_action_request_response.go | 123 + .../v54/core/instance_agent_config.go | 60 + .../v54/core/instance_agent_features.go | 32 + .../instance_agent_plugin_config_details.go | 60 + .../v54/core/instance_availability_config.go | 60 + .../v54/core/instance_configuration.go | 109 + ...ilan_bm_launch_instance_platform_config.go | 96 + ...rome_bm_launch_instance_platform_config.go | 65 + ..._amd_vm_launch_instance_platform_config.go | 65 + ...tance_configuration_attach_vnic_details.go | 38 + ...nce_configuration_attach_volume_details.go | 114 + ...tance_configuration_availability_config.go | 55 + ...ance_configuration_block_volume_details.go | 63 + ...tance_configuration_create_vnic_details.go | 70 + ...nce_configuration_create_volume_details.go | 121 + ...instance_configuration_instance_details.go | 66 + ...instance_configuration_instance_options.go | 31 + ...e_configuration_instance_source_details.go | 70 + ...instance_source_via_boot_volume_details.go | 44 + ...ation_instance_source_via_image_details.go | 48 + ...lake_bm_launch_instance_platform_config.go | 65 + ...ntel_vm_launch_instance_platform_config.go | 65 + ...nfiguration_iscsi_attach_volume_details.go | 80 + ...on_launch_instance_agent_config_details.go | 63 + ...e_configuration_launch_instance_details.go | 328 + ...uration_launch_instance_platform_config.go | 146 + ...on_launch_instance_shape_config_details.go | 71 + .../instance_configuration_launch_options.go | 174 + ...n_paravirtualized_attach_volume_details.go | 80 + .../core/instance_configuration_summary.go | 50 + ...nce_configuration_volume_source_details.go | 70 + ...olume_source_from_volume_backup_details.go | 44 + ...ation_volume_source_from_volume_details.go | 44 + .../v54/core/instance_console_connection.go | 92 + .../v54/core/instance_credentials.go | 32 + .../oci-go-sdk/v54/core/instance_options.go | 31 + .../oci-go-sdk/v54/core/instance_pool.go | 104 + .../v54/core/instance_pool_instance.go | 95 + ...nce_pool_instance_load_balancer_backend.go | 65 + .../instance_pool_load_balancer_attachment.go | 76 + .../instance_pool_placement_configuration.go | 48 + ...ce_pool_placement_secondary_vnic_subnet.go | 33 + .../v54/core/instance_pool_summary.go | 97 + .../v54/core/instance_reservation_config.go | 44 + .../instance_reservation_config_details.go | 47 + ...stance_reservation_shape_config_details.go | 39 + .../v54/core/instance_shape_config.go | 93 + .../v54/core/instance_source_details.go | 70 + ...instance_source_via_boot_volume_details.go | 44 + .../core/instance_source_via_image_details.go | 50 + .../oci-go-sdk/v54/core/instance_summary.go | 63 + ...lake_bm_launch_instance_platform_config.go | 65 + .../core/intel_skylake_bm_platform_config.go | 65 + ...ntel_vm_launch_instance_platform_config.go | 65 + .../v54/core/intel_vm_platform_config.go | 65 + .../oci-go-sdk/v54/core/internet_gateway.go | 92 + .../oci-go-sdk/v54/core/ip_sec_connection.go | 153 + .../core/ip_sec_connection_device_config.go | 40 + .../core/ip_sec_connection_device_status.go | 40 + .../v54/core/ip_sec_connection_tunnel.go | 259 + .../ip_sec_connection_tunnel_error_details.go | 44 + .../ip_sec_connection_tunnel_shared_secret.go | 29 + ...c_tunnel_drg_attachment_network_details.go | 52 + .../oracle/oci-go-sdk/v54/core/ipv6.go | 98 + .../launch_instance_agent_config_details.go | 63 + ...ch_instance_availability_config_details.go | 61 + ...instance_configuration_request_response.go | 91 + .../v54/core/launch_instance_details.go | 285 + .../core/launch_instance_platform_config.go | 146 + .../core/launch_instance_request_response.go | 88 + .../launch_instance_shape_config_details.go | 70 + .../oci-go-sdk/v54/core/launch_options.go | 174 + .../v54/core/letter_of_authority.go | 72 + ...ons_for_remote_peering_request_response.go | 71 + ...ting_resource_versions_request_response.go | 117 + ...t_app_catalog_listings_request_response.go | 123 + ..._catalog_subscriptions_request_response.go | 152 + ..._block_volume_replicas_request_response.go | 159 + ...oot_volume_attachments_request_response.go | 100 + ...st_boot_volume_backups_request_response.go | 162 + ...t_boot_volume_replicas_request_response.go | 159 + .../list_boot_volumes_request_response.go | 97 + ...byoip_allocated_ranges_request_response.go | 90 + .../list_byoip_ranges_request_response.go | 155 + ...ster_network_instances_request_response.go | 155 + .../list_cluster_networks_request_response.go | 156 + ...vation_instance_shapes_request_response.go | 156 + ..._reservation_instances_request_response.go | 156 + ..._capacity_reservations_request_response.go | 159 + ...bility_schema_versions_request_response.go | 152 + ...age_capability_schemas_request_response.go | 152 + ...age_capability_schemas_request_response.go | 155 + ...list_console_histories_request_response.go | 160 + ...list_cpe_device_shapes_request_response.go | 87 + .../v54/core/list_cpes_request_response.go | 90 + ...t_cross_connect_groups_request_response.go | 156 + ...ross_connect_locations_request_response.go | 90 + ...cross_connect_mappings_request_response.go | 74 + .../list_cross_connects_request_response.go | 159 + ...nect_port_speed_shapes_request_response.go | 90 + ...m_host_instance_shapes_request_response.go | 97 + ...ated_vm_host_instances_request_response.go | 156 + ...dicated_vm_host_shapes_request_response.go | 97 + ...ist_dedicated_vm_hosts_request_response.go | 199 + .../list_dhcp_options_request_response.go | 159 + .../list_drg_attachments_request_response.go | 200 + ...istribution_statements_request_response.go | 141 + ...rg_route_distributions_request_response.go | 156 + .../list_drg_route_rules_request_response.go | 117 + .../list_drg_route_tables_request_response.go | 159 + .../v54/core/list_drgs_request_response.go | 90 + ...nect_provider_services_request_response.go | 90 + ...rcuit_bandwidth_shapes_request_response.go | 90 + ...nnection_tunnel_routes_request_response.go | 101 + ..._security_associations_request_response.go | 96 + ...sec_connection_tunnels_request_response.go | 90 + ...st_i_p_sec_connections_request_response.go | 96 + ..._compatibility_entries_request_response.go | 90 + .../v54/core/list_images_request_response.go | 167 + ...nstance_configurations_request_response.go | 149 + ...ce_console_connections_request_response.go | 93 + .../list_instance_devices_request_response.go | 155 + ...nstance_pool_instances_request_response.go | 155 + .../list_instance_pools_request_response.go | 156 + .../core/list_instances_request_response.go | 163 + ...list_internet_gateways_request_response.go | 159 + .../v54/core/list_ipv6s_request_response.go | 97 + ...local_peering_gateways_request_response.go | 93 + .../list_nat_gateways_request_response.go | 159 + ...y_group_security_rules_request_response.go | 168 + ...k_security_group_vnics_request_response.go | 141 + ...etwork_security_groups_request_response.go | 162 + .../core/list_private_ips_request_response.go | 100 + .../list_public_ip_pools_request_response.go | 155 + .../core/list_public_ips_request_response.go | 156 + ...te_peering_connections_request_response.go | 93 + .../list_route_tables_request_response.go | 159 + .../list_security_lists_request_response.go | 159 + .../list_service_gateways_request_response.go | 156 + .../core/list_services_request_response.go | 87 + .../v54/core/list_shapes_request_response.go | 97 + .../v54/core/list_subnets_request_response.go | 159 + .../v54/core/list_vcns_request_response.go | 156 + ...rcuit_bandwidth_shapes_request_response.go | 90 + ...ircuit_public_prefixes_request_response.go | 79 + .../list_virtual_circuits_request_response.go | 156 + .../v54/core/list_vlans_request_response.go | 159 + .../list_vnic_attachments_request_response.go | 100 + ...ist_volume_attachments_request_response.go | 100 + ...volume_backup_policies_request_response.go | 91 + .../list_volume_backups_request_response.go | 162 + ...t_volume_group_backups_request_response.go | 155 + .../list_volume_groups_request_response.go | 160 + .../v54/core/list_volumes_request_response.go | 163 + .../v54/core/local_peering_gateway.go | 152 + .../v54/core/macsec_encryption_cipher.go | 41 + .../oracle/oci-go-sdk/v54/core/macsec_key.go | 38 + .../oci-go-sdk/v54/core/macsec_properties.go | 34 + .../oci-go-sdk/v54/core/macsec_state.go | 37 + .../v54/core/measured_boot_entry.go | 36 + .../v54/core/measured_boot_report.go | 31 + .../core/measured_boot_report_measurements.go | 32 + .../v54/core/modify_vcn_cidr_details.go | 32 + .../core/modify_vcn_cidr_request_response.go | 90 + .../oci-go-sdk/v54/core/multipath_device.go | 39 + .../oracle/oci-go-sdk/v54/core/nat_gateway.go | 104 + .../v54/core/network_security_group.go | 110 + .../v54/core/network_security_group_vnic.go | 38 + .../v54/core/networking_topology.go | 101 + .../core/paravirtualized_volume_attachment.go | 160 + .../core/peer_region_for_remote_peering.go | 31 + .../v54/core/phase_one_config_details.go | 122 + .../v54/core/phase_two_config_details.go | 129 + .../oci-go-sdk/v54/core/platform_config.go | 141 + .../oracle/oci-go-sdk/v54/core/port_range.go | 33 + .../preemptible_instance_config_details.go | 52 + .../oci-go-sdk/v54/core/preemption_action.go | 87 + .../oracle/oci-go-sdk/v54/core/private_ip.go | 122 + .../oracle/oci-go-sdk/v54/core/public_ip.go | 217 + .../oci-go-sdk/v54/core/public_ip_pool.go | 85 + .../v54/core/public_ip_pool_collection.go | 29 + .../v54/core/public_ip_pool_summary.go | 53 + .../v54/core/remote_peering_connection.go | 138 + ...nnection_drg_attachment_network_details.go | 49 + ...g_route_distribution_statements_details.go | 29 + ...istribution_statements_request_response.go | 74 + .../core/remove_drg_route_rules_details.go | 29 + ...remove_drg_route_rules_request_response.go | 74 + ...drg_route_distribution_request_response.go | 82 + ...pe_compatibility_entry_request_response.go | 74 + ...drg_route_distribution_request_response.go | 82 + ...k_security_group_security_rules_details.go | 29 + ...y_group_security_rules_request_response.go | 75 + .../remove_public_ip_pool_capacity_details.go | 30 + ...ublic_ip_pool_capacity_request_response.go | 87 + .../v54/core/remove_vcn_cidr_details.go | 29 + .../core/remove_vcn_cidr_request_response.go | 90 + .../reset_instance_pool_request_response.go | 89 + .../oracle/oci-go-sdk/v54/core/route_rule.go | 86 + .../oracle/oci-go-sdk/v54/core/route_table.go | 91 + .../oci-go-sdk/v54/core/security_list.go | 103 + .../oci-go-sdk/v54/core/security_rule.go | 187 + .../oracle/oci-go-sdk/v54/core/service.go | 53 + .../oci-go-sdk/v54/core/service_gateway.go | 110 + .../v54/core/service_id_request_details.go | 29 + .../v54/core/service_id_response_details.go | 32 + .../oracle/oci-go-sdk/v54/core/shape.go | 110 + .../core/shape_max_vnic_attachment_options.go | 36 + .../v54/core/shape_measured_boot_options.go | 32 + .../v54/core/shape_memory_options.go | 42 + .../shape_networking_bandwidth_options.go | 36 + ..._numa_nodes_per_socket_platform_options.go | 59 + .../oci-go-sdk/v54/core/shape_ocpu_options.go | 33 + .../v54/core/shape_platform_config_options.go | 66 + .../v54/core/shape_secure_boot_options.go | 32 + .../shape_trusted_platform_module_options.go | 32 + ...oftreset_instance_pool_request_response.go | 89 + .../start_instance_pool_request_response.go | 89 + .../stop_instance_pool_request_response.go | 89 + .../oracle/oci-go-sdk/v54/core/subnet.go | 172 + .../oci-go-sdk/v54/core/subnet_topology.go | 107 + .../oracle/oci-go-sdk/v54/core/tcp_options.go | 30 + ...minate_cluster_network_request_response.go | 80 + ...erminate_instance_pool_request_response.go | 76 + .../terminate_instance_request_response.go | 80 + .../v54/core/terminate_preemption_action.go | 44 + .../oracle/oci-go-sdk/v54/core/topology.go | 129 + ...ogy_associated_with_entity_relationship.go | 62 + ...gy_associated_with_relationship_details.go | 29 + .../topology_contains_entity_relationship.go | 60 + .../v54/core/topology_entity_relationship.go | 119 + .../topology_routes_to_entity_relationship.go | 61 + ...topology_routes_to_relationship_details.go | 63 + .../oci-go-sdk/v54/core/tunnel_config.go | 39 + .../v54/core/tunnel_cpe_device_config.go | 35 + .../v54/core/tunnel_phase_one_details.go | 60 + .../v54/core/tunnel_phase_two_details.go | 63 + .../v54/core/tunnel_route_summary.go | 64 + .../tunnel_security_association_summary.go | 72 + .../oci-go-sdk/v54/core/tunnel_status.go | 68 + .../oracle/oci-go-sdk/v54/core/udp_options.go | 30 + .../core/update_boot_volume_backup_details.go | 40 + ...ate_boot_volume_backup_request_response.go | 81 + .../v54/core/update_boot_volume_details.go | 58 + .../update_boot_volume_kms_key_details.go | 31 + ...te_boot_volume_kms_key_request_response.go | 85 + .../update_boot_volume_request_response.go | 85 + .../v54/core/update_byoip_range_details.go | 40 + .../update_byoip_range_request_response.go | 85 + .../core/update_cluster_network_details.go | 43 + ...e_cluster_network_instance_pool_details.go | 46 + ...update_cluster_network_request_response.go | 92 + ...te_compute_capacity_reservation_details.go | 49 + ...e_capacity_reservation_request_response.go | 83 + ...compute_image_capability_schema_details.go | 80 + ...mage_capability_schema_request_response.go | 85 + .../core/update_console_history_details.go | 40 + ...update_console_history_request_response.go | 85 + .../oci-go-sdk/v54/core/update_cpe_details.go | 51 + .../v54/core/update_cpe_request_response.go | 85 + .../v54/core/update_cross_connect_details.go | 51 + .../update_cross_connect_group_details.go | 45 + ...te_cross_connect_group_request_response.go | 85 + .../update_cross_connect_request_response.go | 85 + .../core/update_dedicated_vm_host_details.go | 40 + ...date_dedicated_vm_host_request_response.go | 92 + .../v54/core/update_dhcp_details.go | 110 + .../update_dhcp_options_request_response.go | 85 + .../v54/core/update_drg_attachment_details.go | 102 + .../update_drg_attachment_request_response.go | 85 + .../oci-go-sdk/v54/core/update_drg_details.go | 42 + .../v54/core/update_drg_request_response.go | 85 + .../update_drg_route_distribution_details.go | 41 + ...drg_route_distribution_request_response.go | 85 + ...rg_route_distribution_statement_details.go | 70 + ...g_route_distribution_statements_details.go | 29 + ...istribution_statements_request_response.go | 77 + .../v54/core/update_drg_route_rule_details.go | 65 + .../core/update_drg_route_rules_details.go | 29 + ...update_drg_route_rules_request_response.go | 77 + .../core/update_drg_route_table_details.go | 49 + ...update_drg_route_table_request_response.go | 85 + ...ate_i_p_sec_connection_request_response.go | 85 + ..._sec_connection_tunnel_request_response.go | 88 + ...n_tunnel_shared_secret_request_response.go | 88 + .../v54/core/update_image_details.go | 48 + .../v54/core/update_image_request_response.go | 92 + .../update_instance_agent_config_details.go | 62 + ...te_instance_availability_config_details.go | 61 + .../update_instance_configuration_details.go | 40 + ...instance_configuration_request_response.go | 92 + ...ate_instance_console_connection_details.go | 36 + ...nce_console_connection_request_response.go | 85 + .../v54/core/update_instance_details.go | 102 + .../v54/core/update_instance_pool_details.go | 54 + ...ce_pool_placement_configuration_details.go | 48 + .../update_instance_pool_request_response.go | 92 + .../core/update_instance_request_response.go | 96 + .../update_instance_shape_config_details.go | 71 + .../core/update_internet_gateway_details.go | 43 + ...pdate_internet_gateway_request_response.go | 85 + .../core/update_ip_sec_connection_details.go | 85 + ...update_ip_sec_connection_tunnel_details.go | 148 + ...connection_tunnel_shared_secret_details.go | 30 + ...pdate_ip_sec_tunnel_bgp_session_details.go | 77 + ...ip_sec_tunnel_encryption_domain_details.go | 34 + .../v54/core/update_ipv6_details.go | 44 + .../v54/core/update_ipv6_request_response.go | 85 + .../v54/core/update_launch_options.go | 108 + .../update_local_peering_gateway_details.go | 45 + ..._local_peering_gateway_request_response.go | 85 + .../oci-go-sdk/v54/core/update_macsec_key.go | 38 + .../v54/core/update_macsec_properties.go | 34 + .../v54/core/update_nat_gateway_details.go | 44 + .../update_nat_gateway_request_response.go | 85 + .../update_network_security_group_details.go | 40 + ...network_security_group_request_response.go | 85 + ...k_security_group_security_rules_details.go | 29 + ...y_group_security_rules_request_response.go | 78 + .../v54/core/update_private_ip_details.go | 55 + .../update_private_ip_request_response.go | 85 + .../v54/core/update_public_ip_details.go | 47 + .../v54/core/update_public_ip_pool_details.go | 40 + .../update_public_ip_pool_request_response.go | 85 + .../core/update_public_ip_request_response.go | 85 + ...pdate_remote_peering_connection_details.go | 40 + ...ote_peering_connection_request_response.go | 85 + .../v54/core/update_route_table_details.go | 43 + .../update_route_table_request_response.go | 85 + .../v54/core/update_security_list_details.go | 46 + .../update_security_list_request_response.go | 85 + .../v54/core/update_security_rule_details.go | 176 + .../core/update_service_gateway_details.go | 61 + ...update_service_gateway_request_response.go | 85 + .../v54/core/update_subnet_details.go | 71 + .../core/update_subnet_request_response.go | 85 + ...update_tunnel_cpe_device_config_details.go | 29 + ...nnel_cpe_device_config_request_response.go | 95 + .../oci-go-sdk/v54/core/update_vcn_details.go | 40 + .../v54/core/update_vcn_request_response.go | 85 + .../core/update_virtual_circuit_details.go | 148 + ...update_virtual_circuit_request_response.go | 85 + .../v54/core/update_vlan_details.go | 58 + .../v54/core/update_vlan_request_response.go | 85 + .../v54/core/update_vnic_details.go | 73 + .../v54/core/update_vnic_request_response.go | 85 + .../core/update_volume_attachment_details.go | 63 + ...date_volume_attachment_request_response.go | 85 + .../v54/core/update_volume_backup_details.go | 40 + .../update_volume_backup_policy_details.go | 53 + ...e_volume_backup_policy_request_response.go | 92 + .../update_volume_backup_request_response.go | 81 + .../v54/core/update_volume_details.go | 59 + .../update_volume_group_backup_details.go | 40 + ...te_volume_group_backup_request_response.go | 81 + .../v54/core/update_volume_group_details.go | 43 + .../update_volume_group_request_response.go | 85 + .../v54/core/update_volume_kms_key_details.go | 31 + .../update_volume_kms_key_request_response.go | 85 + .../core/update_volume_request_response.go | 85 + ...d_network_security_group_security_rules.go | 29 + .../v54/core/upgrade_drg_request_response.go | 82 + .../oci-go-sdk/v54/core/upgrade_status.go | 60 + .../validate_byoip_range_request_response.go | 75 + .../oracle/oci-go-sdk/v54/core/vcn.go | 125 + .../v54/core/vcn_dns_resolver_association.go | 62 + ...n_drg_attachment_network_create_details.go | 57 + .../vcn_drg_attachment_network_details.go | 55 + ...n_drg_attachment_network_update_details.go | 47 + .../oci-go-sdk/v54/core/vcn_topology.go | 107 + .../oci-go-sdk/v54/core/virtual_circuit.go | 362 + .../core/virtual_circuit_bandwidth_shape.go | 34 + ..._circuit_drg_attachment_network_details.go | 49 + .../v54/core/virtual_circuit_ip_mtu.go | 37 + .../v54/core/virtual_circuit_public_prefix.go | 63 + .../oracle/oci-go-sdk/v54/core/vlan.go | 115 + .../oracle/oci-go-sdk/v54/core/vnic.go | 158 + .../oci-go-sdk/v54/core/vnic_attachment.go | 108 + .../oracle/oci-go-sdk/v54/core/volume.go | 216 + .../oci-go-sdk/v54/core/volume_attachment.go | 287 + .../oci-go-sdk/v54/core/volume_backup.go | 185 + .../v54/core/volume_backup_policy.go | 60 + .../core/volume_backup_policy_assignment.go | 41 + .../v54/core/volume_backup_schedule.go | 248 + .../oci-go-sdk/v54/core/volume_group.go | 166 + .../v54/core/volume_group_backup.go | 180 + .../v54/core/volume_group_source_details.go | 74 + ...source_from_volume_group_backup_details.go | 44 + ..._group_source_from_volume_group_details.go | 44 + ...olume_group_source_from_volumes_details.go | 44 + .../oci-go-sdk/v54/core/volume_kms_key.go | 29 + .../v54/core/volume_source_details.go | 76 + ...ource_from_block_volume_replica_details.go | 46 + ...olume_source_from_volume_backup_details.go | 44 + .../core/volume_source_from_volume_details.go | 44 + .../withdraw_byoip_range_request_response.go | 71 + .../activate_domain_request_response.go | 86 + ...tivate_mfa_totp_device_request_response.go | 95 + .../v54/identity/add_user_to_group_details.go | 28 + .../add_user_to_group_request_response.go | 84 + .../allowed_domain_license_type_summary.go | 33 + .../oracle/oci-go-sdk/v54/identity/api_key.go | 81 + ...mble_effective_tag_set_request_response.go | 82 + .../oci-go-sdk/v54/identity/auth_token.go | 86 + .../v54/identity/authentication_policy.go | 28 + .../v54/identity/availability_domain.go | 33 + .../identity/base_tag_definition_validator.go | 97 + .../v54/identity/bulk_action_resource.go | 52 + .../v54/identity/bulk_action_resource_type.go | 29 + .../bulk_action_resource_type_collection.go | 25 + .../identity/bulk_delete_resources_details.go | 25 + .../bulk_delete_resources_request_response.go | 84 + .../v54/identity/bulk_delete_tags_details.go | 25 + .../bulk_delete_tags_request_response.go | 81 + .../identity/bulk_edit_operation_details.go | 62 + .../v54/identity/bulk_edit_resource.go | 31 + .../v54/identity/bulk_edit_tags_details.go | 31 + .../bulk_edit_tags_request_response.go | 81 + .../identity/bulk_edit_tags_resource_type.go | 32 + ...bulk_edit_tags_resource_type_collection.go | 25 + .../identity/bulk_move_resources_details.go | 29 + .../bulk_move_resources_request_response.go | 84 + ...e_delete_tag_namespace_request_response.go | 86 + .../change_domain_compartment_details.go | 26 + ...nge_domain_compartment_request_response.go | 89 + .../change_domain_license_type_details.go | 25 + ...ge_domain_license_type_request_response.go | 89 + ...change_tag_namespace_compartment_detail.go | 25 + ..._namespace_compartment_request_response.go | 81 + .../change_tas_domain_license_type_details.go | 25 + .../oci-go-sdk/v54/identity/compartment.go | 105 + .../v54/identity/create_api_key_details.go | 25 + .../v54/identity/create_auth_token_details.go | 25 + .../create_auth_token_request_response.go | 87 + .../identity/create_compartment_details.go | 42 + .../create_compartment_request_response.go | 84 + .../create_customer_secret_key_details.go | 25 + ...te_customer_secret_key_request_response.go | 87 + .../identity/create_db_credential_details.go | 28 + .../create_db_credential_request_response.go | 87 + .../v54/identity/create_domain_details.go | 73 + .../create_domain_request_response.go | 81 + .../identity/create_dynamic_group_details.go | 46 + .../create_dynamic_group_request_response.go | 84 + .../v54/identity/create_group_details.go | 42 + .../identity/create_group_request_response.go | 84 + .../create_identity_provider_details.go | 178 + ...eate_identity_provider_request_response.go | 84 + .../create_idp_group_mapping_details.go | 29 + ...eate_idp_group_mapping_request_response.go | 87 + ...create_mfa_totp_device_request_response.go | 84 + .../identity/create_network_source_details.go | 54 + .../create_network_source_request_response.go | 84 + ...reate_o_auth2_client_credential_details.go | 31 + ...auth_client_credential_request_response.go | 87 + ..._or_reset_u_i_password_request_response.go | 84 + .../v54/identity/create_policy_details.go | 52 + .../create_policy_request_response.go | 84 + .../create_region_subscription_details.go | 27 + ...te_region_subscription_request_response.go | 84 + .../create_saml2_identity_provider_details.go | 106 + .../create_smtp_credential_details.go | 25 + ...create_smtp_credential_request_response.go | 87 + .../identity/create_swift_password_details.go | 25 + .../create_swift_password_request_response.go | 87 + .../identity/create_tag_default_details.go | 39 + .../create_tag_default_request_response.go | 84 + .../v54/identity/create_tag_details.go | 84 + .../identity/create_tag_namespace_details.go | 41 + .../create_tag_namespace_request_response.go | 81 + .../identity/create_tag_request_response.go | 87 + .../v54/identity/create_user_details.go | 45 + .../identity/create_user_request_response.go | 84 + .../v54/identity/customer_secret_key.go | 83 + .../identity/customer_secret_key_summary.go | 77 + .../oci-go-sdk/v54/identity/db_credential.go | 72 + .../v54/identity/db_credential_summary.go | 46 + .../deactivate_domain_request_response.go | 86 + .../default_tag_definition_validator.go | 39 + .../delete_api_key_request_response.go | 79 + .../delete_auth_token_request_response.go | 79 + .../delete_compartment_request_response.go | 79 + ...te_customer_secret_key_request_response.go | 79 + .../delete_db_credential_request_response.go | 79 + .../delete_domain_request_response.go | 79 + .../delete_dynamic_group_request_response.go | 76 + .../identity/delete_group_request_response.go | 76 + ...lete_identity_provider_request_response.go | 76 + ...lete_idp_group_mapping_request_response.go | 79 + ...delete_mfa_totp_device_request_response.go | 79 + .../delete_network_source_request_response.go | 76 + ...auth_client_credential_request_response.go | 79 + .../delete_policy_request_response.go | 76 + ...delete_smtp_credential_request_response.go | 79 + .../delete_swift_password_request_response.go | 79 + .../delete_tag_default_request_response.go | 76 + .../delete_tag_namespace_request_response.go | 76 + .../identity/delete_tag_request_response.go | 82 + .../identity/delete_user_request_response.go | 76 + .../oracle/oci-go-sdk/v54/identity/domain.go | 153 + .../v54/identity/domain_replication.go | 31 + .../v54/identity/domain_replication_states.go | 31 + .../oci-go-sdk/v54/identity/domain_summary.go | 100 + .../oci-go-sdk/v54/identity/dynamic_group.go | 98 + .../enable_replication_to_region_details.go | 28 + ..._replication_to_region_request_response.go | 89 + .../identity/enum_tag_definition_validator.go | 42 + .../oci-go-sdk/v54/identity/fault_domain.go | 36 + .../v54/identity/fully_qualified_scope.go | 28 + .../generate_totp_seed_request_response.go | 85 + ..._authentication_policy_request_response.go | 77 + .../get_compartment_request_response.go | 77 + .../identity/get_domain_request_response.go | 77 + .../get_dynamic_group_request_response.go | 77 + .../identity/get_group_request_response.go | 77 + .../get_iam_work_request_request_response.go | 74 + .../get_identity_provider_request_response.go | 77 + .../get_idp_group_mapping_request_response.go | 80 + .../get_mfa_totp_device_request_response.go | 80 + .../get_network_source_request_response.go | 77 + .../identity/get_policy_request_response.go | 77 + ..._standard_tag_template_request_response.go | 77 + .../get_tag_default_request_response.go | 77 + .../get_tag_namespace_request_response.go | 74 + .../v54/identity/get_tag_request_response.go | 80 + ...t_tagging_work_request_request_response.go | 77 + .../identity/get_tenancy_request_response.go | 74 + ..._user_group_membership_request_response.go | 77 + .../v54/identity/get_user_request_response.go | 77 + ...i_password_information_request_response.go | 77 + .../get_work_request_request_response.go | 77 + .../oracle/oci-go-sdk/v54/identity/group.go | 97 + .../v54/identity/iam_work_request.go | 118 + .../iam_work_request_error_summary.go | 31 + .../identity/iam_work_request_log_summary.go | 29 + .../v54/identity/iam_work_request_resource.go | 66 + .../v54/identity/iam_work_request_summary.go | 118 + .../v54/identity/identity_client.go | 8577 ++++++++++ .../v54/identity/identity_provider.go | 217 + .../identity_provider_group_summary.go | 45 + .../v54/identity/idp_group_mapping.go | 85 + .../identity/import_standard_tags_details.go | 28 + .../import_standard_tags_request_response.go | 81 + ...d_domain_license_types_request_response.go | 79 + .../list_api_keys_request_response.go | 79 + .../list_auth_tokens_request_response.go | 79 + ...t_availability_domains_request_response.go | 79 + ..._action_resource_types_request_response.go | 108 + ...it_tags_resource_types_request_response.go | 82 + .../list_compartments_request_response.go | 188 + ...ist_cost_tracking_tags_request_response.go | 86 + ...t_customer_secret_keys_request_response.go | 79 + .../list_db_credentials_request_response.go | 150 + .../identity/list_domains_request_response.go | 168 + .../list_dynamic_groups_request_response.go | 150 + .../list_fault_domains_request_response.go | 77 + .../identity/list_groups_request_response.go | 150 + ...am_work_request_errors_request_response.go | 112 + ..._iam_work_request_logs_request_response.go | 115 + ...list_iam_work_requests_request_response.go | 88 + ...entity_provider_groups_request_response.go | 91 + ...ist_identity_providers_request_response.go | 174 + ...ist_idp_group_mappings_request_response.go | 85 + .../list_mfa_totp_devices_request_response.go | 144 + .../list_network_sources_request_response.go | 150 + ...uth_client_credentials_request_response.go | 88 + .../list_policies_request_response.go | 150 + ...t_region_subscriptions_request_response.go | 74 + .../identity/list_regions_request_response.go | 71 + .../list_smtp_credentials_request_response.go | 79 + ...tandard_tag_namespaces_request_response.go | 85 + .../list_swift_passwords_request_response.go | 79 + .../list_tag_defaults_request_response.go | 94 + .../list_tag_namespaces_request_response.go | 92 + ...ng_work_request_errors_request_response.go | 88 + ...ging_work_request_logs_request_response.go | 88 + ..._tagging_work_requests_request_response.go | 88 + .../identity/list_tags_request_response.go | 88 + ...user_group_memberships_request_response.go | 91 + .../identity/list_users_request_response.go | 156 + .../list_work_requests_request_response.go | 88 + .../v54/identity/mfa_totp_device.go | 89 + .../v54/identity/mfa_totp_device_summary.go | 80 + .../oci-go-sdk/v54/identity/mfa_totp_token.go | 25 + .../v54/identity/move_compartment_details.go | 26 + .../move_compartment_request_response.go | 89 + .../oci-go-sdk/v54/identity/network_policy.go | 25 + .../v54/identity/network_sources.go | 99 + .../v54/identity/network_sources_summary.go | 62 + .../network_sources_virtual_source_list.go | 25 + .../v54/identity/o_auth2_client_credential.go | 85 + .../o_auth2_client_credential_summary.go | 82 + .../v54/identity/password_policy.go | 40 + .../oracle/oci-go-sdk/v54/identity/policy.go | 104 + .../recover_compartment_request_response.go | 82 + .../oracle/oci-go-sdk/v54/identity/region.go | 37 + .../v54/identity/region_subscription.go | 65 + ...remove_user_from_group_request_response.go | 76 + .../v54/identity/replicated_region_details.go | 62 + .../reset_idp_scim_client_request_response.go | 74 + .../v54/identity/saml2_identity_provider.go | 155 + .../v54/identity/scim_client_credentials.go | 28 + .../v54/identity/smtp_credential.go | 87 + .../v54/identity/smtp_credential_summary.go | 81 + .../standard_tag_definition_template.go | 88 + .../standard_tag_namespace_template.go | 34 + ...standard_tag_namespace_template_summary.go | 31 + .../oci-go-sdk/v54/identity/swift_password.go | 85 + .../oracle/oci-go-sdk/v54/identity/tag.go | 159 + .../oci-go-sdk/v54/identity/tag_default.go | 85 + .../v54/identity/tag_default_summary.go | 76 + .../oci-go-sdk/v54/identity/tag_namespace.go | 85 + .../v54/identity/tag_namespace_summary.go | 55 + .../oci-go-sdk/v54/identity/tag_summary.go | 59 + .../v54/identity/tagging_work_request.go | 115 + .../tagging_work_request_error_summary.go | 32 + .../tagging_work_request_log_summary.go | 29 + .../identity/tagging_work_request_summary.go | 114 + .../oracle/oci-go-sdk/v54/identity/tenancy.go | 55 + .../oci-go-sdk/v54/identity/ui_password.go | 70 + .../v54/identity/ui_password_information.go | 64 + .../v54/identity/update_auth_token_details.go | 25 + .../update_auth_token_request_response.go | 88 + .../update_authentication_policy_details.go | 25 + ..._authentication_policy_request_response.go | 85 + .../identity/update_compartment_details.go | 39 + .../update_compartment_request_response.go | 85 + .../update_customer_secret_key_details.go | 25 + ...te_customer_secret_key_request_response.go | 88 + .../v54/identity/update_domain_details.go | 41 + .../update_domain_request_response.go | 82 + .../identity/update_dynamic_group_details.go | 39 + .../update_dynamic_group_request_response.go | 85 + .../v54/identity/update_group_details.go | 35 + .../identity/update_group_request_response.go | 85 + .../update_identity_provider_details.go | 118 + ...date_identity_provider_request_response.go | 85 + .../update_idp_group_mapping_details.go | 28 + ...date_idp_group_mapping_request_response.go | 88 + .../identity/update_network_source_details.go | 46 + .../update_network_source_request_response.go | 85 + ...pdate_o_auth2_client_credential_details.go | 31 + ...auth_client_credential_request_response.go | 88 + .../v54/identity/update_policy_details.go | 45 + .../update_policy_request_response.go | 85 + .../update_saml2_identity_provider_details.go | 77 + .../update_smtp_credential_details.go | 25 + ...update_smtp_credential_request_response.go | 88 + .../v54/identity/update_state_details.go | 25 + .../identity/update_swift_password_details.go | 25 + .../update_swift_password_request_response.go | 88 + .../identity/update_tag_default_details.go | 33 + .../update_tag_default_request_response.go | 85 + .../v54/identity/update_tag_details.go | 84 + .../identity/update_tag_namespace_details.go | 39 + .../update_tag_namespace_request_response.go | 77 + .../identity/update_tag_request_response.go | 88 + .../update_user_capabilities_details.go | 43 + ...date_user_capabilities_request_response.go | 85 + .../v54/identity/update_user_details.go | 41 + .../identity/update_user_request_response.go | 85 + .../update_user_state_request_response.go | 85 + .../upload_api_key_request_response.go | 87 + .../oracle/oci-go-sdk/v54/identity/user.go | 146 + .../v54/identity/user_capabilities.go | 43 + .../v54/identity/user_group_membership.go | 75 + .../oci-go-sdk/v54/identity/work_request.go | 113 + .../v54/identity/work_request_error.go | 32 + .../v54/identity/work_request_log_entry.go | 29 + .../v54/identity/work_request_resource.go | 65 + .../v54/identity/work_request_summary.go | 109 + ...abort_multipart_upload_request_response.go | 84 + .../v54/objectstorage/archival_state.go | 37 + .../oci-go-sdk/v54/objectstorage/bucket.go | 210 + .../v54/objectstorage/bucket_summary.go | 55 + .../cancel_work_request_request_response.go | 73 + .../commit_multipart_upload_details.go | 33 + .../commit_multipart_upload_part_details.go | 32 + ...ommit_multipart_upload_request_response.go | 112 + .../v54/objectstorage/copy_object_details.go | 68 + .../copy_object_request_response.go | 118 + .../objectstorage/create_bucket_details.go | 149 + .../create_bucket_request_response.go | 85 + .../create_multipart_upload_details.go | 69 + ...reate_multipart_upload_request_response.go | 113 + ...create_preauthenticated_request_details.go | 77 + ...eauthenticated_request_request_response.go | 83 + .../create_replication_policy_details.go | 34 + ...ate_replication_policy_request_response.go | 83 + .../create_retention_rule_details.go | 36 + .../create_retention_rule_request_response.go | 85 + .../delete_bucket_request_response.go | 82 + ...bject_lifecycle_policy_request_response.go | 82 + .../delete_object_request_response.go | 99 + ...eauthenticated_request_request_response.go | 81 + ...ete_replication_policy_request_response.go | 80 + .../delete_retention_rule_request_response.go | 85 + .../oci-go-sdk/v54/objectstorage/duration.go | 56 + .../get_bucket_request_response.go | 130 + ...get_namespace_metadata_request_response.go | 76 + .../get_namespace_request_response.go | 70 + ...bject_lifecycle_policy_request_response.go | 83 + .../get_object_request_response.go | 247 + ...eauthenticated_request_request_response.go | 84 + ...get_replication_policy_request_response.go | 83 + .../get_retention_rule_request_response.go | 89 + .../get_work_request_request_response.go | 79 + .../head_bucket_request_response.go | 96 + .../head_object_request_response.go | 214 + .../list_buckets_request_response.go | 123 + ...multipart_upload_parts_request_response.go | 105 + ...list_multipart_uploads_request_response.go | 98 + .../list_object_versions_request_response.go | 159 + .../v54/objectstorage/list_objects.go | 37 + .../list_objects_request_response.go | 111 + ...authenticated_requests_request_response.go | 101 + ...t_replication_policies_request_response.go | 97 + ...st_replication_sources_request_response.go | 97 + .../list_retention_rules_request_response.go | 93 + ...st_work_request_errors_request_response.go | 94 + ...list_work_request_logs_request_response.go | 94 + .../list_work_requests_request_response.go | 94 + .../make_bucket_writable_request_response.go | 77 + .../v54/objectstorage/multipart_upload.go | 49 + .../multipart_upload_part_summary.go | 39 + .../v54/objectstorage/namespace_metadata.go | 33 + .../objectstorage/object_lifecycle_policy.go | 33 + .../objectstorage/object_lifecycle_rule.go | 85 + .../v54/objectstorage/object_name_filter.go | 70 + .../v54/objectstorage/object_summary.go | 51 + .../object_version_collection.go | 32 + .../objectstorage/object_version_summary.go | 57 + .../v54/objectstorage/objectstorage_client.go | 2925 ++++ .../v54/objectstorage/pattern_details.go | 64 + .../objectstorage/preauthenticated_request.go | 114 + .../preauthenticated_request_summary.go | 79 + .../put_object_lifecycle_policy_details.go | 27 + ...bject_lifecycle_policy_request_response.go | 95 + .../put_object_request_response.go | 206 + .../reencrypt_bucket_request_response.go | 81 + .../objectstorage/reencrypt_object_details.go | 42 + .../reencrypt_object_request_response.go | 87 + .../objectstorage/rename_object_details.go | 42 + .../rename_object_request_response.go | 89 + .../v54/objectstorage/replication_policy.go | 73 + .../replication_policy_summary.go | 73 + .../v54/objectstorage/replication_source.go | 33 + .../objectstorage/restore_objects_details.go | 34 + .../restore_objects_request_response.go | 80 + .../v54/objectstorage/retention_rule.go | 45 + .../retention_rule_collection.go | 27 + .../objectstorage/retention_rule_details.go | 36 + .../objectstorage/retention_rule_summary.go | 45 + .../objectstorage/sse_customer_key_details.go | 55 + .../v54/objectstorage/storage_tier.go | 37 + .../objectstorage/transfer/file_uploader.go | 209 + .../transfer/file_uploader_req_resp.go | 44 + .../transfer/multipart_manifest.go | 211 + .../transfer/mutipart_uploader.go | 153 + .../objectstorage/transfer/stream_uploader.go | 90 + .../transfer/stream_uploader_req_resp.go | 57 + .../objectstorage/transfer/upload_manager.go | 179 + .../transfer/upload_manager_req_resp.go | 241 + .../objectstorage/update_bucket_details.go | 125 + .../update_bucket_request_response.go | 91 + .../update_namespace_metadata_details.go | 31 + ...ate_namespace_metadata_request_response.go | 79 + .../update_object_storage_tier_details.go | 37 + ...te_object_storage_tier_request_response.go | 80 + .../update_retention_rule_details.go | 36 + .../update_retention_rule_request_response.go | 94 + .../upload_part_request_response.go | 143 + .../v54/objectstorage/work_request.go | 111 + .../v54/objectstorage/work_request_error.go | 34 + .../objectstorage/work_request_log_entry.go | 31 + .../objectstorage/work_request_resource.go | 72 + .../work_request_resource_metadata_key.go | 39 + .../v54/objectstorage/work_request_summary.go | 111 + .../get_work_request_request_response.go | 74 + ...st_work_request_errors_request_response.go | 115 + ...list_work_request_logs_request_response.go | 115 + .../list_work_requests_request_response.go | 92 + .../v54/workrequests/work_request.go | 87 + .../v54/workrequests/work_request_error.go | 35 + .../workrequests/work_request_log_entry.go | 32 + .../v54/workrequests/work_request_resource.go | 70 + .../v54/workrequests/work_request_summary.go | 84 + .../workrequests_workrequest_client.go | 309 + vendor/github.com/sony/gobreaker/.travis.yml | 15 + vendor/github.com/sony/gobreaker/LICENSE | 21 + vendor/github.com/sony/gobreaker/README.md | 128 + vendor/github.com/sony/gobreaker/go.mod | 5 + vendor/github.com/sony/gobreaker/go.sum | 7 + vendor/github.com/sony/gobreaker/gobreaker.go | 380 + vendor/github.com/spf13/cobra/.gitignore | 36 + vendor/github.com/spf13/cobra/.mailmap | 3 + vendor/github.com/spf13/cobra/.travis.yml | 21 + vendor/github.com/spf13/cobra/LICENSE.txt | 174 + vendor/github.com/spf13/cobra/README.md | 736 + vendor/github.com/spf13/cobra/args.go | 89 + .../spf13/cobra/bash_completions.go | 584 + .../spf13/cobra/bash_completions.md | 221 + vendor/github.com/spf13/cobra/cobra.go | 200 + vendor/github.com/spf13/cobra/command.go | 1517 ++ .../github.com/spf13/cobra/command_notwin.go | 5 + vendor/github.com/spf13/cobra/command_win.go | 20 + .../github.com/spf13/cobra/zsh_completions.go | 126 + vendor/github.com/spf13/pflag/.gitignore | 2 + vendor/github.com/spf13/pflag/.travis.yml | 21 + vendor/github.com/spf13/pflag/LICENSE | 28 + vendor/github.com/spf13/pflag/README.md | 296 + vendor/github.com/spf13/pflag/bool.go | 94 + vendor/github.com/spf13/pflag/bool_slice.go | 147 + vendor/github.com/spf13/pflag/bytes.go | 105 + vendor/github.com/spf13/pflag/count.go | 96 + vendor/github.com/spf13/pflag/duration.go | 86 + .../github.com/spf13/pflag/duration_slice.go | 128 + vendor/github.com/spf13/pflag/flag.go | 1223 ++ vendor/github.com/spf13/pflag/float32.go | 88 + vendor/github.com/spf13/pflag/float64.go | 84 + vendor/github.com/spf13/pflag/golangflag.go | 105 + vendor/github.com/spf13/pflag/int.go | 84 + vendor/github.com/spf13/pflag/int16.go | 88 + vendor/github.com/spf13/pflag/int32.go | 88 + vendor/github.com/spf13/pflag/int64.go | 84 + vendor/github.com/spf13/pflag/int8.go | 88 + vendor/github.com/spf13/pflag/int_slice.go | 128 + vendor/github.com/spf13/pflag/ip.go | 94 + vendor/github.com/spf13/pflag/ip_slice.go | 148 + vendor/github.com/spf13/pflag/ipmask.go | 122 + vendor/github.com/spf13/pflag/ipnet.go | 98 + vendor/github.com/spf13/pflag/string.go | 80 + vendor/github.com/spf13/pflag/string_array.go | 103 + vendor/github.com/spf13/pflag/string_slice.go | 149 + vendor/github.com/spf13/pflag/uint.go | 88 + vendor/github.com/spf13/pflag/uint16.go | 88 + vendor/github.com/spf13/pflag/uint32.go | 88 + vendor/github.com/spf13/pflag/uint64.go | 88 + vendor/github.com/spf13/pflag/uint8.go | 88 + vendor/github.com/spf13/pflag/uint_slice.go | 126 + vendor/modules.txt | 18 + 1358 files changed, 151693 insertions(+) create mode 100644 vendor/github.com/inconshreveable/mousetrap/LICENSE create mode 100644 vendor/github.com/inconshreveable/mousetrap/README.md create mode 100644 vendor/github.com/inconshreveable/mousetrap/trap_others.go create mode 100644 vendor/github.com/inconshreveable/mousetrap/trap_windows.go create mode 100644 vendor/github.com/inconshreveable/mousetrap/trap_windows_1.4.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/LICENSE.txt create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/NOTICE.txt create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/auth/certificate_retriever.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/auth/configuration.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/auth/dispatcher_modifier.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/auth/federation_client.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/auth/instance_principal_delegation_token_provider.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/auth/instance_principal_key_provider.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/auth/jwt.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/auth/resouce_principal_key_provider.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/auth/resource_principal_token_path_provider.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/auth/resource_principals_v1.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/auth/utils.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/circuit_breaker.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/client.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/common.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/configuration.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/errors.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/helpers.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/http.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/http_signer.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/log.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/regions.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/regions.json create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/retry.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/common/version.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/accept_shielded_integrity_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_distribution_statement_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_distribution_statements_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_distribution_statements_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_rule_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_rules_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_rules_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_image_shape_compatibility_entry_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_image_shape_compatibility_entry_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_ipv6_vcn_cidr_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_network_security_group_security_rules_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_network_security_group_security_rules_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_public_ip_pool_capacity_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_public_ip_pool_capacity_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_security_rule_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_vcn_cidr_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/add_vcn_cidr_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/added_network_security_group_security_rules.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/advertise_byoip_range_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/allowed_ike_ip_sec_parameters.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/allowed_phase_one_parameters.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/allowed_phase_two_parameters.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/amd_milan_bm_launch_instance_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/amd_milan_bm_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/amd_rome_bm_launch_instance_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/amd_rome_bm_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/amd_vm_launch_instance_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/amd_vm_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_resource_version.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_resource_version_agreements.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_resource_version_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_subscription.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_subscription_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/attach_boot_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/attach_boot_volume_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/attach_emulated_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/attach_i_scsi_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/attach_instance_pool_instance_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/attach_instance_pool_instance_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/attach_load_balancer_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/attach_load_balancer_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/attach_paravirtualized_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/attach_service_determined_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/attach_service_id_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/attach_vnic_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/attach_vnic_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/attach_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/attach_volume_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/bgp_session_info.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/block_volume_replica.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/block_volume_replica_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/block_volume_replica_info.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/boolean_image_capability_schema_descriptor.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_attachment.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_backup.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_kms_key.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_replica.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_replica_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_replica_info.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_from_boot_volume_backup_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_from_boot_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_from_boot_volume_replica_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_add_virtual_circuit_public_prefixes_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_add_virtual_circuit_public_prefixes_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_delete_virtual_circuit_public_prefixes_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_delete_virtual_circuit_public_prefixes_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_allocated_range_collection.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_allocated_range_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_range.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_range_collection.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_range_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/capacity_reservation_instance_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/capture_console_history_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/capture_console_history_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_backup_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_backup_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_byoip_range_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_byoip_range_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_cluster_network_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_cluster_network_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_capacity_reservation_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_capacity_reservation_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_image_capability_schema_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_image_capability_schema_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_cpe_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_cpe_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_group_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_group_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_dedicated_vm_host_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_dedicated_vm_host_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_dhcp_options_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_dhcp_options_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_drg_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_drg_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_i_p_sec_connection_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_image_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_image_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_configuration_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_configuration_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_pool_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_pool_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_internet_gateway_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_internet_gateway_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_ip_sec_connection_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_local_peering_gateway_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_local_peering_gateway_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_nat_gateway_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_nat_gateway_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_network_security_group_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_network_security_group_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_pool_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_pool_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_remote_peering_connection_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_remote_peering_connection_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_route_table_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_route_table_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_security_list_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_security_list_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_service_gateway_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_service_gateway_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_subnet_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_subnet_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_vcn_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_vcn_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_virtual_circuit_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_virtual_circuit_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_vlan_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_vlan_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_backup_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_backup_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_backup_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_backup_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cluster_network.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cluster_network_placement_configuration_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cluster_network_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/compute_capacity_reservation.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/compute_capacity_reservation_instance_shape_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/compute_capacity_reservation_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema_version.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema_version_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/compute_image_capability_schema.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/compute_image_capability_schema_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/compute_instance_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/connect_local_peering_gateways_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/connect_local_peering_gateways_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/connect_remote_peering_connections_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/connect_remote_peering_connections_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/console_history.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/copy_boot_volume_backup_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/copy_boot_volume_backup_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_backup_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_backup_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_group_backup_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_group_backup_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/core_blockstorage_client.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/core_compute_client.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/core_computemanagement_client.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/core_virtualnetwork_client.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cpe.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_config_answer.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_config_question.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_info.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_shape_detail.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_shape_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_app_catalog_subscription_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_app_catalog_subscription_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_backup_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_backup_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_byoip_range_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_byoip_range_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_cluster_network_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_cluster_network_instance_pool_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_cluster_network_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_capacity_reservation_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_capacity_reservation_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_image_capability_schema_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_image_capability_schema_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_cpe_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_cpe_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_group_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_dedicated_vm_host_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_dedicated_vm_host_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_dhcp_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_dhcp_options_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_attachment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_attachment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_distribution_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_distribution_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_table_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_table_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_i_p_sec_connection_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_image_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_image_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_base.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_from_instance_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_console_connection_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_console_connection_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_pool_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_pool_placement_configuration_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_pool_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_internet_gateway_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_internet_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_connection_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_connection_tunnel_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_tunnel_bgp_session_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_tunnel_encryption_domain_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_ipv6_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_ipv6_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_local_peering_gateway_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_local_peering_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_macsec_key.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_macsec_properties.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_nat_gateway_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_nat_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_network_security_group_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_network_security_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_private_ip_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_private_ip_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_pool_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_pool_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_remote_peering_connection_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_remote_peering_connection_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_route_table_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_route_table_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_security_list_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_security_list_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_service_gateway_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_service_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_subnet_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_subnet_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_vcn_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_vcn_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_virtual_circuit_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_virtual_circuit_public_prefix_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_virtual_circuit_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_vlan_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_vlan_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_vnic_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_assignment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_assignment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_backup_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_backup_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_group.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_location.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_mapping.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_mapping_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_mapping_details_collection.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_port_speed_shape.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_status.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_instance_shape_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_instance_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_shape_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/default_drg_route_tables.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/default_phase_one_parameters.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/default_phase_two_parameters.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_app_catalog_subscription_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_boot_volume_backup_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_boot_volume_kms_key_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_boot_volume_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_byoip_range_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_compute_capacity_reservation_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_compute_image_capability_schema_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_console_history_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_cpe_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_cross_connect_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_cross_connect_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_dedicated_vm_host_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_dhcp_options_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_attachment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_route_distribution_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_route_table_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_i_p_sec_connection_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_image_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_instance_configuration_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_instance_console_connection_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_internet_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_ipv6_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_local_peering_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_nat_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_network_security_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_private_ip_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_public_ip_pool_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_public_ip_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_remote_peering_connection_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_route_table_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_security_list_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_service_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_subnet_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_vcn_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_virtual_circuit_public_prefix_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_virtual_circuit_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_vlan_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_backup_policy_assignment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_backup_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_backup_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_group_backup_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_kms_key_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/detach_boot_volume_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/detach_instance_pool_instance_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/detach_instance_pool_instance_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/detach_load_balancer_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/detach_load_balancer_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/detach_service_id_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/detach_vnic_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/detach_volume_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/device.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_dns_option.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_option.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_search_domain_option.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/dpd_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/drg.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_id_drg_route_distribution_match_criteria.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_info.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_network_create_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_network_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_network_update_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_type_drg_route_distribution_match_criteria.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/drg_redundancy_status.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_distribution.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_distribution_match_criteria.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_distribution_statement.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_rule.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_table.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/egress_security_rule.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/emulated_volume_attachment.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/encryption_domain_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/encryption_in_transit_type.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/enum_integer_image_capability_descriptor.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/enum_string_image_capability_schema_descriptor.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_via_object_storage_tuple_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_via_object_storage_uri_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/fast_connect_provider_service.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/fast_connect_provider_service_key.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_all_drg_attachments_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_allowed_ike_i_p_sec_parameters_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_app_catalog_listing_agreements_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_app_catalog_listing_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_app_catalog_listing_resource_version_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_block_volume_replica_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_attachment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_backup_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_kms_key_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_replica_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_byoip_range_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_cluster_network_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_capacity_reservation_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_global_image_capability_schema_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_global_image_capability_schema_version_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_image_capability_schema_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_console_history_content_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_console_history_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_cpe_device_config_content_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_cpe_device_shape_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_cpe_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_letter_of_authority_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_status_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_dedicated_vm_host_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_dhcp_options_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_attachment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_redundancy_status_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_route_distribution_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_route_table_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_fast_connect_provider_service_key_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_fast_connect_provider_service_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_device_config_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_device_status_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_tunnel_error_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_tunnel_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_tunnel_shared_secret_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_image_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_image_shape_compatibility_entry_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_configuration_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_console_connection_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_pool_instance_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_pool_load_balancer_attachment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_pool_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_internet_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_ipsec_cpe_device_config_content_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_ipv6_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_local_peering_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_measured_boot_report_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_nat_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_network_security_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_networking_topology_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_private_ip_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_ip_address_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_ip_address_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_private_ip_id_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_private_ip_id_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_pool_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_remote_peering_connection_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_route_table_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_security_list_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_service_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_service_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_subnet_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_subnet_topology_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_tunnel_cpe_device_config_content_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_tunnel_cpe_device_config_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_upgrade_status_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_vcn_dns_resolver_association_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_vcn_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_vcn_topology_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_virtual_circuit_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_vlan_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_vnic_attachment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_vnic_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_attachment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_policy_asset_assignment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_policy_assignment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_group_backup_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_kms_key_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/get_windows_instance_initial_credentials_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/i_scsi_volume_attachment.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/icmp_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/image.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/image_capability_schema_descriptor.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/image_memory_constraints.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/image_ocpu_constraints.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/image_shape_compatibility_entry.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/image_shape_compatibility_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/image_source_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/image_source_via_object_storage_tuple_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/image_source_via_object_storage_uri_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/ingress_security_rule.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_action_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_agent_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_agent_features.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_agent_plugin_config_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_availability_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_amd_milan_bm_launch_instance_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_amd_rome_bm_launch_instance_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_amd_vm_launch_instance_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_attach_vnic_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_attach_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_availability_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_block_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_create_vnic_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_create_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_source_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_source_via_boot_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_source_via_image_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_intel_skylake_bm_launch_instance_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_intel_vm_launch_instance_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_iscsi_attach_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_agent_config_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_shape_config_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_paravirtualized_attach_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_volume_source_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_volume_source_from_volume_backup_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_volume_source_from_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_console_connection.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_credentials.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_instance.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_instance_load_balancer_backend.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_load_balancer_attachment.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_placement_configuration.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_placement_secondary_vnic_subnet.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_reservation_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_reservation_config_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_reservation_shape_config_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_shape_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_source_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_source_via_boot_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_source_via_image_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/instance_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/intel_skylake_bm_launch_instance_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/intel_skylake_bm_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/intel_vm_launch_instance_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/intel_vm_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/internet_gateway.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_device_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_device_status.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_tunnel.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_tunnel_error_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_tunnel_shared_secret.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/ipsec_tunnel_drg_attachment_network_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/ipv6.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_agent_config_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_availability_config_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_configuration_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_shape_config_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/launch_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/letter_of_authority.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_allowed_peer_regions_for_remote_peering_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_app_catalog_listing_resource_versions_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_app_catalog_listings_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_app_catalog_subscriptions_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_block_volume_replicas_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volume_attachments_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volume_backups_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volume_replicas_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volumes_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_byoip_allocated_ranges_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_byoip_ranges_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_cluster_network_instances_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_cluster_networks_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_capacity_reservation_instance_shapes_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_capacity_reservation_instances_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_capacity_reservations_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_global_image_capability_schema_versions_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_global_image_capability_schemas_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_image_capability_schemas_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_console_histories_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_cpe_device_shapes_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_cpes_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connect_groups_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connect_locations_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connect_mappings_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connects_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_crossconnect_port_speed_shapes_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_host_instance_shapes_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_host_instances_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_host_shapes_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_hosts_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_dhcp_options_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_attachments_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_distribution_statements_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_distributions_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_rules_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_tables_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_drgs_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_fast_connect_provider_services_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_fast_connect_provider_virtual_circuit_bandwidth_shapes_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connection_tunnel_routes_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connection_tunnel_security_associations_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connection_tunnels_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connections_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_image_shape_compatibility_entries_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_images_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_configurations_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_console_connections_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_devices_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_pool_instances_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_pools_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_instances_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_internet_gateways_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_ipv6s_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_local_peering_gateways_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_nat_gateways_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_network_security_group_security_rules_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_network_security_group_vnics_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_network_security_groups_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_private_ips_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_public_ip_pools_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_public_ips_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_remote_peering_connections_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_route_tables_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_security_lists_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_service_gateways_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_services_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_shapes_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_subnets_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_vcns_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_virtual_circuit_bandwidth_shapes_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_virtual_circuit_public_prefixes_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_virtual_circuits_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_vlans_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_vnic_attachments_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_attachments_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_backup_policies_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_backups_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_group_backups_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_groups_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/list_volumes_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/local_peering_gateway.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_encryption_cipher.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_key.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_properties.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_state.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/measured_boot_entry.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/measured_boot_report.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/measured_boot_report_measurements.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/modify_vcn_cidr_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/modify_vcn_cidr_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/multipath_device.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/nat_gateway.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/network_security_group.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/network_security_group_vnic.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/networking_topology.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/paravirtualized_volume_attachment.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/peer_region_for_remote_peering.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/phase_one_config_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/phase_two_config_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/platform_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/port_range.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/preemptible_instance_config_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/preemption_action.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/private_ip.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip_pool.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip_pool_collection.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip_pool_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/remote_peering_connection.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/remote_peering_connection_drg_attachment_network_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_distribution_statements_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_distribution_statements_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_rules_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_rules_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/remove_export_drg_route_distribution_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/remove_image_shape_compatibility_entry_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/remove_import_drg_route_distribution_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/remove_network_security_group_security_rules_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/remove_network_security_group_security_rules_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/remove_public_ip_pool_capacity_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/remove_public_ip_pool_capacity_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/remove_vcn_cidr_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/remove_vcn_cidr_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/reset_instance_pool_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/route_rule.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/route_table.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/security_list.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/security_rule.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/service.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/service_gateway.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/service_id_request_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/service_id_response_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/shape.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/shape_max_vnic_attachment_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/shape_measured_boot_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/shape_memory_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/shape_networking_bandwidth_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/shape_numa_nodes_per_socket_platform_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/shape_ocpu_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/shape_platform_config_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/shape_secure_boot_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/shape_trusted_platform_module_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/softreset_instance_pool_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/start_instance_pool_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/stop_instance_pool_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/subnet.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/subnet_topology.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/tcp_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_cluster_network_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_instance_pool_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_instance_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_preemption_action.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/topology.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/topology_associated_with_entity_relationship.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/topology_associated_with_relationship_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/topology_contains_entity_relationship.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/topology_entity_relationship.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/topology_routes_to_entity_relationship.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/topology_routes_to_relationship_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_cpe_device_config.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_phase_one_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_phase_two_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_route_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_security_association_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_status.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/udp_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_backup_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_backup_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_kms_key_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_kms_key_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_byoip_range_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_byoip_range_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_cluster_network_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_cluster_network_instance_pool_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_cluster_network_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_capacity_reservation_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_capacity_reservation_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_image_capability_schema_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_image_capability_schema_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_console_history_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_console_history_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_cpe_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_cpe_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_group_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_dedicated_vm_host_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_dedicated_vm_host_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_dhcp_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_dhcp_options_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_attachment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_attachment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_statement_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_statements_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_statements_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_rule_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_rules_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_rules_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_table_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_table_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_i_p_sec_connection_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_i_p_sec_connection_tunnel_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_i_p_sec_connection_tunnel_shared_secret_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_image_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_image_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_agent_config_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_availability_config_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_configuration_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_configuration_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_console_connection_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_console_connection_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_pool_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_pool_placement_configuration_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_pool_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_shape_config_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_internet_gateway_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_internet_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_connection_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_connection_tunnel_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_connection_tunnel_shared_secret_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_tunnel_bgp_session_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_tunnel_encryption_domain_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_ipv6_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_ipv6_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_launch_options.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_local_peering_gateway_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_local_peering_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_macsec_key.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_macsec_properties.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_nat_gateway_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_nat_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_security_rules_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_security_rules_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_private_ip_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_private_ip_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_pool_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_pool_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_remote_peering_connection_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_remote_peering_connection_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_route_table_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_route_table_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_security_list_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_security_list_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_security_rule_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_service_gateway_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_service_gateway_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_subnet_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_subnet_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_tunnel_cpe_device_config_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_tunnel_cpe_device_config_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_vcn_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_vcn_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_virtual_circuit_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_virtual_circuit_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_vlan_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_vlan_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_vnic_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_vnic_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_attachment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_attachment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_policy_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_backup_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_backup_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_kms_key_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_kms_key_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/updated_network_security_group_security_rules.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/upgrade_drg_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/upgrade_status.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/validate_byoip_range_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/vcn.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_dns_resolver_association.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_drg_attachment_network_create_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_drg_attachment_network_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_drg_attachment_network_update_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_topology.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_bandwidth_shape.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_drg_attachment_network_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_ip_mtu.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_public_prefix.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/vlan.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/vnic.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/vnic_attachment.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_attachment.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup_policy.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup_policy_assignment.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup_schedule.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_backup.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_from_volume_group_backup_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_from_volume_group_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_from_volumes_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_kms_key.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_from_block_volume_replica_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_from_volume_backup_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_from_volume_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/core/withdraw_byoip_range_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/activate_domain_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/activate_mfa_totp_device_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/add_user_to_group_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/add_user_to_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/allowed_domain_license_type_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/api_key.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/assemble_effective_tag_set_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/auth_token.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/authentication_policy.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/availability_domain.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/base_tag_definition_validator.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_action_resource.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_action_resource_type.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_action_resource_type_collection.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_resources_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_resources_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_tags_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_tags_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_operation_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_resource.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_resource_type.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_resource_type_collection.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_move_resources_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_move_resources_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/cascade_delete_tag_namespace_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_license_type_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_license_type_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/change_tag_namespace_compartment_detail.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/change_tag_namespace_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/change_tas_domain_license_type_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/compartment.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_api_key_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_auth_token_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_auth_token_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_customer_secret_key_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_customer_secret_key_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_db_credential_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_db_credential_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_domain_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_domain_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_dynamic_group_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_dynamic_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_group_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_identity_provider_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_identity_provider_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_idp_group_mapping_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_idp_group_mapping_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_mfa_totp_device_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_network_source_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_network_source_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_o_auth2_client_credential_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_o_auth_client_credential_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_or_reset_u_i_password_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_policy_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_region_subscription_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_region_subscription_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_saml2_identity_provider_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_smtp_credential_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_smtp_credential_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_swift_password_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_swift_password_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_default_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_default_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_namespace_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_namespace_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_user_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/create_user_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/customer_secret_key.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/customer_secret_key_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/db_credential.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/db_credential_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/deactivate_domain_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/default_tag_definition_validator.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_api_key_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_auth_token_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_customer_secret_key_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_db_credential_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_domain_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_dynamic_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_identity_provider_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_idp_group_mapping_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_mfa_totp_device_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_network_source_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_o_auth_client_credential_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_smtp_credential_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_swift_password_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_tag_default_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_tag_namespace_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_tag_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_user_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/domain.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/domain_replication.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/domain_replication_states.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/domain_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/dynamic_group.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/enable_replication_to_region_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/enable_replication_to_region_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/enum_tag_definition_validator.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/fault_domain.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/fully_qualified_scope.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/generate_totp_seed_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_authentication_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_domain_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_dynamic_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_iam_work_request_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_identity_provider_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_idp_group_mapping_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_mfa_totp_device_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_network_source_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_standard_tag_template_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tag_default_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tag_namespace_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tag_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tagging_work_request_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tenancy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_user_group_membership_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_user_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_user_u_i_password_information_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/get_work_request_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/group.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_error_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_log_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_resource.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/identity_client.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/identity_provider.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/identity_provider_group_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/idp_group_mapping.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/import_standard_tags_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/import_standard_tags_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_allowed_domain_license_types_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_api_keys_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_auth_tokens_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_availability_domains_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_bulk_action_resource_types_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_bulk_edit_tags_resource_types_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_compartments_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_cost_tracking_tags_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_customer_secret_keys_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_db_credentials_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_domains_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_dynamic_groups_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_fault_domains_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_groups_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_iam_work_request_errors_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_iam_work_request_logs_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_iam_work_requests_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_identity_provider_groups_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_identity_providers_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_idp_group_mappings_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_mfa_totp_devices_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_network_sources_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_o_auth_client_credentials_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_policies_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_region_subscriptions_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_regions_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_smtp_credentials_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_standard_tag_namespaces_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_swift_passwords_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tag_defaults_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tag_namespaces_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tagging_work_request_errors_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tagging_work_request_logs_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tagging_work_requests_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tags_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_user_group_memberships_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_users_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/list_work_requests_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/mfa_totp_device.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/mfa_totp_device_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/mfa_totp_token.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/move_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/move_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/network_policy.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/network_sources.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/network_sources_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/network_sources_virtual_source_list.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/o_auth2_client_credential.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/o_auth2_client_credential_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/password_policy.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/policy.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/recover_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/region.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/region_subscription.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/remove_user_from_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/replicated_region_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/reset_idp_scim_client_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/saml2_identity_provider.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/scim_client_credentials.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/smtp_credential.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/smtp_credential_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/standard_tag_definition_template.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/standard_tag_namespace_template.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/standard_tag_namespace_template_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/swift_password.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/tag.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_default.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_default_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_namespace.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_namespace_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request_error_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request_log_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/tenancy.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/ui_password.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/ui_password_information.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_auth_token_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_auth_token_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_authentication_policy_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_authentication_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_compartment_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_compartment_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_customer_secret_key_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_customer_secret_key_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_domain_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_domain_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_dynamic_group_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_dynamic_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_group_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_group_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_identity_provider_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_identity_provider_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_idp_group_mapping_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_idp_group_mapping_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_network_source_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_network_source_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_o_auth2_client_credential_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_o_auth_client_credential_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_policy_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_saml2_identity_provider_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_smtp_credential_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_smtp_credential_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_state_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_swift_password_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_swift_password_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_default_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_default_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_namespace_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_namespace_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_capabilities_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_capabilities_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_state_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/upload_api_key_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/user.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/user_capabilities.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/user_group_membership.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_error.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_log_entry.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_resource.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/abort_multipart_upload_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/archival_state.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/bucket.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/bucket_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/cancel_work_request_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/commit_multipart_upload_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/commit_multipart_upload_part_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/commit_multipart_upload_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/copy_object_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/copy_object_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_bucket_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_bucket_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_multipart_upload_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_multipart_upload_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_preauthenticated_request_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_preauthenticated_request_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_replication_policy_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_replication_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_retention_rule_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_retention_rule_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_bucket_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_object_lifecycle_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_object_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_preauthenticated_request_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_replication_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_retention_rule_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/duration.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_bucket_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_namespace_metadata_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_namespace_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_object_lifecycle_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_object_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_preauthenticated_request_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_replication_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_retention_rule_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_work_request_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/head_bucket_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/head_object_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_buckets_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_multipart_upload_parts_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_multipart_uploads_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_object_versions_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_objects.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_objects_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_preauthenticated_requests_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_replication_policies_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_replication_sources_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_retention_rules_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_work_request_errors_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_work_request_logs_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_work_requests_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/make_bucket_writable_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/multipart_upload.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/multipart_upload_part_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/namespace_metadata.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_lifecycle_policy.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_lifecycle_rule.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_name_filter.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_version_collection.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_version_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/objectstorage_client.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/pattern_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/preauthenticated_request.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/preauthenticated_request_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/put_object_lifecycle_policy_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/put_object_lifecycle_policy_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/put_object_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/reencrypt_bucket_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/reencrypt_object_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/reencrypt_object_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/rename_object_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/rename_object_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/replication_policy.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/replication_policy_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/replication_source.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/restore_objects_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/restore_objects_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule_collection.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/sse_customer_key_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/storage_tier.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/file_uploader.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/file_uploader_req_resp.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/multipart_manifest.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/mutipart_uploader.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/stream_uploader.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/stream_uploader_req_resp.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/upload_manager.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/upload_manager_req_resp.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_bucket_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_bucket_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_namespace_metadata_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_namespace_metadata_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_object_storage_tier_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_object_storage_tier_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_retention_rule_details.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_retention_rule_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/upload_part_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_error.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_log_entry.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_resource.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_resource_metadata_key.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/workrequests/get_work_request_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/workrequests/list_work_request_errors_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/workrequests/list_work_request_logs_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/workrequests/list_work_requests_request_response.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_error.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_log_entry.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_resource.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_summary.go create mode 100644 vendor/github.com/oracle/oci-go-sdk/v54/workrequests/workrequests_workrequest_client.go create mode 100644 vendor/github.com/sony/gobreaker/.travis.yml create mode 100644 vendor/github.com/sony/gobreaker/LICENSE create mode 100644 vendor/github.com/sony/gobreaker/README.md create mode 100644 vendor/github.com/sony/gobreaker/go.mod create mode 100644 vendor/github.com/sony/gobreaker/go.sum create mode 100644 vendor/github.com/sony/gobreaker/gobreaker.go create mode 100644 vendor/github.com/spf13/cobra/.gitignore create mode 100644 vendor/github.com/spf13/cobra/.mailmap create mode 100644 vendor/github.com/spf13/cobra/.travis.yml create mode 100644 vendor/github.com/spf13/cobra/LICENSE.txt create mode 100644 vendor/github.com/spf13/cobra/README.md create mode 100644 vendor/github.com/spf13/cobra/args.go create mode 100644 vendor/github.com/spf13/cobra/bash_completions.go create mode 100644 vendor/github.com/spf13/cobra/bash_completions.md create mode 100644 vendor/github.com/spf13/cobra/cobra.go create mode 100644 vendor/github.com/spf13/cobra/command.go create mode 100644 vendor/github.com/spf13/cobra/command_notwin.go create mode 100644 vendor/github.com/spf13/cobra/command_win.go create mode 100644 vendor/github.com/spf13/cobra/zsh_completions.go create mode 100644 vendor/github.com/spf13/pflag/.gitignore create mode 100644 vendor/github.com/spf13/pflag/.travis.yml create mode 100644 vendor/github.com/spf13/pflag/LICENSE create mode 100644 vendor/github.com/spf13/pflag/README.md create mode 100644 vendor/github.com/spf13/pflag/bool.go create mode 100644 vendor/github.com/spf13/pflag/bool_slice.go create mode 100644 vendor/github.com/spf13/pflag/bytes.go create mode 100644 vendor/github.com/spf13/pflag/count.go create mode 100644 vendor/github.com/spf13/pflag/duration.go create mode 100644 vendor/github.com/spf13/pflag/duration_slice.go create mode 100644 vendor/github.com/spf13/pflag/flag.go create mode 100644 vendor/github.com/spf13/pflag/float32.go create mode 100644 vendor/github.com/spf13/pflag/float64.go create mode 100644 vendor/github.com/spf13/pflag/golangflag.go create mode 100644 vendor/github.com/spf13/pflag/int.go create mode 100644 vendor/github.com/spf13/pflag/int16.go create mode 100644 vendor/github.com/spf13/pflag/int32.go create mode 100644 vendor/github.com/spf13/pflag/int64.go create mode 100644 vendor/github.com/spf13/pflag/int8.go create mode 100644 vendor/github.com/spf13/pflag/int_slice.go create mode 100644 vendor/github.com/spf13/pflag/ip.go create mode 100644 vendor/github.com/spf13/pflag/ip_slice.go create mode 100644 vendor/github.com/spf13/pflag/ipmask.go create mode 100644 vendor/github.com/spf13/pflag/ipnet.go create mode 100644 vendor/github.com/spf13/pflag/string.go create mode 100644 vendor/github.com/spf13/pflag/string_array.go create mode 100644 vendor/github.com/spf13/pflag/string_slice.go create mode 100644 vendor/github.com/spf13/pflag/uint.go create mode 100644 vendor/github.com/spf13/pflag/uint16.go create mode 100644 vendor/github.com/spf13/pflag/uint32.go create mode 100644 vendor/github.com/spf13/pflag/uint64.go create mode 100644 vendor/github.com/spf13/pflag/uint8.go create mode 100644 vendor/github.com/spf13/pflag/uint_slice.go diff --git a/go.mod b/go.mod index ee6685219..333fffc38 100644 --- a/go.mod +++ b/go.mod @@ -37,11 +37,13 @@ require ( github.com/labstack/echo/v4 v4.6.1 github.com/labstack/gommon v0.3.0 github.com/openshift-online/ocm-sdk-go v0.1.214 + github.com/oracle/oci-go-sdk/v54 v54.0.0 github.com/prometheus/client_golang v1.11.0 github.com/prometheus/common v0.30.0 // indirect github.com/prometheus/procfs v0.7.3 // indirect github.com/segmentio/ksuid v1.0.4 github.com/sirupsen/logrus v1.8.1 + github.com/spf13/cobra v0.0.3 github.com/stretchr/testify v1.7.0 github.com/ubccr/kerby v0.0.0-20170626144437-201a958fc453 github.com/vmware/govmomi v0.26.1 diff --git a/go.sum b/go.sum index 4a7a8c6cc..9a371c4c2 100644 --- a/go.sum +++ b/go.sum @@ -348,6 +348,7 @@ github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpO github.com/hudl/fargo v1.3.0/go.mod h1:y3CKSmjA+wD2gak7sUSXTAoopbhU08POFhmITJgmKTg= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= +github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NHg9XEKhtSvM= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= github.com/influxdata/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= github.com/jackc/chunkreader v1.0.0 h1:4s39bBR8ByfqH+DKm8rQA3E1LHZWB9XWcrz8fqaZbe0= @@ -544,6 +545,8 @@ github.com/openzipkin-contrib/zipkin-go-opentracing v0.4.5/go.mod h1:/wsWhb9smxS github.com/openzipkin/zipkin-go v0.1.6/go.mod h1:QgAqvLzwWbR/WpD4A3cGpPtJrZXNIiJc5AZX7/PBEpw= github.com/openzipkin/zipkin-go v0.2.1/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnhQw8ySjnjRyN4= github.com/openzipkin/zipkin-go v0.2.2/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnhQw8ySjnjRyN4= +github.com/oracle/oci-go-sdk/v54 v54.0.0 h1:CDLjeSejv2aDpElAJrhKpi6zvT/zhZCZuXchUUZ+LS4= +github.com/oracle/oci-go-sdk/v54 v54.0.0/go.mod h1:+t+yvcFGVp+3ZnztnyxqXfQDsMlq8U25faBLa+mqCMc= github.com/pact-foundation/pact-go v1.0.4/go.mod h1:uExwJY4kCzNPcHRj+hCR/HBbOOIwwtUjcrb0b5/5kLM= github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pborman/uuid v1.2.0/go.mod h1:X/NO0urCmaxf9VXbdlT7C2Yzkj2IKimNn4k+gtPdI/k= @@ -621,14 +624,19 @@ github.com/smartystreets/goconvey v1.6.4 h1:fv0U8FUIMPNf1L9lnHLvLhgicrIVChEkdzIK github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM= github.com/sony/gobreaker v0.4.1/go.mod h1:ZKptC7FHNvhBz7dN2LGjPVBz2sZJmc0/PkyDJOjmxWY= +github.com/sony/gobreaker v0.4.2-0.20210216022020-dd874f9dd33b h1:br+bPNZsJWKicw/5rALEo67QHs5weyD5tf8WST+4sJ0= +github.com/sony/gobreaker v0.4.2-0.20210216022020-dd874f9dd33b/go.mod h1:ZKptC7FHNvhBz7dN2LGjPVBz2sZJmc0/PkyDJOjmxWY= github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= +github.com/spf13/cobra v0.0.3 h1:ZlrZ4XsMRm04Fr5pSFxBgfND2EBVa1nLpiy1stUsX/8= github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ= +github.com/spf13/pflag v1.0.1 h1:aCvUg6QPl3ibpQUxyLkrEkCHtPqYJL4x9AuhqVqFis4= github.com/spf13/pflag v1.0.1/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/streadway/amqp v0.0.0-20190404075320-75d898a42a94/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= github.com/streadway/amqp v0.0.0-20190827072141-edfb9018d271/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= github.com/streadway/handy v0.0.0-20190108123426-d5acb3125c2a/go.mod h1:qNTQ5P5JnDBl6z3cMAg/SywNDC5ABu5ApDIw6lUbRmI= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= +github.com/stretchr/objx v0.2.0 h1:Hbg2NidpLE8veEBkEZTL3CvlkUIVzuU9jDplZO54c48= github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= diff --git a/vendor/github.com/inconshreveable/mousetrap/LICENSE b/vendor/github.com/inconshreveable/mousetrap/LICENSE new file mode 100644 index 000000000..5f0d1fb6a --- /dev/null +++ b/vendor/github.com/inconshreveable/mousetrap/LICENSE @@ -0,0 +1,13 @@ +Copyright 2014 Alan Shreve + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. diff --git a/vendor/github.com/inconshreveable/mousetrap/README.md b/vendor/github.com/inconshreveable/mousetrap/README.md new file mode 100644 index 000000000..7a950d177 --- /dev/null +++ b/vendor/github.com/inconshreveable/mousetrap/README.md @@ -0,0 +1,23 @@ +# mousetrap + +mousetrap is a tiny library that answers a single question. + +On a Windows machine, was the process invoked by someone double clicking on +the executable file while browsing in explorer? + +### Motivation + +Windows developers unfamiliar with command line tools will often "double-click" +the executable for a tool. Because most CLI tools print the help and then exit +when invoked without arguments, this is often very frustrating for those users. + +mousetrap provides a way to detect these invocations so that you can provide +more helpful behavior and instructions on how to run the CLI tool. To see what +this looks like, both from an organizational and a technical perspective, see +https://inconshreveable.com/09-09-2014/sweat-the-small-stuff/ + +### The interface + +The library exposes a single interface: + + func StartedByExplorer() (bool) diff --git a/vendor/github.com/inconshreveable/mousetrap/trap_others.go b/vendor/github.com/inconshreveable/mousetrap/trap_others.go new file mode 100644 index 000000000..9d2d8a4ba --- /dev/null +++ b/vendor/github.com/inconshreveable/mousetrap/trap_others.go @@ -0,0 +1,15 @@ +// +build !windows + +package mousetrap + +// StartedByExplorer returns true if the program was invoked by the user +// double-clicking on the executable from explorer.exe +// +// It is conservative and returns false if any of the internal calls fail. +// It does not guarantee that the program was run from a terminal. It only can tell you +// whether it was launched from explorer.exe +// +// On non-Windows platforms, it always returns false. +func StartedByExplorer() bool { + return false +} diff --git a/vendor/github.com/inconshreveable/mousetrap/trap_windows.go b/vendor/github.com/inconshreveable/mousetrap/trap_windows.go new file mode 100644 index 000000000..336142a5e --- /dev/null +++ b/vendor/github.com/inconshreveable/mousetrap/trap_windows.go @@ -0,0 +1,98 @@ +// +build windows +// +build !go1.4 + +package mousetrap + +import ( + "fmt" + "os" + "syscall" + "unsafe" +) + +const ( + // defined by the Win32 API + th32cs_snapprocess uintptr = 0x2 +) + +var ( + kernel = syscall.MustLoadDLL("kernel32.dll") + CreateToolhelp32Snapshot = kernel.MustFindProc("CreateToolhelp32Snapshot") + Process32First = kernel.MustFindProc("Process32FirstW") + Process32Next = kernel.MustFindProc("Process32NextW") +) + +// ProcessEntry32 structure defined by the Win32 API +type processEntry32 struct { + dwSize uint32 + cntUsage uint32 + th32ProcessID uint32 + th32DefaultHeapID int + th32ModuleID uint32 + cntThreads uint32 + th32ParentProcessID uint32 + pcPriClassBase int32 + dwFlags uint32 + szExeFile [syscall.MAX_PATH]uint16 +} + +func getProcessEntry(pid int) (pe *processEntry32, err error) { + snapshot, _, e1 := CreateToolhelp32Snapshot.Call(th32cs_snapprocess, uintptr(0)) + if snapshot == uintptr(syscall.InvalidHandle) { + err = fmt.Errorf("CreateToolhelp32Snapshot: %v", e1) + return + } + defer syscall.CloseHandle(syscall.Handle(snapshot)) + + var processEntry processEntry32 + processEntry.dwSize = uint32(unsafe.Sizeof(processEntry)) + ok, _, e1 := Process32First.Call(snapshot, uintptr(unsafe.Pointer(&processEntry))) + if ok == 0 { + err = fmt.Errorf("Process32First: %v", e1) + return + } + + for { + if processEntry.th32ProcessID == uint32(pid) { + pe = &processEntry + return + } + + ok, _, e1 = Process32Next.Call(snapshot, uintptr(unsafe.Pointer(&processEntry))) + if ok == 0 { + err = fmt.Errorf("Process32Next: %v", e1) + return + } + } +} + +func getppid() (pid int, err error) { + pe, err := getProcessEntry(os.Getpid()) + if err != nil { + return + } + + pid = int(pe.th32ParentProcessID) + return +} + +// StartedByExplorer returns true if the program was invoked by the user double-clicking +// on the executable from explorer.exe +// +// It is conservative and returns false if any of the internal calls fail. +// It does not guarantee that the program was run from a terminal. It only can tell you +// whether it was launched from explorer.exe +func StartedByExplorer() bool { + ppid, err := getppid() + if err != nil { + return false + } + + pe, err := getProcessEntry(ppid) + if err != nil { + return false + } + + name := syscall.UTF16ToString(pe.szExeFile[:]) + return name == "explorer.exe" +} diff --git a/vendor/github.com/inconshreveable/mousetrap/trap_windows_1.4.go b/vendor/github.com/inconshreveable/mousetrap/trap_windows_1.4.go new file mode 100644 index 000000000..9a28e57c3 --- /dev/null +++ b/vendor/github.com/inconshreveable/mousetrap/trap_windows_1.4.go @@ -0,0 +1,46 @@ +// +build windows +// +build go1.4 + +package mousetrap + +import ( + "os" + "syscall" + "unsafe" +) + +func getProcessEntry(pid int) (*syscall.ProcessEntry32, error) { + snapshot, err := syscall.CreateToolhelp32Snapshot(syscall.TH32CS_SNAPPROCESS, 0) + if err != nil { + return nil, err + } + defer syscall.CloseHandle(snapshot) + var procEntry syscall.ProcessEntry32 + procEntry.Size = uint32(unsafe.Sizeof(procEntry)) + if err = syscall.Process32First(snapshot, &procEntry); err != nil { + return nil, err + } + for { + if procEntry.ProcessID == uint32(pid) { + return &procEntry, nil + } + err = syscall.Process32Next(snapshot, &procEntry) + if err != nil { + return nil, err + } + } +} + +// StartedByExplorer returns true if the program was invoked by the user double-clicking +// on the executable from explorer.exe +// +// It is conservative and returns false if any of the internal calls fail. +// It does not guarantee that the program was run from a terminal. It only can tell you +// whether it was launched from explorer.exe +func StartedByExplorer() bool { + pe, err := getProcessEntry(os.Getppid()) + if err != nil { + return false + } + return "explorer.exe" == syscall.UTF16ToString(pe.ExeFile[:]) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/LICENSE.txt b/vendor/github.com/oracle/oci-go-sdk/v54/LICENSE.txt new file mode 100644 index 000000000..2b28b149d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/LICENSE.txt @@ -0,0 +1,82 @@ +Copyright (c) 2016, 2018, 2020, Oracle and/or its affiliates. All rights reserved. +This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl +or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + ____________________________ +The Universal Permissive License (UPL), Version 1.0 +Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved. + +Subject to the condition set forth below, permission is hereby granted to any person obtaining a copy of this software, associated documentation and/or data (collectively the "Software"), free of charge and under any and all copyright rights in the Software, and any and all patent rights owned or freely licensable by each licensor hereunder covering either (i) the unmodified Software as contributed to or provided by such licensor, or (ii) the Larger Works (as defined below), to deal in both + +(a) the Software, and +(b) any piece of software and/or hardware listed in the lrgrwrks.txt file if one is included with the Software (each a "Larger Work" to which the Software is contributed by such licensors), + +without restriction, including without limitation the rights to copy, create derivative works of, display, perform, and distribute the Software and make, use, sell, offer for sale, import, export, have made, and have sold the Software and the Larger Work(s), and to sublicense the foregoing rights on either these or other terms. + +This license is subject to the following condition: + +The above copyright notice and either this complete permission notice or at a minimum a reference to the UPL must be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +The Apache Software License, Version 2.0 +Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved. + +Licensed under the Apache License, Version 2.0 (the "License"); You may not use this product except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0. A copy of the license is also reproduced below. Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. + +Apache License + +Version 2.0, January 2004 + +http://www.apache.org/licenses/ +TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION +1. Definitions. +"License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. +"Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. +"Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. +"You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. +"Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. +"Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. +"Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). +"Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. +"Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." +"Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. +2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. +3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. +4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: +You must give any other recipients of the Work or Derivative Works a copy of this License; and +You must cause any modified files to carry prominent notices stating that You changed the files; and +You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and +If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. + +You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. +5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. +6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. +7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. +8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. +9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. +END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/NOTICE.txt b/vendor/github.com/oracle/oci-go-sdk/v54/NOTICE.txt new file mode 100644 index 000000000..55a68d59c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/NOTICE.txt @@ -0,0 +1 @@ +Copyright (c) 2016, 2018, 2020, Oracle and/or its affiliates. \ No newline at end of file diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/certificate_retriever.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/certificate_retriever.go new file mode 100644 index 000000000..5125299e9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/certificate_retriever.go @@ -0,0 +1,261 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package auth + +import ( + "bytes" + "crypto/rsa" + "crypto/x509" + "encoding/pem" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" + "sync" +) + +// x509CertificateRetriever provides an X509 certificate with the RSA private key +type x509CertificateRetriever interface { + Refresh() error + CertificatePemRaw() []byte + Certificate() *x509.Certificate + PrivateKeyPemRaw() []byte + PrivateKey() *rsa.PrivateKey +} + +// urlBasedX509CertificateRetriever retrieves PEM-encoded X509 certificates from the given URLs. +type urlBasedX509CertificateRetriever struct { + certURL string + privateKeyURL string + passphrase string + certificatePemRaw []byte + certificate *x509.Certificate + privateKeyPemRaw []byte + privateKey *rsa.PrivateKey + mux sync.Mutex + dispatcher common.HTTPRequestDispatcher +} + +func newURLBasedX509CertificateRetriever(dispatcher common.HTTPRequestDispatcher, certURL, privateKeyURL, passphrase string) x509CertificateRetriever { + return &urlBasedX509CertificateRetriever{ + certURL: certURL, + privateKeyURL: privateKeyURL, + passphrase: passphrase, + mux: sync.Mutex{}, + dispatcher: dispatcher, + } +} + +// Refresh() is failure atomic, i.e., CertificatePemRaw(), Certificate(), PrivateKeyPemRaw(), and PrivateKey() would +// return their previous values if Refresh() fails. +func (r *urlBasedX509CertificateRetriever) Refresh() error { + common.Debugln("Refreshing certificate") + + r.mux.Lock() + defer r.mux.Unlock() + + var err error + + var certificatePemRaw []byte + var certificate *x509.Certificate + if certificatePemRaw, certificate, err = r.renewCertificate(r.certURL); err != nil { + return fmt.Errorf("failed to renew certificate: %s", err.Error()) + } + + var privateKeyPemRaw []byte + var privateKey *rsa.PrivateKey + if r.privateKeyURL != "" { + if privateKeyPemRaw, privateKey, err = r.renewPrivateKey(r.privateKeyURL, r.passphrase); err != nil { + return fmt.Errorf("failed to renew private key: %s", err.Error()) + } + } + + r.certificatePemRaw = certificatePemRaw + r.certificate = certificate + r.privateKeyPemRaw = privateKeyPemRaw + r.privateKey = privateKey + return nil +} + +func (r *urlBasedX509CertificateRetriever) renewCertificate(url string) (certificatePemRaw []byte, certificate *x509.Certificate, err error) { + var body bytes.Buffer + if body, _, err = httpGet(r.dispatcher, url); err != nil { + return nil, nil, fmt.Errorf("failed to get certificate from %s: %s", url, err.Error()) + } + + certificatePemRaw = body.Bytes() + var block *pem.Block + block, _ = pem.Decode(certificatePemRaw) + if block == nil { + return nil, nil, fmt.Errorf("failed to parse the new certificate, not valid pem data") + } + + if certificate, err = x509.ParseCertificate(block.Bytes); err != nil { + return nil, nil, fmt.Errorf("failed to parse the new certificate: %s", err.Error()) + } + + return certificatePemRaw, certificate, nil +} + +func (r *urlBasedX509CertificateRetriever) renewPrivateKey(url, passphrase string) (privateKeyPemRaw []byte, privateKey *rsa.PrivateKey, err error) { + var body bytes.Buffer + if body, _, err = httpGet(r.dispatcher, url); err != nil { + return nil, nil, fmt.Errorf("failed to get private key from %s: %s", url, err.Error()) + } + + privateKeyPemRaw = body.Bytes() + if privateKey, err = common.PrivateKeyFromBytes(privateKeyPemRaw, &passphrase); err != nil { + return nil, nil, fmt.Errorf("failed to parse the new private key: %s", err.Error()) + } + + return privateKeyPemRaw, privateKey, nil +} + +func (r *urlBasedX509CertificateRetriever) CertificatePemRaw() []byte { + r.mux.Lock() + defer r.mux.Unlock() + + if r.certificatePemRaw == nil { + return nil + } + + c := make([]byte, len(r.certificatePemRaw)) + copy(c, r.certificatePemRaw) + return c +} + +func (r *urlBasedX509CertificateRetriever) Certificate() *x509.Certificate { + r.mux.Lock() + defer r.mux.Unlock() + + if r.certificate == nil { + return nil + } + + c := *r.certificate + return &c +} + +func (r *urlBasedX509CertificateRetriever) PrivateKeyPemRaw() []byte { + r.mux.Lock() + defer r.mux.Unlock() + + if r.privateKeyPemRaw == nil { + return nil + } + + c := make([]byte, len(r.privateKeyPemRaw)) + copy(c, r.privateKeyPemRaw) + return c +} + +func (r *urlBasedX509CertificateRetriever) PrivateKey() *rsa.PrivateKey { + r.mux.Lock() + defer r.mux.Unlock() + + //Nil Private keys are supported as part of a certificate + if r.privateKey == nil { + return nil + } + + c := *r.privateKey + return &c +} + +//staticCertificateRetriever serves certificates from static data +type staticCertificateRetriever struct { + Passphrase []byte + CertificatePem []byte + PrivateKeyPem []byte + certificate *x509.Certificate + privateKey *rsa.PrivateKey + mux sync.Mutex +} + +//Refresh proccess the inputs into appropiate keys and certificates +func (r *staticCertificateRetriever) Refresh() error { + r.mux.Lock() + defer r.mux.Unlock() + + certifcate, err := r.readCertificate() + if err != nil { + r.certificate = nil + return err + } + r.certificate = certifcate + + key, err := r.readPrivateKey() + if err != nil { + r.privateKey = nil + return err + } + r.privateKey = key + + return nil +} + +func (r *staticCertificateRetriever) Certificate() *x509.Certificate { + r.mux.Lock() + defer r.mux.Unlock() + + return r.certificate +} + +func (r *staticCertificateRetriever) PrivateKey() *rsa.PrivateKey { + r.mux.Lock() + defer r.mux.Unlock() + + return r.privateKey +} + +func (r *staticCertificateRetriever) CertificatePemRaw() []byte { + r.mux.Lock() + defer r.mux.Unlock() + + if r.CertificatePem == nil { + return nil + } + + c := make([]byte, len(r.CertificatePem)) + copy(c, r.CertificatePem) + return c +} + +func (r *staticCertificateRetriever) PrivateKeyPemRaw() []byte { + r.mux.Lock() + defer r.mux.Unlock() + + if r.PrivateKeyPem == nil { + return nil + } + + c := make([]byte, len(r.PrivateKeyPem)) + copy(c, r.PrivateKeyPem) + return c +} + +func (r *staticCertificateRetriever) readCertificate() (certificate *x509.Certificate, err error) { + block, _ := pem.Decode(r.CertificatePem) + if block == nil { + return nil, fmt.Errorf("failed to parse the new certificate, not valid pem data") + } + + if certificate, err = x509.ParseCertificate(block.Bytes); err != nil { + return nil, fmt.Errorf("failed to parse the new certificate: %s", err.Error()) + } + return certificate, nil +} + +func (r *staticCertificateRetriever) readPrivateKey() (*rsa.PrivateKey, error) { + if r.PrivateKeyPem == nil { + return nil, nil + } + + var pass *string + if r.Passphrase == nil { + pass = nil + } else { + ss := string(r.Passphrase) + pass = &ss + } + return common.PrivateKeyFromBytes(r.PrivateKeyPem, pass) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/configuration.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/configuration.go new file mode 100644 index 000000000..effbbb4eb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/configuration.go @@ -0,0 +1,110 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package auth + +import ( + "crypto/rsa" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" +) + +type instancePrincipalConfigurationProvider struct { + keyProvider instancePrincipalKeyProvider + region *common.Region +} + +//InstancePrincipalConfigurationProvider returns a configuration for instance principals +func InstancePrincipalConfigurationProvider() (common.ConfigurationProvider, error) { + return newInstancePrincipalConfigurationProvider("", nil) +} + +//InstancePrincipalConfigurationProviderForRegion returns a configuration for instance principals with a given region +func InstancePrincipalConfigurationProviderForRegion(region common.Region) (common.ConfigurationProvider, error) { + return newInstancePrincipalConfigurationProvider(region, nil) +} + +//InstancePrincipalConfigurationProviderWithCustomClient returns a configuration for instance principals using a modifier function to modify the HTTPRequestDispatcher +func InstancePrincipalConfigurationProviderWithCustomClient(modifier func(common.HTTPRequestDispatcher) (common.HTTPRequestDispatcher, error)) (common.ConfigurationProvider, error) { + return newInstancePrincipalConfigurationProvider("", modifier) +} + +//InstancePrincipalConfigurationForRegionWithCustomClient returns a configuration for instance principals with a given region using a modifier function to modify the HTTPRequestDispatcher +func InstancePrincipalConfigurationForRegionWithCustomClient(region common.Region, modifier func(common.HTTPRequestDispatcher) (common.HTTPRequestDispatcher, error)) (common.ConfigurationProvider, error) { + return newInstancePrincipalConfigurationProvider(region, modifier) +} + +func newInstancePrincipalConfigurationProvider(region common.Region, modifier func(common.HTTPRequestDispatcher) (common.HTTPRequestDispatcher, error)) (common.ConfigurationProvider, error) { + var err error + var keyProvider *instancePrincipalKeyProvider + if keyProvider, err = newInstancePrincipalKeyProvider(modifier); err != nil { + return nil, fmt.Errorf("failed to create a new key provider for instance principal: %s", err.Error()) + } + if len(region) > 0 { + return instancePrincipalConfigurationProvider{keyProvider: *keyProvider, region: ®ion}, nil + } + return instancePrincipalConfigurationProvider{keyProvider: *keyProvider, region: nil}, nil +} + +//InstancePrincipalConfigurationWithCerts returns a configuration for instance principals with a given region and hardcoded certificates in lieu of metadata service certs +func InstancePrincipalConfigurationWithCerts(region common.Region, leafCertificate, leafPassphrase, leafPrivateKey []byte, intermediateCertificates [][]byte) (common.ConfigurationProvider, error) { + leafCertificateRetriever := staticCertificateRetriever{Passphrase: leafPassphrase, CertificatePem: leafCertificate, PrivateKeyPem: leafPrivateKey} + + //The .Refresh() call actually reads the certificates from the inputs + err := leafCertificateRetriever.Refresh() + if err != nil { + return nil, err + } + + certificate := leafCertificateRetriever.Certificate() + + tenancyID := extractTenancyIDFromCertificate(certificate) + fedClient, err := newX509FederationClientWithCerts(region, tenancyID, leafCertificate, leafPassphrase, leafPrivateKey, intermediateCertificates, *newDispatcherModifier(nil)) + if err != nil { + return nil, err + } + + provider := instancePrincipalConfigurationProvider{ + keyProvider: instancePrincipalKeyProvider{ + Region: region, + FederationClient: fedClient, + TenancyID: tenancyID, + }, + region: ®ion, + } + return provider, nil + +} + +func (p instancePrincipalConfigurationProvider) PrivateRSAKey() (*rsa.PrivateKey, error) { + return p.keyProvider.PrivateRSAKey() +} + +func (p instancePrincipalConfigurationProvider) KeyID() (string, error) { + return p.keyProvider.KeyID() +} + +func (p instancePrincipalConfigurationProvider) TenancyOCID() (string, error) { + return p.keyProvider.TenancyOCID() +} + +func (p instancePrincipalConfigurationProvider) UserOCID() (string, error) { + return "", nil +} + +func (p instancePrincipalConfigurationProvider) KeyFingerprint() (string, error) { + return "", nil +} + +func (p instancePrincipalConfigurationProvider) Region() (string, error) { + if p.region == nil { + region := p.keyProvider.RegionForFederationClient() + common.Debugf("Region in instance principal configuration provider is nil. Returning federation clients region: %s", region) + return string(region), nil + } + return string(*p.region), nil +} + +func (p instancePrincipalConfigurationProvider) AuthType() (common.AuthConfig, error) { + return common.AuthConfig{common.InstancePrincipal, false, nil}, fmt.Errorf("unsupported, keep the interface") +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/dispatcher_modifier.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/dispatcher_modifier.go new file mode 100644 index 000000000..3f05d659d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/dispatcher_modifier.go @@ -0,0 +1,41 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package auth + +import "github.com/oracle/oci-go-sdk/v54/common" + +//dispatcherModifier gives ability to modify a HTTPRequestDispatcher before use. +type dispatcherModifier struct { + modifiers []func(common.HTTPRequestDispatcher) (common.HTTPRequestDispatcher, error) +} + +//newDispatcherModifier creates a new dispatcherModifier with optional initial modifier (may be nil). +func newDispatcherModifier(modifier func(common.HTTPRequestDispatcher) (common.HTTPRequestDispatcher, error)) *dispatcherModifier { + dispatcherModifier := &dispatcherModifier{ + modifiers: make([]func(common.HTTPRequestDispatcher) (common.HTTPRequestDispatcher, error), 0), + } + if modifier != nil { + dispatcherModifier.QueueModifier(modifier) + } + return dispatcherModifier +} + +//QueueModifier queues up a new modifier +func (c *dispatcherModifier) QueueModifier(modifier func(common.HTTPRequestDispatcher) (common.HTTPRequestDispatcher, error)) { + c.modifiers = append(c.modifiers, modifier) +} + +//Modify the provided HTTPRequestDispatcher with this modifier, and return the result, or error if something goes wrong +func (c *dispatcherModifier) Modify(dispatcher common.HTTPRequestDispatcher) (common.HTTPRequestDispatcher, error) { + if len(c.modifiers) > 0 { + for _, modifier := range c.modifiers { + var err error + if dispatcher, err = modifier(dispatcher); err != nil { + common.Debugf("An error occurred when attempting to modify the dispatcher. Error was: %s", err.Error()) + return nil, err + } + } + } + return dispatcher, nil +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/federation_client.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/federation_client.go new file mode 100644 index 000000000..fee9c3309 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/federation_client.go @@ -0,0 +1,569 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +// Package auth provides supporting functions and structs for authentication +package auth + +import ( + "context" + "crypto/rand" + "crypto/rsa" + "crypto/x509" + "encoding/pem" + "errors" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" + "io/ioutil" + "net/http" + "os" + "strings" + "sync" + "time" +) + +// federationClient is a client to retrieve the security token for an instance principal necessary to sign a request. +// It also provides the private key whose corresponding public key is used to retrieve the security token. +type federationClient interface { + ClaimHolder + PrivateKey() (*rsa.PrivateKey, error) + SecurityToken() (string, error) +} + +// ClaimHolder is implemented by any token interface that provides access to the security claims embedded in the token. +type ClaimHolder interface { + GetClaim(key string) (interface{}, error) +} + +type genericFederationClient struct { + SessionKeySupplier sessionKeySupplier + RefreshSecurityToken func() (securityToken, error) + + securityToken securityToken + mux sync.Mutex +} + +var _ federationClient = &genericFederationClient{} + +func (c *genericFederationClient) PrivateKey() (*rsa.PrivateKey, error) { + c.mux.Lock() + defer c.mux.Unlock() + + if err := c.renewKeyAndSecurityTokenIfNotValid(); err != nil { + return nil, err + } + return c.SessionKeySupplier.PrivateKey(), nil +} + +func (c *genericFederationClient) SecurityToken() (token string, err error) { + c.mux.Lock() + defer c.mux.Unlock() + + if err = c.renewKeyAndSecurityTokenIfNotValid(); err != nil { + return "", err + } + return c.securityToken.String(), nil +} + +func (c *genericFederationClient) renewKeyAndSecurityTokenIfNotValid() (err error) { + if c.securityToken == nil || !c.securityToken.Valid() { + if err = c.renewKeyAndSecurityToken(); err != nil { + return fmt.Errorf("failed to renew security token: %s", err.Error()) + } + } + return nil +} + +func (c *genericFederationClient) renewKeyAndSecurityToken() (err error) { + common.Logf("Renewing keys for file based security token at: %v\n", time.Now().Format("15:04:05.000")) + if err = c.SessionKeySupplier.Refresh(); err != nil { + return fmt.Errorf("failed to refresh session key: %s", err.Error()) + } + + common.Logf("Renewing security token at: %v\n", time.Now().Format("15:04:05.000")) + if c.securityToken, err = c.RefreshSecurityToken(); err != nil { + return fmt.Errorf("failed to refresh security token key: %s", err.Error()) + } + common.Logf("Security token renewed at: %v\n", time.Now().Format("15:04:05.000")) + return nil +} + +func (c *genericFederationClient) GetClaim(key string) (interface{}, error) { + c.mux.Lock() + defer c.mux.Unlock() + + if err := c.renewKeyAndSecurityTokenIfNotValid(); err != nil { + return nil, err + } + return c.securityToken.GetClaim(key) +} + +func newFileBasedFederationClient(securityTokenPath string, supplier sessionKeySupplier) (*genericFederationClient, error) { + return &genericFederationClient{ + SessionKeySupplier: supplier, + RefreshSecurityToken: func() (token securityToken, err error) { + var content []byte + if content, err = ioutil.ReadFile(securityTokenPath); err != nil { + return nil, fmt.Errorf("failed to read security token from :%s. Due to: %s", securityTokenPath, err.Error()) + } + + var newToken securityToken + if newToken, err = newPrincipalToken(string(content)); err != nil { + return nil, fmt.Errorf("failed to read security token from :%s. Due to: %s", securityTokenPath, err.Error()) + } + + return newToken, nil + }, + }, nil +} + +func newStaticFederationClient(sessionToken string, supplier sessionKeySupplier) (*genericFederationClient, error) { + var newToken securityToken + var err error + if newToken, err = newPrincipalToken(string(sessionToken)); err != nil { + return nil, fmt.Errorf("failed to read security token. Due to: %s", err.Error()) + } + + return &genericFederationClient{ + SessionKeySupplier: supplier, + RefreshSecurityToken: func() (token securityToken, err error) { + return newToken, nil + }, + }, nil +} + +// x509FederationClient retrieves a security token from Auth service. +type x509FederationClient struct { + tenancyID string + sessionKeySupplier sessionKeySupplier + leafCertificateRetriever x509CertificateRetriever + intermediateCertificateRetrievers []x509CertificateRetriever + securityToken securityToken + authClient *common.BaseClient + mux sync.Mutex +} + +func newX509FederationClient(region common.Region, tenancyID string, leafCertificateRetriever x509CertificateRetriever, intermediateCertificateRetrievers []x509CertificateRetriever, modifier dispatcherModifier) (federationClient, error) { + client := &x509FederationClient{ + tenancyID: tenancyID, + leafCertificateRetriever: leafCertificateRetriever, + intermediateCertificateRetrievers: intermediateCertificateRetrievers, + } + client.sessionKeySupplier = newSessionKeySupplier() + authClient := newAuthClient(region, client) + + var err error + + if authClient.HTTPClient, err = modifier.Modify(authClient.HTTPClient); err != nil { + err = fmt.Errorf("failed to modify client: %s", err.Error()) + return nil, err + } + + client.authClient = authClient + return client, nil +} + +func newX509FederationClientWithCerts(region common.Region, tenancyID string, leafCertificate, leafPassphrase, leafPrivateKey []byte, intermediateCertificates [][]byte, modifier dispatcherModifier) (federationClient, error) { + intermediateRetrievers := make([]x509CertificateRetriever, len(intermediateCertificates)) + for i, c := range intermediateCertificates { + intermediateRetrievers[i] = &staticCertificateRetriever{Passphrase: []byte(""), CertificatePem: c, PrivateKeyPem: nil} + } + + client := &x509FederationClient{ + tenancyID: tenancyID, + leafCertificateRetriever: &staticCertificateRetriever{Passphrase: leafPassphrase, CertificatePem: leafCertificate, PrivateKeyPem: leafPrivateKey}, + intermediateCertificateRetrievers: intermediateRetrievers, + } + client.sessionKeySupplier = newSessionKeySupplier() + authClient := newAuthClient(region, client) + + var err error + + if authClient.HTTPClient, err = modifier.Modify(authClient.HTTPClient); err != nil { + err = fmt.Errorf("failed to modify client: %s", err.Error()) + return nil, err + } + + client.authClient = authClient + return client, nil +} + +var ( + genericHeaders = []string{"date", "(request-target)"} // "host" is not needed for the federation endpoint. Don't ask me why. + bodyHeaders = []string{"content-length", "content-type", "x-content-sha256"} +) + +func newAuthClient(region common.Region, provider common.KeyProvider) *common.BaseClient { + signer := common.RequestSigner(provider, genericHeaders, bodyHeaders) + client := common.DefaultBaseClientWithSigner(signer) + if regionURL, ok := os.LookupEnv("OCI_SDK_AUTH_CLIENT_REGION_URL"); ok { + client.Host = regionURL + } else { + client.Host = region.Endpoint("auth") + } + client.BasePath = "v1/x509" + return &client +} + +// For authClient to sign requests to X509 Federation Endpoint +func (c *x509FederationClient) KeyID() (string, error) { + tenancy := c.tenancyID + fingerprint := fingerprint(c.leafCertificateRetriever.Certificate()) + return fmt.Sprintf("%s/fed-x509/%s", tenancy, fingerprint), nil +} + +// For authClient to sign requests to X509 Federation Endpoint +func (c *x509FederationClient) PrivateRSAKey() (*rsa.PrivateKey, error) { + key := c.leafCertificateRetriever.PrivateKey() + if key == nil { + return nil, fmt.Errorf("can not read private key from leaf certificate. Likely an error in the metadata service") + } + + return key, nil +} + +func (c *x509FederationClient) PrivateKey() (*rsa.PrivateKey, error) { + c.mux.Lock() + defer c.mux.Unlock() + + if err := c.renewSecurityTokenIfNotValid(); err != nil { + return nil, err + } + return c.sessionKeySupplier.PrivateKey(), nil +} + +func (c *x509FederationClient) SecurityToken() (token string, err error) { + c.mux.Lock() + defer c.mux.Unlock() + + if err = c.renewSecurityTokenIfNotValid(); err != nil { + return "", err + } + return c.securityToken.String(), nil +} + +func (c *x509FederationClient) renewSecurityTokenIfNotValid() (err error) { + if c.securityToken == nil || !c.securityToken.Valid() { + if err = c.renewSecurityToken(); err != nil { + return fmt.Errorf("failed to renew security token: %s", err.Error()) + } + } + return nil +} + +func (c *x509FederationClient) renewSecurityToken() (err error) { + if err = c.sessionKeySupplier.Refresh(); err != nil { + return fmt.Errorf("failed to refresh session key: %s", err.Error()) + } + + if err = c.leafCertificateRetriever.Refresh(); err != nil { + return fmt.Errorf("failed to refresh leaf certificate: %s", err.Error()) + } + + updatedTenancyID := extractTenancyIDFromCertificate(c.leafCertificateRetriever.Certificate()) + if c.tenancyID != updatedTenancyID { + err = fmt.Errorf("unexpected update of tenancy OCID in the leaf certificate. Previous tenancy: %s, Updated: %s", c.tenancyID, updatedTenancyID) + return + } + + for _, retriever := range c.intermediateCertificateRetrievers { + if err = retriever.Refresh(); err != nil { + return fmt.Errorf("failed to refresh intermediate certificate: %s", err.Error()) + } + } + + common.Logf("Renewing security token at: %v\n", time.Now().Format("15:04:05.000")) + if c.securityToken, err = c.getSecurityToken(); err != nil { + return fmt.Errorf("failed to get security token: %s", err.Error()) + } + common.Logf("Security token renewed at: %v\n", time.Now().Format("15:04:05.000")) + + return nil +} + +func (c *x509FederationClient) getSecurityToken() (securityToken, error) { + request := c.makeX509FederationRequest() + + var err error + var httpRequest http.Request + if httpRequest, err = common.MakeDefaultHTTPRequestWithTaggedStruct(http.MethodPost, "", request); err != nil { + return nil, fmt.Errorf("failed to make http request: %s", err.Error()) + } + + var httpResponse *http.Response + defer common.CloseBodyIfValid(httpResponse) + + for retry := 0; retry < 5; retry++ { + if httpResponse, err = c.authClient.Call(context.Background(), &httpRequest); err == nil { + break + } + time.Sleep(250 * time.Microsecond) + } + if err != nil { + return nil, fmt.Errorf("failed to call: %s", err.Error()) + } + + response := x509FederationResponse{} + if err = common.UnmarshalResponse(httpResponse, &response); err != nil { + return nil, fmt.Errorf("failed to unmarshal the response: %s", err.Error()) + } + + return newPrincipalToken(response.Token.Token) +} + +func (c *x509FederationClient) GetClaim(key string) (interface{}, error) { + c.mux.Lock() + defer c.mux.Unlock() + + if err := c.renewSecurityTokenIfNotValid(); err != nil { + return nil, err + } + return c.securityToken.GetClaim(key) +} + +type x509FederationRequest struct { + X509FederationDetails `contributesTo:"body"` +} + +// X509FederationDetails x509 federation details +type X509FederationDetails struct { + Certificate string `mandatory:"true" json:"certificate,omitempty"` + PublicKey string `mandatory:"true" json:"publicKey,omitempty"` + IntermediateCertificates []string `mandatory:"false" json:"intermediateCertificates,omitempty"` +} + +type x509FederationResponse struct { + Token `presentIn:"body"` +} + +// Token token +type Token struct { + Token string `mandatory:"true" json:"token,omitempty"` +} + +func (c *x509FederationClient) makeX509FederationRequest() *x509FederationRequest { + certificate := c.sanitizeCertificateString(string(c.leafCertificateRetriever.CertificatePemRaw())) + publicKey := c.sanitizeCertificateString(string(c.sessionKeySupplier.PublicKeyPemRaw())) + var intermediateCertificates []string + for _, retriever := range c.intermediateCertificateRetrievers { + intermediateCertificates = append(intermediateCertificates, c.sanitizeCertificateString(string(retriever.CertificatePemRaw()))) + } + + details := X509FederationDetails{ + Certificate: certificate, + PublicKey: publicKey, + IntermediateCertificates: intermediateCertificates, + } + return &x509FederationRequest{details} +} + +func (c *x509FederationClient) sanitizeCertificateString(certString string) string { + certString = strings.Replace(certString, "-----BEGIN CERTIFICATE-----", "", -1) + certString = strings.Replace(certString, "-----END CERTIFICATE-----", "", -1) + certString = strings.Replace(certString, "-----BEGIN PUBLIC KEY-----", "", -1) + certString = strings.Replace(certString, "-----END PUBLIC KEY-----", "", -1) + certString = strings.Replace(certString, "\n", "", -1) + return certString +} + +// sessionKeySupplier provides an RSA keypair which can be re-generated by calling Refresh(). +type sessionKeySupplier interface { + Refresh() error + PrivateKey() *rsa.PrivateKey + PublicKeyPemRaw() []byte +} + +//genericKeySupplier implements sessionKeySupplier and provides an arbitrary refresh mechanism +type genericKeySupplier struct { + RefreshFn func() (*rsa.PrivateKey, []byte, error) + + privateKey *rsa.PrivateKey + publicKeyPemRaw []byte +} + +func (s genericKeySupplier) PrivateKey() *rsa.PrivateKey { + if s.privateKey == nil { + return nil + } + + c := *s.privateKey + return &c +} + +func (s genericKeySupplier) PublicKeyPemRaw() []byte { + if s.publicKeyPemRaw == nil { + return nil + } + + c := make([]byte, len(s.publicKeyPemRaw)) + copy(c, s.publicKeyPemRaw) + return c +} + +func (s *genericKeySupplier) Refresh() (err error) { + privateKey, publicPem, err := s.RefreshFn() + if err != nil { + return err + } + + s.privateKey = privateKey + s.publicKeyPemRaw = publicPem + return nil +} + +// create a sessionKeySupplier that reads keys from file every time it refreshes +func newFileBasedKeySessionSupplier(privateKeyPemPath string, passphrasePath *string) (*genericKeySupplier, error) { + return &genericKeySupplier{ + RefreshFn: func() (*rsa.PrivateKey, []byte, error) { + var err error + var passContent []byte + if passphrasePath != nil { + if passContent, err = ioutil.ReadFile(*passphrasePath); err != nil { + return nil, nil, fmt.Errorf("can not read passphrase from file: %s, due to %s", *passphrasePath, err.Error()) + } + } + + var keyPemContent []byte + if keyPemContent, err = ioutil.ReadFile(privateKeyPemPath); err != nil { + return nil, nil, fmt.Errorf("can not read private privateKey pem from file: %s, due to %s", privateKeyPemPath, err.Error()) + } + + var privateKey *rsa.PrivateKey + if privateKey, err = common.PrivateKeyFromBytesWithPassword(keyPemContent, passContent); err != nil { + return nil, nil, fmt.Errorf("can not create private privateKey from contents of: %s, due to: %s", privateKeyPemPath, err.Error()) + } + + var publicKeyAsnBytes []byte + if publicKeyAsnBytes, err = x509.MarshalPKIXPublicKey(privateKey.Public()); err != nil { + return nil, nil, fmt.Errorf("failed to marshal the public part of the new keypair: %s", err.Error()) + } + publicKeyPemRaw := pem.EncodeToMemory(&pem.Block{ + Type: "PUBLIC KEY", + Bytes: publicKeyAsnBytes, + }) + return privateKey, publicKeyPemRaw, nil + }, + }, nil +} + +func newStaticKeySessionSupplier(privateKeyPemContent, passphrase []byte) (*genericKeySupplier, error) { + var err error + var privateKey *rsa.PrivateKey + + if privateKey, err = common.PrivateKeyFromBytesWithPassword(privateKeyPemContent, passphrase); err != nil { + return nil, fmt.Errorf("can not create private privateKey, due to: %s", err.Error()) + } + + var publicKeyAsnBytes []byte + if publicKeyAsnBytes, err = x509.MarshalPKIXPublicKey(privateKey.Public()); err != nil { + return nil, fmt.Errorf("failed to marshal the public part of the new keypair: %s", err.Error()) + } + publicKeyPemRaw := pem.EncodeToMemory(&pem.Block{ + Type: "PUBLIC KEY", + Bytes: publicKeyAsnBytes, + }) + + return &genericKeySupplier{ + RefreshFn: func() (key *rsa.PrivateKey, bytes []byte, err error) { + return privateKey, publicKeyPemRaw, nil + }, + }, nil +} + +// inMemorySessionKeySupplier implements sessionKeySupplier to vend an RSA keypair. +// Refresh() generates a new RSA keypair with a random source, and keeps it in memory. +// +// inMemorySessionKeySupplier is not thread-safe. +type inMemorySessionKeySupplier struct { + keySize int + privateKey *rsa.PrivateKey + publicKeyPemRaw []byte +} + +// newSessionKeySupplier creates and returns a sessionKeySupplier instance which generates key pairs of size 2048. +func newSessionKeySupplier() sessionKeySupplier { + return &inMemorySessionKeySupplier{keySize: 2048} +} + +// Refresh() is failure atomic, i.e., PrivateKey() and PublicKeyPemRaw() would return their previous values +// if Refresh() fails. +func (s *inMemorySessionKeySupplier) Refresh() (err error) { + common.Debugln("Refreshing session key") + + var privateKey *rsa.PrivateKey + privateKey, err = rsa.GenerateKey(rand.Reader, s.keySize) + if err != nil { + return fmt.Errorf("failed to generate a new keypair: %s", err) + } + + var publicKeyAsnBytes []byte + if publicKeyAsnBytes, err = x509.MarshalPKIXPublicKey(privateKey.Public()); err != nil { + return fmt.Errorf("failed to marshal the public part of the new keypair: %s", err.Error()) + } + publicKeyPemRaw := pem.EncodeToMemory(&pem.Block{ + Type: "PUBLIC KEY", + Bytes: publicKeyAsnBytes, + }) + + s.privateKey = privateKey + s.publicKeyPemRaw = publicKeyPemRaw + return nil +} + +func (s *inMemorySessionKeySupplier) PrivateKey() *rsa.PrivateKey { + if s.privateKey == nil { + return nil + } + + c := *s.privateKey + return &c +} + +func (s *inMemorySessionKeySupplier) PublicKeyPemRaw() []byte { + if s.publicKeyPemRaw == nil { + return nil + } + + c := make([]byte, len(s.publicKeyPemRaw)) + copy(c, s.publicKeyPemRaw) + return c +} + +type securityToken interface { + fmt.Stringer + Valid() bool + + ClaimHolder +} + +type principalToken struct { + tokenString string + jwtToken *jwtToken +} + +func newPrincipalToken(tokenString string) (newToken securityToken, err error) { + var jwtToken *jwtToken + if jwtToken, err = parseJwt(tokenString); err != nil { + return nil, fmt.Errorf("failed to parse the token string \"%s\": %s", tokenString, err.Error()) + } + return &principalToken{tokenString, jwtToken}, nil +} + +func (t *principalToken) String() string { + return t.tokenString +} + +func (t *principalToken) Valid() bool { + return !t.jwtToken.expired() +} + +var ( + // ErrNoSuchClaim is returned when a token does not hold the claim sought + ErrNoSuchClaim = errors.New("no such claim") +) + +func (t *principalToken) GetClaim(key string) (interface{}, error) { + if value, ok := t.jwtToken.payload[key]; ok { + return value, nil + } + return nil, ErrNoSuchClaim +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/instance_principal_delegation_token_provider.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/instance_principal_delegation_token_provider.go new file mode 100644 index 000000000..e4859e56e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/instance_principal_delegation_token_provider.go @@ -0,0 +1,83 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package auth + +import ( + "crypto/rsa" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" +) + +type instancePrincipalDelegationTokenConfigurationProvider struct { + instancePrincipalKeyProvider instancePrincipalKeyProvider + delegationToken string + region *common.Region +} + +//InstancePrincipalDelegationTokenConfigurationProvider returns a configuration for obo token instance principals +func InstancePrincipalDelegationTokenConfigurationProvider(delegationToken *string) (common.ConfigurationProvider, error) { + if delegationToken == nil || len(*delegationToken) == 0 { + return nil, fmt.Errorf("failed to create a delagationTokenConfigurationProvider: token is a mondatory input paras") + } + return newInstancePrincipalDelegationTokenConfigurationProvider(delegationToken, "", nil) +} + +//InstancePrincipalDelegationTokenConfigurationProviderForRegion returns a configuration for obo token instance principals with a given region +func InstancePrincipalDelegationTokenConfigurationProviderForRegion(delegationToken *string, region common.Region) (common.ConfigurationProvider, error) { + if delegationToken == nil || len(*delegationToken) == 0 { + return nil, fmt.Errorf("failed to create a delagationTokenConfigurationProvider: token is a mondatory input paras") + } + return newInstancePrincipalDelegationTokenConfigurationProvider(delegationToken, region, nil) +} + +func newInstancePrincipalDelegationTokenConfigurationProvider(delegationToken *string, region common.Region, modifier func(common.HTTPRequestDispatcher) (common.HTTPRequestDispatcher, + error)) (common.ConfigurationProvider, error) { + + keyProvider, err := newInstancePrincipalKeyProvider(modifier) + if err != nil { + return nil, fmt.Errorf("failed to create a new key provider for instance principal: %s", err.Error()) + } + if len(region) > 0 { + return instancePrincipalDelegationTokenConfigurationProvider{*keyProvider, *delegationToken, ®ion}, err + } + return instancePrincipalDelegationTokenConfigurationProvider{*keyProvider, *delegationToken, nil}, err +} + +func (p instancePrincipalDelegationTokenConfigurationProvider) getInstancePrincipalDelegationTokenConfigurationProvider() (instancePrincipalDelegationTokenConfigurationProvider, error) { + return p, nil +} + +func (p instancePrincipalDelegationTokenConfigurationProvider) PrivateRSAKey() (*rsa.PrivateKey, error) { + return p.instancePrincipalKeyProvider.PrivateRSAKey() +} + +func (p instancePrincipalDelegationTokenConfigurationProvider) KeyID() (string, error) { + return p.instancePrincipalKeyProvider.KeyID() +} + +func (p instancePrincipalDelegationTokenConfigurationProvider) TenancyOCID() (string, error) { + return p.instancePrincipalKeyProvider.TenancyOCID() +} + +func (p instancePrincipalDelegationTokenConfigurationProvider) UserOCID() (string, error) { + return "", nil +} + +func (p instancePrincipalDelegationTokenConfigurationProvider) KeyFingerprint() (string, error) { + return "", nil +} + +func (p instancePrincipalDelegationTokenConfigurationProvider) Region() (string, error) { + if p.region == nil { + region := p.instancePrincipalKeyProvider.RegionForFederationClient() + common.Debugf("Region in instance principal delegation token configuration provider is nil. Returning federation clients region: %s", region) + return string(region), nil + } + return string(*p.region), nil +} + +func (p instancePrincipalDelegationTokenConfigurationProvider) AuthType() (common.AuthConfig, error) { + token := p.delegationToken + return common.AuthConfig{common.InstancePrincipalDelegationToken, false, &token}, nil +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/instance_principal_key_provider.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/instance_principal_key_provider.go new file mode 100644 index 000000000..ee0681843 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/instance_principal_key_provider.go @@ -0,0 +1,146 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package auth + +import ( + "bytes" + "crypto/rsa" + "fmt" + "net/http" + "strings" + "time" + + "github.com/oracle/oci-go-sdk/v54/common" +) + +const ( + metadataBaseURL = `http://169.254.169.254/opc/v2` + metadataFallbackURL = `http://169.254.169.254/opc/v1` + regionPath = `/instance/region` + leafCertificatePath = `/identity/cert.pem` + leafCertificateKeyPath = `/identity/key.pem` + intermediateCertificatePath = `/identity/intermediate.pem` + + leafCertificateKeyPassphrase = `` // No passphrase for the private key for Compute instances + intermediateCertificateKeyURL = `` + intermediateCertificateKeyPassphrase = `` // No passphrase for the private key for Compute instances +) + +var ( + regionURL, leafCertificateURL, leafCertificateKeyURL, intermediateCertificateURL string +) + +// instancePrincipalKeyProvider implements KeyProvider to provide a key ID and its corresponding private key +// for an instance principal by getting a security token via x509FederationClient. +// +// The region name of the endpoint for x509FederationClient is obtained from the metadata service on the compute +// instance. +type instancePrincipalKeyProvider struct { + Region common.Region + FederationClient federationClient + TenancyID string +} + +// newInstancePrincipalKeyProvider creates and returns an instancePrincipalKeyProvider instance based on +// x509FederationClient. +// +// NOTE: There is a race condition between PrivateRSAKey() and KeyID(). These two pieces are tightly coupled; KeyID +// includes a security token obtained from Auth service by giving a public key which is paired with PrivateRSAKey. +// The x509FederationClient caches the security token in memory until it is expired. Thus, even if a client obtains a +// KeyID that is not expired at the moment, the PrivateRSAKey that the client acquires at a next moment could be +// invalid because the KeyID could be already expired. +func newInstancePrincipalKeyProvider(modifier func(common.HTTPRequestDispatcher) (common.HTTPRequestDispatcher, error)) (provider *instancePrincipalKeyProvider, err error) { + updateX509CertRetrieverURLParas(metadataBaseURL) + clientModifier := newDispatcherModifier(modifier) + + client, err := clientModifier.Modify(&http.Client{}) + if err != nil { + err = fmt.Errorf("failed to modify client: %s", err.Error()) + return nil, err + } + + var region common.Region + + if region, err = getRegionForFederationClient(client, regionURL); err != nil { + err = fmt.Errorf("failed to get the region name from %s: %s", regionURL, err.Error()) + common.Logf("%v\n", err) + return nil, err + } + + leafCertificateRetriever := newURLBasedX509CertificateRetriever(client, + leafCertificateURL, leafCertificateKeyURL, leafCertificateKeyPassphrase) + intermediateCertificateRetrievers := []x509CertificateRetriever{ + newURLBasedX509CertificateRetriever( + client, intermediateCertificateURL, intermediateCertificateKeyURL, + intermediateCertificateKeyPassphrase), + } + + if err = leafCertificateRetriever.Refresh(); err != nil { + err = fmt.Errorf("failed to refresh the leaf certificate: %s", err.Error()) + return nil, err + } + tenancyID := extractTenancyIDFromCertificate(leafCertificateRetriever.Certificate()) + + federationClient, err := newX509FederationClient(region, tenancyID, leafCertificateRetriever, intermediateCertificateRetrievers, *clientModifier) + + if err != nil { + err = fmt.Errorf("failed to create federation client: %s", err.Error()) + return nil, err + } + + provider = &instancePrincipalKeyProvider{FederationClient: federationClient, TenancyID: tenancyID, Region: region} + return +} + +func getRegionForFederationClient(dispatcher common.HTTPRequestDispatcher, url string) (r common.Region, err error) { + var body bytes.Buffer + var statusCode int + MaxRetriesFederationClient := 3 + for currTry := 0; currTry < MaxRetriesFederationClient; currTry++ { + body, statusCode, err = httpGet(dispatcher, url) + if err == nil && statusCode == 200 { + return common.StringToRegion(body.String()), nil + } + common.Logf("Error in getting region from url: %s, Status code: %v, Error: %s", url, statusCode, err.Error()) + if statusCode == 404 && strings.Compare(url, metadataBaseURL+regionPath) == 0 { + common.Logf("Falling back to http://169.254.169.254/opc/v1 to try again...") + updateX509CertRetrieverURLParas(metadataFallbackURL) + url = regionURL + } + time.Sleep(1 * time.Second) + } + return +} + +func updateX509CertRetrieverURLParas(baseURL string) { + regionURL = baseURL + regionPath + leafCertificateURL = baseURL + leafCertificatePath + leafCertificateKeyURL = baseURL + leafCertificateKeyPath + intermediateCertificateURL = baseURL + intermediateCertificatePath +} + +func (p *instancePrincipalKeyProvider) RegionForFederationClient() common.Region { + return p.Region +} + +func (p *instancePrincipalKeyProvider) PrivateRSAKey() (privateKey *rsa.PrivateKey, err error) { + if privateKey, err = p.FederationClient.PrivateKey(); err != nil { + err = fmt.Errorf("failed to get private key: %s", err.Error()) + return nil, err + } + return privateKey, nil +} + +func (p *instancePrincipalKeyProvider) KeyID() (string, error) { + var securityToken string + var err error + if securityToken, err = p.FederationClient.SecurityToken(); err != nil { + return "", fmt.Errorf("failed to get security token: %s", err.Error()) + } + return fmt.Sprintf("ST$%s", securityToken), nil +} + +func (p *instancePrincipalKeyProvider) TenancyOCID() (string, error) { + return p.TenancyID, nil +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/jwt.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/jwt.go new file mode 100644 index 000000000..e7289d830 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/jwt.go @@ -0,0 +1,70 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package auth + +import ( + "bytes" + "encoding/base64" + "encoding/json" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" + "strings" + "time" +) + +type jwtToken struct { + raw string + header map[string]interface{} + payload map[string]interface{} +} + +const bufferTimeBeforeTokenExpiration = 5 * time.Minute + +func (t *jwtToken) expired() bool { + exp := int64(t.payload["exp"].(float64)) + expTime := time.Unix(exp, 0) + expired := exp <= time.Now().Unix()+int64(bufferTimeBeforeTokenExpiration.Seconds()) + if expired { + common.Debugf("Token expires at: %v, currently expired due to bufferTime: %v", expTime.Format("15:04:05.000"), expired) + } + return expired +} + +func parseJwt(tokenString string) (*jwtToken, error) { + parts := strings.Split(tokenString, ".") + if len(parts) != 3 { + return nil, fmt.Errorf("the given token string contains an invalid number of parts") + } + + token := &jwtToken{raw: tokenString} + var err error + + // Parse Header part + var headerBytes []byte + if headerBytes, err = decodePart(parts[0]); err != nil { + return nil, fmt.Errorf("failed to decode the header bytes: %s", err.Error()) + } + if err = json.Unmarshal(headerBytes, &token.header); err != nil { + return nil, err + } + + // Parse Payload part + var payloadBytes []byte + if payloadBytes, err = decodePart(parts[1]); err != nil { + return nil, fmt.Errorf("failed to decode the payload bytes: %s", err.Error()) + } + decoder := json.NewDecoder(bytes.NewBuffer(payloadBytes)) + if err = decoder.Decode(&token.payload); err != nil { + return nil, fmt.Errorf("failed to decode the payload json: %s", err.Error()) + } + + return token, nil +} + +func decodePart(partString string) ([]byte, error) { + if l := len(partString) % 4; 0 < l { + partString += strings.Repeat("=", 4-l) + } + return base64.URLEncoding.DecodeString(partString) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/resouce_principal_key_provider.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/resouce_principal_key_provider.go new file mode 100644 index 000000000..d4b509d5d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/resouce_principal_key_provider.go @@ -0,0 +1,231 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package auth + +import ( + "crypto/rsa" + "errors" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" + "os" + "path" +) + +const ( + //ResourcePrincipalVersion2_2 is a supported version for resource principals + ResourcePrincipalVersion2_2 = "2.2" + //ResourcePrincipalVersionEnvVar environment var name for version + ResourcePrincipalVersionEnvVar = "OCI_RESOURCE_PRINCIPAL_VERSION" + //ResourcePrincipalRPSTEnvVar environment var name holding the token or a path to the token + ResourcePrincipalRPSTEnvVar = "OCI_RESOURCE_PRINCIPAL_RPST" + //ResourcePrincipalPrivatePEMEnvVar environment var holding a rsa private key in pem format or a path to one + ResourcePrincipalPrivatePEMEnvVar = "OCI_RESOURCE_PRINCIPAL_PRIVATE_PEM" + //ResourcePrincipalPrivatePEMPassphraseEnvVar environment var holding the passphrase to a key or a path to one + ResourcePrincipalPrivatePEMPassphraseEnvVar = "OCI_RESOURCE_PRINCIPAL_PRIVATE_PEM_PASSPHRASE" + //ResourcePrincipalRegionEnvVar environment variable holding a region + ResourcePrincipalRegionEnvVar = "OCI_RESOURCE_PRINCIPAL_REGION" + + //ResourcePrincipalVersion1_1 is a supported version for resource principals + ResourcePrincipalVersion1_1 = "1.1" + //ResourcePrincipalSessionTokenEndpoint endpoint for retrieving the Resource Principal Session Token + ResourcePrincipalSessionTokenEndpoint = "OCI_RESOURCE_PRINCIPAL_RPST_ENDPOINT" + //ResourcePrincipalTokenEndpoint endpoint for retrieving the Resource Principal Token + ResourcePrincipalTokenEndpoint = "OCI_RESOURCE_PRINCIPAL_RPT_ENDPOINT" + + // TenancyOCIDClaimKey is the key used to look up the resource tenancy in an RPST + TenancyOCIDClaimKey = "res_tenant" + // CompartmentOCIDClaimKey is the key used to look up the resource compartment in an RPST + CompartmentOCIDClaimKey = "res_compartment" +) + +// ConfigurationProviderWithClaimAccess mixes in a method to access the claims held on the underlying security token +type ConfigurationProviderWithClaimAccess interface { + common.ConfigurationProvider + ClaimHolder +} + +// ResourcePrincipalConfigurationProvider returns a resource principal configuration provider using well known +// environment variables to look up token information. The environment variables can either paths or contain the material value +// of the keys. However in the case of the keys and tokens paths and values can not be mixed +func ResourcePrincipalConfigurationProvider() (ConfigurationProviderWithClaimAccess, error) { + var version string + var ok bool + if version, ok = os.LookupEnv(ResourcePrincipalVersionEnvVar); !ok { + return nil, fmt.Errorf("can not create resource principal, environment variable: %s, not present", ResourcePrincipalVersionEnvVar) + } + + switch version { + case ResourcePrincipalVersion2_2: + rpst := requireEnv(ResourcePrincipalRPSTEnvVar) + if rpst == nil { + return nil, fmt.Errorf("can not create resource principal, environment variable: %s, not present", ResourcePrincipalRPSTEnvVar) + } + private := requireEnv(ResourcePrincipalPrivatePEMEnvVar) + if private == nil { + return nil, fmt.Errorf("can not create resource principal, environment variable: %s, not present", ResourcePrincipalPrivatePEMEnvVar) + } + passphrase := requireEnv(ResourcePrincipalPrivatePEMPassphraseEnvVar) + region := requireEnv(ResourcePrincipalRegionEnvVar) + if region == nil { + return nil, fmt.Errorf("can not create resource principal, environment variable: %s, not present", ResourcePrincipalRegionEnvVar) + } + return newResourcePrincipalKeyProvider22( + *rpst, *private, passphrase, *region) + case ResourcePrincipalVersion1_1: + return newResourcePrincipalKeyProvider11(DefaultRptPathProvider{}) + default: + return nil, fmt.Errorf("can not create resource principal, environment variable: %s, must be valid", ResourcePrincipalVersionEnvVar) + } +} + +// ResourcePrincipalConfigurationProviderWithPathProvider returns a resource principal configuration provider using path provider. +func ResourcePrincipalConfigurationProviderWithPathProvider(pathProvider PathProvider) (ConfigurationProviderWithClaimAccess, error) { + var version string + var ok bool + if version, ok = os.LookupEnv(ResourcePrincipalVersionEnvVar); !ok { + return nil, fmt.Errorf("can not create resource principal, environment variable: %s, not present", ResourcePrincipalVersionEnvVar) + } else if version != ResourcePrincipalVersion1_1 { + return nil, fmt.Errorf("can not create resource principal, environment variable: %s, must be %s", ResourcePrincipalVersionEnvVar, ResourcePrincipalVersion1_1) + } + return newResourcePrincipalKeyProvider11(pathProvider) +} + +func newResourcePrincipalKeyProvider11(pathProvider PathProvider) (ConfigurationProviderWithClaimAccess, error) { + rptEndpoint := requireEnv(ResourcePrincipalTokenEndpoint) + if rptEndpoint == nil { + return nil, fmt.Errorf("can not create resource principal, environment variable: %s, not present", ResourcePrincipalTokenEndpoint) + } + rptPath, err := pathProvider.Path() + if err != nil { + return nil, fmt.Errorf("can not create resource principal, due to: %s ", err.Error()) + } + resourceID, err := pathProvider.ResourceID() + if err != nil { + return nil, fmt.Errorf("can not create resource principal, due to: %s ", err.Error()) + } + rp, err := resourcePrincipalConfigurationProviderV1(*rptEndpoint+*rptPath, *resourceID) + if err != nil { + return nil, fmt.Errorf("can not create resource principal, due to: %s ", err.Error()) + } + return rp, nil +} + +func requireEnv(key string) *string { + if val, ok := os.LookupEnv(key); ok { + return &val + } + return nil +} + +// resourcePrincipalKeyProvider22 is key provider that reads from specified the specified environment variables +// the environment variables can host the material keys/passphrases or they can be paths to files that need to be read +type resourcePrincipalKeyProvider struct { + FederationClient federationClient + KeyProviderRegion common.Region +} + +func newResourcePrincipalKeyProvider22(sessionTokenLocation, privatePemLocation string, + passphraseLocation *string, region string) (*resourcePrincipalKeyProvider, error) { + + //Check both the the passphrase and the key are paths + if passphraseLocation != nil && (!isPath(privatePemLocation) && isPath(*passphraseLocation) || + isPath(privatePemLocation) && !isPath(*passphraseLocation)) { + return nil, fmt.Errorf("cant not create resource principal: both key and passphrase need to be path or none needs to be path") + } + + var supplier sessionKeySupplier + var err error + + //File based case + if isPath(privatePemLocation) { + supplier, err = newFileBasedKeySessionSupplier(privatePemLocation, passphraseLocation) + if err != nil { + return nil, fmt.Errorf("can not create resource principal, due to: %s ", err.Error()) + } + } else { + //else the content is in the env vars + var passphrase []byte + if passphraseLocation != nil { + passphrase = []byte(*passphraseLocation) + } + supplier, err = newStaticKeySessionSupplier([]byte(privatePemLocation), passphrase) + if err != nil { + return nil, fmt.Errorf("can not create resource principal, due to: %s ", err.Error()) + } + } + + var fd federationClient + if isPath(sessionTokenLocation) { + fd, _ = newFileBasedFederationClient(sessionTokenLocation, supplier) + } else { + fd, err = newStaticFederationClient(sessionTokenLocation, supplier) + if err != nil { + return nil, fmt.Errorf("can not create resource principal, due to: %s ", err.Error()) + } + } + + rs := resourcePrincipalKeyProvider{ + FederationClient: fd, + KeyProviderRegion: common.StringToRegion(region), + } + return &rs, nil +} + +func (p *resourcePrincipalKeyProvider) PrivateRSAKey() (privateKey *rsa.PrivateKey, err error) { + if privateKey, err = p.FederationClient.PrivateKey(); err != nil { + err = fmt.Errorf("failed to get private key: %s", err.Error()) + return nil, err + } + return privateKey, nil +} + +func (p *resourcePrincipalKeyProvider) KeyID() (string, error) { + var securityToken string + var err error + if securityToken, err = p.FederationClient.SecurityToken(); err != nil { + return "", fmt.Errorf("failed to get security token: %s", err.Error()) + } + return fmt.Sprintf("ST$%s", securityToken), nil +} + +func (p *resourcePrincipalKeyProvider) Region() (string, error) { + return string(p.KeyProviderRegion), nil +} + +var ( + // ErrNonStringClaim is returned if the token has a claim for a key, but it's not a string value + ErrNonStringClaim = errors.New("claim does not have a string value") +) + +func (p *resourcePrincipalKeyProvider) TenancyOCID() (string, error) { + if claim, err := p.GetClaim(TenancyOCIDClaimKey); err != nil { + return "", err + } else if tenancy, ok := claim.(string); ok { + return tenancy, nil + } else { + return "", ErrNonStringClaim + } +} + +func (p *resourcePrincipalKeyProvider) GetClaim(claim string) (interface{}, error) { + return p.FederationClient.GetClaim(claim) +} + +func (p *resourcePrincipalKeyProvider) KeyFingerprint() (string, error) { + return "", nil +} + +func (p *resourcePrincipalKeyProvider) UserOCID() (string, error) { + return "", nil +} + +func (p *resourcePrincipalKeyProvider) AuthType() (common.AuthConfig, error) { + return common.AuthConfig{common.UnknownAuthenticationType, false, nil}, fmt.Errorf("unsupported, keep the interface") +} + +// By contract for the the content of a resource principal to be considered path, it needs to be +// an absolute path. +func isPath(str string) bool { + return path.IsAbs(str) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/resource_principal_token_path_provider.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/resource_principal_token_path_provider.go new file mode 100644 index 000000000..5bc58ccce --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/resource_principal_token_path_provider.go @@ -0,0 +1,138 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package auth + +import ( + "fmt" + "io/ioutil" + "net/http" +) + +const ( + imdsPathTemplate = "/20180711/resourcePrincipalToken/{id}" + instanceIDURL = `http://169.254.169.254/opc/v2/instance/id` + + //ResourcePrincipalTokenPath path for retrieving the Resource Principal Token + ResourcePrincipalTokenPath = "OCI_RESOURCE_PRINCIPAL_RPT_PATH" + //ResourceID OCID for the resource for Resource Principal + ResourceID = "OCI_RESOURCE_PRINCIPAL_RPT_ID" +) + +// PathProvider is an interface that returns path and resource ID +type PathProvider interface { + Path() (*string, error) + ResourceID() (*string, error) +} + +// StringRptPathProvider is a simple path provider that takes a string and returns it +type StringRptPathProvider struct { + path string + resourceID string +} + +// Path returns the resource principal token path +func (pp StringRptPathProvider) Path() (*string, error) { + return &pp.path, nil +} + +// ResourceID returns the resource associated with the resource principal +func (pp StringRptPathProvider) ResourceID() (*string, error) { + return &pp.resourceID, nil +} + +// ImdsRptPathProvider sets the path from a default value and the resource ID from instance metadata +type ImdsRptPathProvider struct{} + +// Path returns the resource principal token path +func (pp ImdsRptPathProvider) Path() (*string, error) { + path := imdsPathTemplate + return &path, nil +} + +// ResourceID returns the resource associated with the resource principal +func (pp ImdsRptPathProvider) ResourceID() (*string, error) { + instanceID, err := getInstanceIDFromMetadata() + return &instanceID, err +} + +// EnvRptPathProvider sets the path and resource ID from environment variables +type EnvRptPathProvider struct{} + +// Path returns the resource principal token path +func (pp EnvRptPathProvider) Path() (*string, error) { + path := requireEnv(ResourcePrincipalTokenPath) + if path == nil { + return nil, fmt.Errorf("missing %s env var", ResourcePrincipalTokenPath) + } + return path, nil +} + +// ResourceID returns the resource associated with the resource principal +func (pp EnvRptPathProvider) ResourceID() (*string, error) { + rpID := requireEnv(ResourceID) + if rpID == nil { + return nil, fmt.Errorf("missing %s env var", ResourceID) + } + return rpID, nil +} + +//DefaultRptPathProvider path provider makes sure the behavior happens with the correct fallback. +// +//For the path, +//Use the contents of the OCI_RESOURCE_PRINCIPAL_RPT_PATH environment variable, if set. +//Otherwise, use the current path: "/20180711/resourcePrincipalToken/{id}" +// +//For the resource id, +//Use the contents of the OCI_RESOURCE_PRINCIPAL_RPT_ID environment variable, if set. +//Otherwise, use IMDS to get the instance id +// +//This path provider is used when the caller doesn't provide a specific path provider to the resource principals signer +type DefaultRptPathProvider struct { + path string + resourceID string +} + +// Path returns the resource principal token path +func (pp DefaultRptPathProvider) Path() (*string, error) { + path := requireEnv(ResourcePrincipalTokenPath) + if path == nil { + rpPath := imdsPathTemplate + return &rpPath, nil + } + return path, nil +} + +// ResourceID returns the resource associated with the resource principal +func (pp DefaultRptPathProvider) ResourceID() (*string, error) { + rpID := requireEnv(ResourceID) + if rpID == nil { + instanceID, err := getInstanceIDFromMetadata() + if err != nil { + return nil, err + } + return &instanceID, nil + } + return rpID, nil +} + +func getInstanceIDFromMetadata() (instanceID string, err error) { + client := &http.Client{} + req, err := http.NewRequest("GET", instanceIDURL, nil) + if err != nil { + return "", err + } + req.Header.Set("Authorization", "Bearer Oracle") + resp, err := client.Do(req) + if err != nil { + return "", err + } + defer resp.Body.Close() + + bodyBytes, err := ioutil.ReadAll(resp.Body) + if err != nil { + return "", err + } + bodyString := string(bodyBytes) + return bodyString, nil +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/resource_principals_v1.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/resource_principals_v1.go new file mode 100644 index 000000000..0aa834f6e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/resource_principals_v1.go @@ -0,0 +1,373 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package auth + +import ( + "context" + "crypto/rsa" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" + + "net/http" + "net/url" + "sync" + "time" +) + +// resourcePrincipalFederationClient is the client used to to talk acquire resource principals +// No auth client, leaf or intermediate retrievers. We use certificates retrieved by instance principals to sign the operations of +// resource principals +type resourcePrincipalFederationClient struct { + tenancyID string + instanceID string + sessionKeySupplier sessionKeySupplier + mux sync.Mutex + securityToken securityToken + path string + + //instancePrincipalKeyProvider the instance Principal Key container + instancePrincipalKeyProvider instancePrincipalKeyProvider + + //ResourcePrincipalTargetServiceClient client that calls the target service to acquire a resource principal token + ResourcePrincipalTargetServiceClient common.BaseClient + + //ResourcePrincipalSessionTokenClient. The client used to communicate with identity to exchange a resource principal for + // resource principal session token + ResourcePrincipalSessionTokenClient common.BaseClient +} + +type resourcePrincipalTokenRequest struct { + InstanceID string `contributesTo:"path" name:"id"` +} + +type resourcePrincipalTokenResponse struct { + Body struct { + ResourcePrincipalToken string `json:"resourcePrincipalToken"` + ServicePrincipalSessionToken string `json:"servicePrincipalSessionToken"` + } `presentIn:"body"` +} + +type resourcePrincipalSessionTokenRequestBody struct { + ResourcePrincipalToken string `json:"resourcePrincipalToken,omitempty"` + ServicePrincipalSessionToken string `json:"servicePrincipalSessionToken,omitempty"` + SessionPublicKey string `json:"sessionPublicKey,omitempty"` +} +type resourcePrincipalSessionTokenRequest struct { + Body resourcePrincipalSessionTokenRequestBody `contributesTo:"body"` +} + +//acquireResourcePrincipalToken acquires the resource principal from the target service +func (c *resourcePrincipalFederationClient) acquireResourcePrincipalToken() (tokenResponse resourcePrincipalTokenResponse, err error) { + rpServiceClient := c.ResourcePrincipalTargetServiceClient + + //Set the signer of this client to be the instance principal provider + rpServiceClient.Signer = common.DefaultRequestSigner(&c.instancePrincipalKeyProvider) + + //Create a request with the instanceId + request, err := common.MakeDefaultHTTPRequestWithTaggedStruct(http.MethodGet, c.path, resourcePrincipalTokenRequest{InstanceID: c.instanceID}) + if err != nil { + return + } + + //Call the target service + response, err := rpServiceClient.Call(context.Background(), &request) + if err != nil { + return + } + + defer common.CloseBodyIfValid(response) + + tokenResponse = resourcePrincipalTokenResponse{} + err = common.UnmarshalResponse(response, &tokenResponse) + return +} + +//exchangeToken exchanges a resource principal token from the target service with a session token from identity +func (c *resourcePrincipalFederationClient) exchangeToken(publicKeyBase64 string, tokenResponse resourcePrincipalTokenResponse) (sessionToken string, err error) { + rpServiceClient := c.ResourcePrincipalSessionTokenClient + + //Set the signer of this client to be the instance principal provider + rpServiceClient.Signer = common.DefaultRequestSigner(&c.instancePrincipalKeyProvider) + + // Call identity service to get resource principal session token + sessionTokenReq := resourcePrincipalSessionTokenRequest{ + resourcePrincipalSessionTokenRequestBody{ + ServicePrincipalSessionToken: tokenResponse.Body.ServicePrincipalSessionToken, + ResourcePrincipalToken: tokenResponse.Body.ResourcePrincipalToken, + SessionPublicKey: publicKeyBase64, + }, + } + + sessionTokenHTTPReq, err := common.MakeDefaultHTTPRequestWithTaggedStruct(http.MethodPost, + "", sessionTokenReq) + if err != nil { + return + } + + sessionTokenHTTPRes, err := rpServiceClient.Call(context.Background(), &sessionTokenHTTPReq) + if err != nil { + return + } + defer common.CloseBodyIfValid(sessionTokenHTTPRes) + + sessionTokenRes := x509FederationResponse{} + err = common.UnmarshalResponse(sessionTokenHTTPRes, &sessionTokenRes) + if err != nil { + return + } + + sessionToken = sessionTokenRes.Token.Token + return +} + +//getSecurityToken makes the appropiate calls to acquire a resource principal security token +func (c *resourcePrincipalFederationClient) getSecurityToken() (securityToken, error) { + var err error + ipFederationClient := c.instancePrincipalKeyProvider.FederationClient + + common.Debugf("Refreshing instance principal token") + //Refresh instance principal token + if refreshable, ok := ipFederationClient.(*x509FederationClient); ok { + err = refreshable.renewSecurityTokenIfNotValid() + if err != nil { + return nil, err + } + } + + //Acquire resource principal token from target service + common.Debugf("Acquiring resource principal token from target service") + tokenResponse, err := c.acquireResourcePrincipalToken() + if err != nil { + return nil, err + } + + //Read the public key from the session supplier. + pem := c.sessionKeySupplier.PublicKeyPemRaw() + pemSanitized := sanitizeCertificateString(string(pem)) + + //Exchange resource principal token for session token from identity + common.Debugf("Exchanging resource principal token for resource principal session token") + sessionToken, err := c.exchangeToken(pemSanitized, tokenResponse) + if err != nil { + return nil, err + } + + return newPrincipalToken(sessionToken) // should be a resource principal token +} + +func (c *resourcePrincipalFederationClient) renewSecurityToken() (err error) { + if err = c.sessionKeySupplier.Refresh(); err != nil { + return fmt.Errorf("failed to refresh session key: %s", err.Error()) + } + common.Logf("Renewing resource principal security token at: %v\n", time.Now().Format("15:04:05.000")) + if c.securityToken, err = c.getSecurityToken(); err != nil { + return fmt.Errorf("failed to get security token: %s", err.Error()) + } + common.Logf("Resource principal security token renewed at: %v\n", time.Now().Format("15:04:05.000")) + + return nil +} + +//ResourcePrincipal Key provider in charge of resource principal acquiring tokens +type resourcePrincipalKeyProviderV1 struct { + ResourcePrincipalClient resourcePrincipalFederationClient +} + +func (c *resourcePrincipalFederationClient) renewSecurityTokenIfNotValid() (err error) { + if c.securityToken == nil || !c.securityToken.Valid() { + if err = c.renewSecurityToken(); err != nil { + return fmt.Errorf("failed to renew resource prinicipal security token: %s", err.Error()) + } + } + return nil +} + +func (c *resourcePrincipalFederationClient) PrivateKey() (*rsa.PrivateKey, error) { + c.mux.Lock() + defer c.mux.Unlock() + + if err := c.renewSecurityTokenIfNotValid(); err != nil { + return nil, err + } + return c.sessionKeySupplier.PrivateKey(), nil +} + +func (c *resourcePrincipalFederationClient) SecurityToken() (token string, err error) { + c.mux.Lock() + defer c.mux.Unlock() + + if err = c.renewSecurityTokenIfNotValid(); err != nil { + return "", err + } + return c.securityToken.String(), nil +} + +func (p *resourcePrincipalConfigurationProvider) PrivateRSAKey() (privateKey *rsa.PrivateKey, err error) { + if privateKey, err = p.keyProvider.ResourcePrincipalClient.PrivateKey(); err != nil { + err = fmt.Errorf("failed to get resource principal private key: %s", err.Error()) + return nil, err + } + return privateKey, nil +} + +func (p *resourcePrincipalConfigurationProvider) KeyID() (string, error) { + var securityToken string + var err error + if securityToken, err = p.keyProvider.ResourcePrincipalClient.SecurityToken(); err != nil { + return "", fmt.Errorf("failed to get resource principal security token: %s", err.Error()) + } + return fmt.Sprintf("ST$%s", securityToken), nil +} + +func (p *resourcePrincipalConfigurationProvider) TenancyOCID() (string, error) { + return p.keyProvider.ResourcePrincipalClient.instancePrincipalKeyProvider.TenancyOCID() +} + +// todo what is this +func (p *resourcePrincipalConfigurationProvider) GetClaim(key string) (interface{}, error) { + return nil, nil +} + +//Resource Principals +type resourcePrincipalConfigurationProvider struct { + keyProvider resourcePrincipalKeyProviderV1 + region *common.Region +} + +func newResourcePrincipalKeyProvider(ipKeyProvider instancePrincipalKeyProvider, rpTokenTargetServiceClient, rpSessionTokenClient common.BaseClient, instanceID, path string) (keyProvider resourcePrincipalKeyProviderV1, err error) { + rpFedClient := resourcePrincipalFederationClient{} + rpFedClient.tenancyID = ipKeyProvider.TenancyID + rpFedClient.instanceID = instanceID + rpFedClient.sessionKeySupplier = newSessionKeySupplier() + rpFedClient.ResourcePrincipalTargetServiceClient = rpTokenTargetServiceClient + rpFedClient.ResourcePrincipalSessionTokenClient = rpSessionTokenClient + rpFedClient.instancePrincipalKeyProvider = ipKeyProvider + rpFedClient.path = path + keyProvider = resourcePrincipalKeyProviderV1{ResourcePrincipalClient: rpFedClient} + return +} + +func (p *resourcePrincipalConfigurationProvider) AuthType() (common.AuthConfig, error) { + return common.AuthConfig{common.UnknownAuthenticationType, false, nil}, + fmt.Errorf("unsupported, keep the interface") +} + +func (p resourcePrincipalConfigurationProvider) UserOCID() (string, error) { + return "", nil +} + +func (p resourcePrincipalConfigurationProvider) KeyFingerprint() (string, error) { + return "", nil +} + +func (p resourcePrincipalConfigurationProvider) Region() (string, error) { + if p.region == nil { + region := p.keyProvider.ResourcePrincipalClient.instancePrincipalKeyProvider.RegionForFederationClient() + common.Debugf("Region in resource principal configuration provider is nil. Returning instance principal federation clients region: %s", region) + return string(region), nil + } + return string(*p.region), nil +} + +// resourcePrincipalConfigurationProviderForInstanceWithClients returns a configuration for instance principals +// resourcePrincipalTargetServiceTokenClient and resourcePrincipalSessionTokenClient are clients that at last need to have +// their base path and host properly set for their respective services. Additionally the clients can be further customized +// to provide mocking or any other customization for the requests/responses +func resourcePrincipalConfigurationProviderForInstanceWithClients(instancePrincipalProvider common.ConfigurationProvider, + resourcePrincipalTargetServiceTokenClient, resourcePrincipalSessionTokenClient common.BaseClient, instanceID, path string) (*resourcePrincipalConfigurationProvider, error) { + var ok bool + var ip instancePrincipalConfigurationProvider + if ip, ok = instancePrincipalProvider.(instancePrincipalConfigurationProvider); !ok { + return nil, fmt.Errorf("instancePrincipalConfigurationProvider needs to be of type vald Instance Principal Configuration Provider") + } + + keyProvider, err := newResourcePrincipalKeyProvider(ip.keyProvider, resourcePrincipalTargetServiceTokenClient, resourcePrincipalSessionTokenClient, instanceID, path) + if err != nil { + return nil, err + } + + provider := &resourcePrincipalConfigurationProvider{ + region: nil, + keyProvider: keyProvider, + } + return provider, nil +} + +const identityResourcePrincipalSessionTokenPath = "/v1/resourcePrincipalSessionToken" + +// resourcePrincipalConfigurationProviderForInstanceWithInterceptor creates a resource principal configuration provider with +// a interceptor used to customize the call going to the resource principal token request to the target service +// for a given instance ID +func resourcePrincipalConfigurationProviderForInstanceWithInterceptor(instancePrincipalProvider common.ConfigurationProvider, resourcePrincipalTokenEndpoint, instanceID string, interceptor common.RequestInterceptor) (provider *resourcePrincipalConfigurationProvider, err error) { + + //Build the target service client + rpTargetServiceClient, err := common.NewClientWithConfig(instancePrincipalProvider) + if err != nil { + return + } + + rpTokenURL, err := url.Parse(resourcePrincipalTokenEndpoint) + if err != nil { + return + } + + rpTargetServiceClient.Host = rpTokenURL.Scheme + "://" + rpTokenURL.Host + rpTargetServiceClient.Interceptor = interceptor + + var path string + if rpTokenURL.Path != "" { + path = rpTokenURL.Path + } else { + path = identityResourcePrincipalSessionTokenPath + } + + //Build the identity client for token service + rpTokenSessionClient, err := common.NewClientWithConfig(instancePrincipalProvider) + if err != nil { + return + } + + // Set RPST endpoint if passed in from env var, otherwise create it from region + resourcePrincipalSessionTokenEndpoint := requireEnv(ResourcePrincipalSessionTokenEndpoint) + if resourcePrincipalSessionTokenEndpoint != nil { + rpSessionTokenURL, err := url.Parse(*resourcePrincipalSessionTokenEndpoint) + if err != nil { + return nil, err + } + + rpTokenSessionClient.Host = rpSessionTokenURL.Scheme + "://" + rpSessionTokenURL.Host + } else { + regionStr, err := instancePrincipalProvider.Region() + if err != nil { + return nil, fmt.Errorf("missing RPST env var and cannot determine region: %v", err) + } + region := common.StringToRegion(regionStr) + rpTokenSessionClient.Host = fmt.Sprintf("https://%s", region.Endpoint("auth")) + } + + rpTokenSessionClient.BasePath = identityResourcePrincipalSessionTokenPath + + return resourcePrincipalConfigurationProviderForInstanceWithClients(instancePrincipalProvider, rpTargetServiceClient, rpTokenSessionClient, instanceID, path) +} + +// ResourcePrincipalConfigurationProviderWithInterceptor creates a resource principal configuration provider with endpoints +// a interceptor used to customize the call going to the resource principal token request to the target service +// see https://godoc.org/github.com/oracle/oci-go-sdk/common#RequestInterceptor +func ResourcePrincipalConfigurationProviderWithInterceptor(instancePrincipalProvider common.ConfigurationProvider, + resourcePrincipalTokenEndpoint, resourcePrincipalSessionTokenEndpoint string, + interceptor common.RequestInterceptor) (common.ConfigurationProvider, error) { + + return resourcePrincipalConfigurationProviderForInstanceWithInterceptor(instancePrincipalProvider, resourcePrincipalTokenEndpoint, "", interceptor) +} + +// resourcePrincipalConfigurationProviderV1 creates a resource principal configuration provider with +// endpoints for both resource principal token and resource principal token session +func resourcePrincipalConfigurationProviderV1(resourcePrincipalTokenEndpoint, resourceID string) (*resourcePrincipalConfigurationProvider, error) { + + instancePrincipalProvider, err := InstancePrincipalConfigurationProvider() + if err != nil { + return nil, err + } + return resourcePrincipalConfigurationProviderForInstanceWithInterceptor(instancePrincipalProvider, resourcePrincipalTokenEndpoint, resourceID, nil) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/utils.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/utils.go new file mode 100644 index 000000000..0a9b7ecfa --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/auth/utils.go @@ -0,0 +1,97 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package auth + +import ( + "bytes" + "crypto/sha1" + "crypto/x509" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" + "net/http/httputil" + "strings" +) + +// httpGet makes a simple HTTP GET request to the given URL, expecting only "200 OK" status code. +// This is basically for the Instance Metadata Service. +func httpGet(dispatcher common.HTTPRequestDispatcher, url string) (body bytes.Buffer, statusCode int, err error) { + var response *http.Response + request, err := http.NewRequest(http.MethodGet, url, nil) + + request.Header.Add("Authorization", "Bearer Oracle") + + if response, err = dispatcher.Do(request); err != nil { + return + } + + statusCode = response.StatusCode + common.IfDebug(func() { + if dump, e := httputil.DumpResponse(response, true); e == nil { + common.Logf("Dump Response %v", string(dump)) + } else { + common.Debugln(e) + } + }) + + defer response.Body.Close() + if _, err = body.ReadFrom(response.Body); err != nil { + return + } + + if statusCode != http.StatusOK { + err = fmt.Errorf("HTTP Get failed: URL: %s, Status: %s, Message: %s", + url, response.Status, body.String()) + return + } + + return +} + +func extractTenancyIDFromCertificate(cert *x509.Certificate) string { + for _, nameAttr := range cert.Subject.Names { + value := nameAttr.Value.(string) + if strings.HasPrefix(value, "opc-tenant:") { + return value[len("opc-tenant:"):] + } + } + return "" +} + +func fingerprint(certificate *x509.Certificate) string { + fingerprint := sha1.Sum(certificate.Raw) + return colonSeparatedString(fingerprint) +} + +func colonSeparatedString(fingerprint [sha1.Size]byte) string { + spaceSeparated := fmt.Sprintf("% x", fingerprint) + return strings.Replace(spaceSeparated, " ", ":", -1) +} + +func sanitizeCertificateString(certString string) string { + certString = strings.Replace(certString, "-----BEGIN CERTIFICATE-----", "", -1) + certString = strings.Replace(certString, "-----END CERTIFICATE-----", "", -1) + certString = strings.Replace(certString, "-----BEGIN PUBLIC KEY-----", "", -1) + certString = strings.Replace(certString, "-----END PUBLIC KEY-----", "", -1) + certString = strings.Replace(certString, "\n", "", -1) + return certString +} + +// GetGenericConfigurationProvider checks auth config paras in config file and return the final configuration provider +func GetGenericConfigurationProvider(configProvider common.ConfigurationProvider) (common.ConfigurationProvider, error) { + if authConfig, err := configProvider.AuthType(); err == nil && authConfig.IsFromConfigFile { + switch authConfig.AuthType { + case common.InstancePrincipalDelegationToken: + if region, err := configProvider.Region(); err == nil { + return InstancePrincipalDelegationTokenConfigurationProviderForRegion(authConfig.OboToken, common.StringToRegion(region)) + } + return InstancePrincipalDelegationTokenConfigurationProvider(authConfig.OboToken) + case common.InstancePrincipal: + return InstancePrincipalConfigurationProvider() + case common.UserPrincipal: + return configProvider, nil + } + } + return configProvider, nil +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/circuit_breaker.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/circuit_breaker.go new file mode 100644 index 000000000..b45ab3faf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/circuit_breaker.go @@ -0,0 +1,235 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package common + +import ( + "fmt" + "time" + + "github.com/sony/gobreaker" +) + +const ( + // CircuitBreakerDefaultFailureRateThreshold is the requests failure rate which calculates in at most 120 seconds, once reaches to this rate, the circuit breaker state changes from closed to open + CircuitBreakerDefaultFailureRateThreshold float64 = 0.80 + // CircuitBreakerDefaultClosedWindow is the default value of closeStateWindow, which is the cyclic period of the closed state + CircuitBreakerDefaultClosedWindow time.Duration = 120 * time.Second + // CircuitBreakerDefaultResetTimeout is the default value of openStateWindow, which is the wait time before setting the breaker to halfOpen state from open state + CircuitBreakerDefaultResetTimeout time.Duration = 30 * time.Second + // CircuitBreakerDefaultVolumeThreshold is the default value of minimumRequests in closed status + CircuitBreakerDefaultVolumeThreshold uint32 = 10 + // DefaultCircuitBreakerName is the name of the circuit breaker + DefaultCircuitBreakerName string = "DefaultCircuitBreaker" +) + +// CircuitBreakerSetting wraps all exposed configurable params of circuit breaker +type CircuitBreakerSetting struct { + // Name is the Circuit Breaker's identifier + name string + // isEnabled is the switch of the circuit breaker, used for disable circuit breaker + isEnabled bool + // closeStateWindow is the cyclic period of the closed state, the default value is 120 seconds + closeStateWindow time.Duration + // openStateWindow is the wait time before setting the breaker to halfOpen state from open state, the default value is 30 seconds + openStateWindow time.Duration + // failureRateThreshold is the failure rate which calculates in at most closeStateWindow seconds, once reaches to this rate, the circuit breaker state changes from closed to open + // the circuit will transition from closed to open, the default value is 80% + failureRateThreshold float64 + // minimumRequests is the minimum number of counted requests in closed state, the default value is 10 requests + minimumRequests uint32 + // successStatCodeMap is the error(s) of StatusCode returned from service, which should be considered as the success or failure accounted by circuit breaker + // successStatCodeMap and successStatErrCodeMap are combined to use, if both StatusCode and ErrorCode are required, no need to add it to successStatCodeMap, + // the default value is [429, 500, 502, 503, 504] + successStatCodeMap map[int]bool + // successStatErrCodeMap is the error(s) of StatusCode and ErrorCode returned from service, which should be considered + // as the success or failure accounted by circuit breaker + // the default value is {409, "IncorrectState"} + successStatErrCodeMap map[StatErrCode]bool +} + +// Convert CircuitBreakerSetting to human-readable string representation +func (cbst CircuitBreakerSetting) String() string { + return fmt.Sprintf("{name=%v, isEnabled=%v, closeStateWindow=%v, openStateWindow=%v, failureRateThreshold=%v, minimumRequests=%v, successStatCodeMap=%v, successStatErrCodeMap=%v}", + cbst.name, cbst.isEnabled, cbst.closeStateWindow, cbst.openStateWindow, cbst.failureRateThreshold, cbst.minimumRequests, cbst.successStatCodeMap, cbst.successStatErrCodeMap) +} + +// CircuitBreakerOption is the type of the options for NewCircuitBreakerWithOptions. +type CircuitBreakerOption func(cbst *CircuitBreakerSetting) + +// NewGoCircuitBreaker is a function to initialize a CircuitBreaker object with the specified configuration +// Add the interface, to allow the user directly use the 3P gobreaker.Setting's params. +func NewGoCircuitBreaker(st gobreaker.Settings) *gobreaker.CircuitBreaker { + return gobreaker.NewCircuitBreaker(st) +} + +// DefaultCircuitBreakerSetting is used for set circuit breaker with default config +func DefaultCircuitBreakerSetting() *CircuitBreakerSetting { + successStatErrCodeMap := map[StatErrCode]bool{ + {409, "IncorrectState"}: false, + } + successStatCodeMap := map[int]bool{ + 429: false, + 500: false, + 502: false, + 503: false, + 504: false, + } + return newCircuitBreakerSetting( + WithName(DefaultCircuitBreakerName), + WithIsEnabled(true), + WithCloseStateWindow(CircuitBreakerDefaultClosedWindow), + WithOpenStateWindow(CircuitBreakerDefaultResetTimeout), + WithFailureRateThreshold(CircuitBreakerDefaultFailureRateThreshold), + WithMinimumRequests(CircuitBreakerDefaultVolumeThreshold), + WithSuccessStatErrCodeMap(successStatErrCodeMap), + WithSuccessStatCodeMap(successStatCodeMap)) +} + +// NoCircuitBreakerSetting is used for disable Circuit Breaker +func NoCircuitBreakerSetting() *CircuitBreakerSetting { + return NewCircuitBreakerSettingWithOptions(WithIsEnabled(false)) +} + +// NewCircuitBreakerSettingWithOptions is a helper method to assemble a CircuitBreakerSetting object. +// It starts out with the values returned by defaultCircuitBreakerSetting(). +func NewCircuitBreakerSettingWithOptions(opts ...CircuitBreakerOption) *CircuitBreakerSetting { + cbst := DefaultCircuitBreakerSetting() + // allow changing values + for _, opt := range opts { + opt(cbst) + } + if defaultLogger.LogLevel() == verboseLogging { + Debugf("Circuit Breaker setting: %s\n", cbst.String()) + } + + return cbst +} + +// NewCircuitBreaker is used for initialing specified circuit breaker configuration with base client +func NewCircuitBreaker(cbst *CircuitBreakerSetting) *gobreaker.CircuitBreaker { + if !cbst.isEnabled { + return nil + } + st := gobreaker.Settings{} + customizeGoBreakerSetting(&st, cbst) + return gobreaker.NewCircuitBreaker(st) +} + +func newCircuitBreakerSetting(opts ...CircuitBreakerOption) *CircuitBreakerSetting { + cbSetting := CircuitBreakerSetting{} + + // allow changing values + for _, opt := range opts { + opt(&cbSetting) + } + return &cbSetting +} + +// customizeGoBreakerSetting is used for converting CircuitBreakerSetting to 3P gobreaker's setting type +func customizeGoBreakerSetting(st *gobreaker.Settings, cbst *CircuitBreakerSetting) { + st.Name = cbst.name + st.Timeout = cbst.openStateWindow + st.Interval = cbst.closeStateWindow + st.ReadyToTrip = func(counts gobreaker.Counts) bool { + failureRatio := float64(counts.TotalFailures) / float64(counts.Requests) + return counts.Requests >= cbst.minimumRequests && failureRatio >= cbst.failureRateThreshold + } + st.IsSuccessful = func(err error) bool { + if serviceErr, ok := IsServiceError(err); ok { + if isSuccessful, ok := cbst.successStatCodeMap[serviceErr.GetHTTPStatusCode()]; ok { + return isSuccessful + } + if isSuccessful, ok := cbst.successStatErrCodeMap[StatErrCode{serviceErr.GetHTTPStatusCode(), serviceErr.GetCode()}]; ok { + return isSuccessful + } + } + return true + } +} + +// WithName is the option for NewCircuitBreaker that sets the Name. +func WithName(name string) CircuitBreakerOption { + // this is the CircuitBreakerOption function type + return func(cbst *CircuitBreakerSetting) { + cbst.name = name + } +} + +// WithIsEnabled is the option for NewCircuitBreaker that sets the isEnabled. +func WithIsEnabled(isEnabled bool) CircuitBreakerOption { + // this is the CircuitBreakerOption function type + return func(cbst *CircuitBreakerSetting) { + cbst.isEnabled = isEnabled + } +} + +// WithCloseStateWindow is the option for NewCircuitBreaker that sets the closeStateWindow. +func WithCloseStateWindow(window time.Duration) CircuitBreakerOption { + // this is the CircuitBreakerOption function type + return func(cbst *CircuitBreakerSetting) { + cbst.closeStateWindow = window + } +} + +// WithOpenStateWindow is the option for NewCircuitBreaker that sets the openStateWindow. +func WithOpenStateWindow(window time.Duration) CircuitBreakerOption { + // this is the CircuitBreakerOption function type + return func(cbst *CircuitBreakerSetting) { + cbst.openStateWindow = window + } +} + +// WithFailureRateThreshold is the option for NewCircuitBreaker that sets the failureRateThreshold. +func WithFailureRateThreshold(threshold float64) CircuitBreakerOption { + // this is the CircuitBreakerOption function type + return func(cbst *CircuitBreakerSetting) { + cbst.failureRateThreshold = threshold + } +} + +// WithMinimumRequests is the option for NewCircuitBreaker that sets the minimumRequests. +func WithMinimumRequests(num uint32) CircuitBreakerOption { + // this is the CircuitBreakerOption function type + return func(cbst *CircuitBreakerSetting) { + cbst.minimumRequests = num + } +} + +// WithSuccessStatCodeMap is the option for NewCircuitBreaker that sets the successStatCodeMap. +func WithSuccessStatCodeMap(successStatCodeMap map[int]bool) CircuitBreakerOption { + // this is the CircuitBreakerOption function type + return func(cbst *CircuitBreakerSetting) { + cbst.successStatCodeMap = successStatCodeMap + } +} + +// WithSuccessStatErrCodeMap is the option for NewCircuitBreaker that sets the successStatErrCodeMap. +func WithSuccessStatErrCodeMap(successStatErrCodeMap map[StatErrCode]bool) CircuitBreakerOption { + // this is the CircuitBreakerOption function type + return func(cbst *CircuitBreakerSetting) { + cbst.successStatErrCodeMap = successStatErrCodeMap + } +} + +// GlobalCircuitBreakerSetting is global level circuit breaker setting, it would impact all services, the precedence is lower +// than client level circuit breaker +var GlobalCircuitBreakerSetting *CircuitBreakerSetting = nil + +// ConfigCircuitBreakerFromEnvVar is used for checking the circuit breaker environment variable setting, default value is nil +func ConfigCircuitBreakerFromEnvVar(baseClient *BaseClient) { + if IsEnvVarTrue(isDefaultCircuitBreakerEnabled) { + baseClient.Configuration.CircuitBreaker = NewCircuitBreaker(DefaultCircuitBreakerSetting()) + return + } + if IsEnvVarFalse(isDefaultCircuitBreakerEnabled) { + baseClient.Configuration.CircuitBreaker = nil + } +} + +// ConfigCircuitBreakerFromGlobalVar is used for checking if global circuitBreakerSetting is configured, the priority is higher than cb env var +func ConfigCircuitBreakerFromGlobalVar(baseClient *BaseClient) { + if GlobalCircuitBreakerSetting != nil { + baseClient.Configuration.CircuitBreaker = NewCircuitBreaker(GlobalCircuitBreakerSetting) + } +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/client.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/client.go new file mode 100644 index 000000000..0e4db22c4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/client.go @@ -0,0 +1,630 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +// Package common provides supporting functions and structs used by service packages +package common + +import ( + "bytes" + "context" + "fmt" + "io" + "io/ioutil" + "math/rand" + "net" + "net/http" + "net/http/httputil" + "net/url" + "os" + "os/user" + "path" + "reflect" + "runtime" + "strings" + "sync" + "sync/atomic" + "time" + + "github.com/sony/gobreaker" +) + +const ( + // DefaultHostURLTemplate The default url template for service hosts + DefaultHostURLTemplate = "%s.%s.oraclecloud.com" + + // requestHeaderAccept The key for passing a header to indicate Accept + requestHeaderAccept = "Accept" + + // requestHeaderAuthorization The key for passing a header to indicate Authorization + requestHeaderAuthorization = "Authorization" + + // requestHeaderContentLength The key for passing a header to indicate Content Length + requestHeaderContentLength = "Content-Length" + + // requestHeaderContentType The key for passing a header to indicate Content Type + requestHeaderContentType = "Content-Type" + + // requestHeaderExpect The key for passing a header to indicate Expect/100-Continue + requestHeaderExpect = "Expect" + + // requestHeaderDate The key for passing a header to indicate Date + requestHeaderDate = "Date" + + // requestHeaderIfMatch The key for passing a header to indicate If Match + requestHeaderIfMatch = "if-match" + + // requestHeaderOpcClientInfo The key for passing a header to indicate OPC Client Info + requestHeaderOpcClientInfo = "opc-client-info" + + // requestHeaderOpcRetryToken The key for passing a header to indicate OPC Retry Token + requestHeaderOpcRetryToken = "opc-retry-token" + + // requestHeaderOpcRequestID The key for unique Oracle-assigned identifier for the request. + requestHeaderOpcRequestID = "opc-request-id" + + // requestHeaderOpcClientRequestID The key for unique Oracle-assigned identifier for the request. + requestHeaderOpcClientRequestID = "opc-client-request-id" + + // requestHeaderUserAgent The key for passing a header to indicate User Agent + requestHeaderUserAgent = "User-Agent" + + // requestHeaderXContentSHA256 The key for passing a header to indicate SHA256 hash + requestHeaderXContentSHA256 = "X-Content-SHA256" + + // requestHeaderOpcOboToken The key for passing a header to use obo token + requestHeaderOpcOboToken = "opc-obo-token" + + // private constants + defaultScheme = "https" + defaultSDKMarker = "Oracle-GoSDK" + defaultUserAgentTemplate = "%s/%s (%s/%s; go/%s)" //SDK/SDKVersion (OS/OSVersion; Lang/LangVersion) + // http.Client.Timeout includes Dial, TLSHandshake, Request, Response header and body + defaultTimeout = 60 * time.Second + defaultConfigFileName = "config" + defaultConfigDirName = ".oci" + configFilePathEnvVarName = "OCI_CONFIG_FILE" + + secondaryConfigDirName = ".oraclebmc" + maxBodyLenForDebug = 1024 * 1000 + + // appendUserAgentEnv The key for retrieving append user agent value from env var + appendUserAgentEnv = "OCI_SDK_APPEND_USER_AGENT" + + // requestHeaderOpcClientRetries The key for passing a header to set client retries info + requestHeaderOpcClientRetries = "opc-client-retries" + + // isDefaultRetryEnabled The key for set default retry disabled from env var + isDefaultRetryEnabled = "OCI_SDK_DEFAULT_RETRY_ENABLED" + + // isDefaultCircuitBreakerEnabled is the key for set default circuit breaker disabled from env var + isDefaultCircuitBreakerEnabled = "OCI_SDK_DEFAULT_CIRCUITBREAKER_ENABLED" +) + +// RequestInterceptor function used to customize the request before calling the underlying service +type RequestInterceptor func(*http.Request) error + +// HTTPRequestDispatcher wraps the execution of a http request, it is generally implemented by +// http.Client.Do, but can be customized for testing +type HTTPRequestDispatcher interface { + Do(req *http.Request) (*http.Response, error) +} + +// CustomClientConfiguration contains configurations set at client level, currently it only includes RetryPolicy +type CustomClientConfiguration struct { + RetryPolicy *RetryPolicy + CircuitBreaker *gobreaker.CircuitBreaker +} + +// BaseClient struct implements all basic operations to call oci web services. +type BaseClient struct { + //HTTPClient performs the http network operations + HTTPClient HTTPRequestDispatcher + + //Signer performs auth operation + Signer HTTPRequestSigner + + //A request interceptor can be used to customize the request before signing and dispatching + Interceptor RequestInterceptor + + //The host of the service + Host string + + //The user agent + UserAgent string + + //Base path for all operations of this client + BasePath string + + Configuration CustomClientConfiguration +} + +// SetCustomClientConfiguration sets client with retry and other custom configurations +func (client *BaseClient) SetCustomClientConfiguration(config CustomClientConfiguration) { + client.Configuration = config +} + +// RetryPolicy returns the retryPolicy configured for client +func (client *BaseClient) RetryPolicy() *RetryPolicy { + return client.Configuration.RetryPolicy +} + +// Endpoint returns the endpoint configured for client +func (client *BaseClient) Endpoint() string { + host := client.Host + if !strings.Contains(host, "http") && + !strings.Contains(host, "https") { + host = fmt.Sprintf("%s://%s", defaultScheme, host) + } + return host +} + +func defaultUserAgent() string { + userAgent := fmt.Sprintf(defaultUserAgentTemplate, defaultSDKMarker, Version(), runtime.GOOS, runtime.GOARCH, runtime.Version()) + appendUA := os.Getenv(appendUserAgentEnv) + if appendUA != "" { + userAgent = fmt.Sprintf("%s %s", userAgent, appendUA) + } + return userAgent +} + +var clientCounter int64 + +func getNextSeed() int64 { + newCounterValue := atomic.AddInt64(&clientCounter, 1) + return newCounterValue + time.Now().UnixNano() +} + +func newBaseClient(signer HTTPRequestSigner, dispatcher HTTPRequestDispatcher) BaseClient { + rand.Seed(getNextSeed()) + + baseClient := BaseClient{ + UserAgent: defaultUserAgent(), + Interceptor: nil, + Signer: signer, + HTTPClient: dispatcher, + } + + // check the default retry environment variable setting + if IsEnvVarTrue(isDefaultRetryEnabled) { + defaultRetry := DefaultRetryPolicy() + baseClient.Configuration.RetryPolicy = &defaultRetry + } else if IsEnvVarFalse(isDefaultRetryEnabled) { + policy := NoRetryPolicy() + baseClient.Configuration.RetryPolicy = &policy + } + // check if user defined global retry is configured + if GlobalRetry != nil { + baseClient.Configuration.RetryPolicy = GlobalRetry + } + + return baseClient +} + +func defaultHTTPDispatcher() http.Client { + var httpClient http.Client + + if isExpectHeaderDisabled := IsEnvVarFalse(UsingExpectHeaderEnvVar); !isExpectHeaderDisabled { + var tp http.RoundTripper = &http.Transport{ + Proxy: http.ProxyFromEnvironment, + DialContext: (&net.Dialer{ + Timeout: 30 * time.Second, + KeepAlive: 30 * time.Second, + DualStack: true, + }).DialContext, + ForceAttemptHTTP2: true, + MaxIdleConns: 100, + IdleConnTimeout: 90 * time.Second, + TLSHandshakeTimeout: 10 * time.Second, + ExpectContinueTimeout: 3 * time.Second, + } + httpClient = http.Client{ + Transport: tp, + Timeout: defaultTimeout, + } + } else { + httpClient = http.Client{ + Timeout: defaultTimeout, + } + } + return httpClient +} + +func defaultBaseClient(provider KeyProvider) BaseClient { + dispatcher := defaultHTTPDispatcher() + signer := DefaultRequestSigner(provider) + return newBaseClient(signer, &dispatcher) +} + +//DefaultBaseClientWithSigner creates a default base client with a given signer +func DefaultBaseClientWithSigner(signer HTTPRequestSigner) BaseClient { + dispatcher := defaultHTTPDispatcher() + return newBaseClient(signer, &dispatcher) +} + +// NewClientWithConfig Create a new client with a configuration provider, the configuration provider +// will be used for the default signer as well as reading the region +// This function does not check for valid regions to implement forward compatibility +func NewClientWithConfig(configProvider ConfigurationProvider) (client BaseClient, err error) { + var ok bool + if ok, err = IsConfigurationProviderValid(configProvider); !ok { + err = fmt.Errorf("can not create client, bad configuration: %s", err.Error()) + return + } + + client = defaultBaseClient(configProvider) + + if authConfig, e := configProvider.AuthType(); e == nil && authConfig.OboToken != nil { + Debugf("authConfig's authType is %s, and token content is %s", authConfig.AuthType, *authConfig.OboToken) + signOboToken(&client, *authConfig.OboToken, configProvider) + } + + return +} + +// NewClientWithOboToken Create a new client that will use oboToken for auth +func NewClientWithOboToken(configProvider ConfigurationProvider, oboToken string) (client BaseClient, err error) { + client, err = NewClientWithConfig(configProvider) + if err != nil { + return + } + + signOboToken(&client, oboToken, configProvider) + + return +} + +// Add obo token header to Interceptor and sign to client +func signOboToken(client *BaseClient, oboToken string, configProvider ConfigurationProvider) { + // Interceptor to add obo token header + client.Interceptor = func(request *http.Request) error { + request.Header.Add(requestHeaderOpcOboToken, oboToken) + return nil + } + // Obo token will also be signed + defaultHeaders := append(DefaultGenericHeaders(), requestHeaderOpcOboToken) + client.Signer = RequestSigner(configProvider, defaultHeaders, DefaultBodyHeaders()) +} + +func getHomeFolder() string { + current, e := user.Current() + if e != nil { + //Give up and try to return something sensible + home := os.Getenv("HOME") + if home == "" { + home = os.Getenv("USERPROFILE") + } + return home + } + return current.HomeDir +} + +// DefaultConfigProvider returns the default config provider. The default config provider +// will look for configurations in 3 places: file in $HOME/.oci/config, HOME/.obmcs/config and +// variables names starting with the string TF_VAR. If the same configuration is found in multiple +// places the provider will prefer the first one. +// If the config file is not placed in the default location, the environment variable +// OCI_CONFIG_FILE can provide the config file location. +func DefaultConfigProvider() ConfigurationProvider { + defaultConfigFile := getDefaultConfigFilePath() + homeFolder := getHomeFolder() + secondaryConfigFile := path.Join(homeFolder, secondaryConfigDirName, defaultConfigFileName) + + defaultFileProvider, _ := ConfigurationProviderFromFile(defaultConfigFile, "") + secondaryFileProvider, _ := ConfigurationProviderFromFile(secondaryConfigFile, "") + environmentProvider := environmentConfigurationProvider{EnvironmentVariablePrefix: "TF_VAR"} + + provider, _ := ComposingConfigurationProvider([]ConfigurationProvider{defaultFileProvider, secondaryFileProvider, environmentProvider}) + Debugf("Configuration provided by: %s", provider) + return provider +} + +func getDefaultConfigFilePath() string { + homeFolder := getHomeFolder() + defaultConfigFile := path.Join(homeFolder, defaultConfigDirName, defaultConfigFileName) + if _, err := os.Stat(defaultConfigFile); err == nil { + return defaultConfigFile + } + Debugf("The %s does not exist, will check env var %s for file path.", defaultConfigFile, configFilePathEnvVarName) + // Read configuration file path from OCI_CONFIG_FILE env var + fallbackConfigFile, existed := os.LookupEnv(configFilePathEnvVarName) + if !existed { + Debugf("The env var %s does not exist...", configFilePathEnvVarName) + return defaultConfigFile + } + if _, err := os.Stat(fallbackConfigFile); os.IsNotExist(err) { + Debugf("The specified cfg file path in the env var %s does not exist: %s", configFilePathEnvVarName, fallbackConfigFile) + return defaultConfigFile + } + return fallbackConfigFile +} + +// CustomProfileConfigProvider returns the config provider of given profile. The custom profile config provider +// will look for configurations in 2 places: file in $HOME/.oci/config, and variables names starting with the +// string TF_VAR. If the same configuration is found in multiple places the provider will prefer the first one. +func CustomProfileConfigProvider(customConfigPath string, profile string) ConfigurationProvider { + homeFolder := getHomeFolder() + if customConfigPath == "" { + customConfigPath = path.Join(homeFolder, defaultConfigDirName, defaultConfigFileName) + } + customFileProvider, _ := ConfigurationProviderFromFileWithProfile(customConfigPath, profile, "") + defaultFileProvider, _ := ConfigurationProviderFromFileWithProfile(customConfigPath, "DEFAULT", "") + environmentProvider := environmentConfigurationProvider{EnvironmentVariablePrefix: "TF_VAR"} + provider, _ := ComposingConfigurationProvider([]ConfigurationProvider{customFileProvider, defaultFileProvider, environmentProvider}) + Debugf("Configuration provided by: %s", provider) + return provider +} + +func (client *BaseClient) prepareRequest(request *http.Request) (err error) { + if client.UserAgent == "" { + return fmt.Errorf("user agent can not be blank") + } + + if request.Header == nil { + request.Header = http.Header{} + } + request.Header.Set(requestHeaderUserAgent, client.UserAgent) + request.Header.Set(requestHeaderDate, time.Now().UTC().Format(http.TimeFormat)) + + if !strings.Contains(client.Host, "http") && + !strings.Contains(client.Host, "https") { + client.Host = fmt.Sprintf("%s://%s", defaultScheme, client.Host) + } + + clientURL, err := url.Parse(client.Host) + if err != nil { + return fmt.Errorf("host is invalid. %s", err.Error()) + } + request.URL.Host = clientURL.Host + request.URL.Scheme = clientURL.Scheme + currentPath := request.URL.Path + if !strings.Contains(currentPath, fmt.Sprintf("/%s", client.BasePath)) { + request.URL.Path = path.Clean(fmt.Sprintf("/%s/%s", client.BasePath, currentPath)) + } + return +} + +func (client BaseClient) intercept(request *http.Request) (err error) { + if client.Interceptor != nil { + err = client.Interceptor(request) + } + return +} + +// checkForSuccessfulResponse checks if the response is successful +// If Error Code is 4XX/5XX and debug level is set to info, will log the request and response +func checkForSuccessfulResponse(res *http.Response, requestBody *io.ReadCloser) error { + familyStatusCode := res.StatusCode / 100 + if familyStatusCode == 4 || familyStatusCode == 5 { + IfInfo(func() { + // If debug level is set to verbose, the request and request body will be dumped and logged under debug level, this is to avoid duplicate logging + if defaultLogger.LogLevel() < verboseLogging { + logRequest(res.Request, Logf, noLogging) + if requestBody != nil && *requestBody != http.NoBody { + bodyContent, _ := ioutil.ReadAll(*requestBody) + Logf("Dump Request Body: \n%s", string(bodyContent)) + } + } + logResponse(res, Logf, infoLogging) + }) + return newServiceFailureFromResponse(res) + } + IfDebug(func() { + logResponse(res, Debugf, verboseLogging) + }) + return nil +} + +func logRequest(request *http.Request, fn func(format string, v ...interface{}), bodyLoggingLevel int) { + if request == nil { + return + } + dumpBody := true + if checkBodyLengthExceedLimit(request.ContentLength) { + fn("not dumping body too big\n") + dumpBody = false + } + + dumpBody = dumpBody && defaultLogger.LogLevel() >= bodyLoggingLevel && bodyLoggingLevel != noLogging + if dump, e := httputil.DumpRequestOut(request, dumpBody); e == nil { + fn("Dump Request %s", string(dump)) + } else { + fn("%v\n", e) + } +} + +func logResponse(response *http.Response, fn func(format string, v ...interface{}), bodyLoggingLevel int) { + if response == nil { + return + } + dumpBody := true + if checkBodyLengthExceedLimit(response.ContentLength) { + fn("not dumping body too big\n") + dumpBody = false + } + dumpBody = dumpBody && defaultLogger.LogLevel() >= bodyLoggingLevel && bodyLoggingLevel != noLogging + if dump, e := httputil.DumpResponse(response, dumpBody); e == nil { + fn("Dump Response %s", string(dump)) + } else { + fn("%v\n", e) + } +} + +func checkBodyLengthExceedLimit(contentLength int64) bool { + if contentLength > maxBodyLenForDebug { + return true + } + return false +} + +// OCIRequest is any request made to an OCI service. +type OCIRequest interface { + // HTTPRequest assembles an HTTP request. + HTTPRequest(method, path string, binaryRequestBody *OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) +} + +// RequestMetadata is metadata about an OCIRequest. This structure represents the behavior exhibited by the SDK when +// issuing (or reissuing) a request. +type RequestMetadata struct { + // RetryPolicy is the policy for reissuing the request. If no retry policy is set on the request, + // then the request will be issued exactly once. + RetryPolicy *RetryPolicy +} + +// OCIReadSeekCloser is a thread-safe io.ReadSeekCloser to prevent racing with retrying binary requests +type OCIReadSeekCloser struct { + rc io.ReadCloser + lock sync.Mutex + isClosed bool +} + +// NewOCIReadSeekCloser constructs OCIReadSeekCloser, the only input is binary request body +func NewOCIReadSeekCloser(rc io.ReadCloser) *OCIReadSeekCloser { + rsc := OCIReadSeekCloser{} + rsc.rc = rc + return &rsc +} + +// Seek is a thread-safe operation, it implements io.seek() interface, if the original request body implements io.seek() +// interface, or implements "well-known" data type like os.File, io.SectionReader, or wrapped by ioutil.NopCloser can be supported +func (rsc *OCIReadSeekCloser) Seek(offset int64, whence int) (int64, error) { + rsc.lock.Lock() + defer rsc.lock.Unlock() + + if _, ok := rsc.rc.(io.Seeker); ok { + return rsc.rc.(io.Seeker).Seek(offset, whence) + } + // once the binary request body is wrapped with ioutil.NopCloser: + if reflect.TypeOf(rsc.rc) == reflect.TypeOf(ioutil.NopCloser(nil)) { + unwrappedInterface := reflect.ValueOf(rsc.rc).Field(0).Interface() + if _, ok := unwrappedInterface.(io.Seeker); ok { + return unwrappedInterface.(io.Seeker).Seek(offset, whence) + } + } + return 0, fmt.Errorf("current binary request body type is not seekable, if want to use retry feature, please make sure the request body implements seek() method") +} + +// Close is a thread-safe operation, it closes the instance of the OCIReadSeekCloser's access to the underlying io.ReadCloser. +func (rsc *OCIReadSeekCloser) Close() error { + rsc.lock.Lock() + defer rsc.lock.Unlock() + rsc.isClosed = true + return nil +} + +// Read is a thread-safe operation, it implements io.Read() interface +func (rsc *OCIReadSeekCloser) Read(p []byte) (n int, err error) { + rsc.lock.Lock() + defer rsc.lock.Unlock() + + if rsc.isClosed { + return 0, io.EOF + } + + return rsc.rc.Read(p) +} + +// Seekable is used for check if the binary request body can be seek or no +func (rsc *OCIReadSeekCloser) Seekable() bool { + if rsc == nil { + return false + } + if _, ok := rsc.rc.(io.Seeker); ok { + return true + } + // once the binary request body is wrapped with ioutil.NopCloser: + if reflect.TypeOf(rsc.rc) == reflect.TypeOf(ioutil.NopCloser(nil)) { + if _, ok := reflect.ValueOf(rsc.rc).Field(0).Interface().(io.Seeker); ok { + return true + } + } + return false +} + +// OCIResponse is the response from issuing a request to an OCI service. +type OCIResponse interface { + // HTTPResponse returns the raw HTTP response. + HTTPResponse() *http.Response +} + +// OCIOperation is the generalization of a request-response cycle undergone by an OCI service. +type OCIOperation func(context.Context, OCIRequest, *OCIReadSeekCloser, map[string]string) (OCIResponse, error) + +//ClientCallDetails a set of settings used by the a single Call operation of the http Client +type ClientCallDetails struct { + Signer HTTPRequestSigner +} + +// Call executes the http request with the given context +func (client BaseClient) Call(ctx context.Context, request *http.Request) (response *http.Response, err error) { + return client.CallWithDetails(ctx, request, ClientCallDetails{Signer: client.Signer}) +} + +// CallWithDetails executes the http request, the given context using details specified in the parameters, this function +// provides a way to override some settings present in the client +func (client BaseClient) CallWithDetails(ctx context.Context, request *http.Request, details ClientCallDetails) (response *http.Response, err error) { + Debugln("Attempting to call downstream service") + request = request.WithContext(ctx) + + err = client.prepareRequest(request) + if err != nil { + return + } + + //Intercept + err = client.intercept(request) + if err != nil { + return + } + + //Sign the request + err = details.Signer.Sign(request) + if err != nil { + return + } + + //Execute the http request + if goBreaker := client.Configuration.CircuitBreaker; goBreaker != nil { + resp, cbErr := goBreaker.Execute(func() (interface{}, error) { + return client.httpDo(request) + }) + if cbErr != nil { + return resp.(*http.Response), cbErr + } + return resp.(*http.Response), nil + } + return client.httpDo(request) +} + +func (client BaseClient) httpDo(request *http.Request) (response *http.Response, err error) { + + //Copy request body and save for logging + dumpRequestBody := ioutil.NopCloser(bytes.NewBuffer(nil)) + if request.Body != nil && !checkBodyLengthExceedLimit(request.ContentLength) { + if dumpRequestBody, request.Body, err = drainBody(request.Body); err != nil { + dumpRequestBody = ioutil.NopCloser(bytes.NewBuffer(nil)) + } + } + IfDebug(func() { + logRequest(request, Debugf, verboseLogging) + }) + + //Execute the http request + response, err = client.HTTPClient.Do(request) + + if err != nil { + IfInfo(func() { + Logf("%v\n", err) + }) + return response, err + } + + err = checkForSuccessfulResponse(response, &dumpRequestBody) + return response, err +} + +//CloseBodyIfValid closes the body of an http response if the response and the body are valid +func CloseBodyIfValid(httpResponse *http.Response) { + if httpResponse != nil && httpResponse.Body != nil { + httpResponse.Body.Close() + } +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/common.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/common.go new file mode 100644 index 000000000..1e80bf6cd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/common.go @@ -0,0 +1,339 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package common + +import ( + "encoding/json" + "fmt" + "io/ioutil" + "net/http" + "os" + "path" + "regexp" + "strings" + "time" +) + +//Region type for regions +type Region string + +const ( + instanceMetadataRegionInfoURLV2 = "http://169.254.169.254/opc/v2/instance/regionInfo" + + // Region Metadata Configuration File + regionMetadataCfgDirName = ".oci" + regionMetadataCfgFileName = "regions-config.json" + + // Region Metadata Environment Variable + regionMetadataEnvVarName = "OCI_REGION_METADATA" + + // Default Realm Environment Variable + defaultRealmEnvVarName = "OCI_DEFAULT_REALM" + + // Region Metadata + regionIdentifierPropertyName = "regionIdentifier" // e.g. "ap-sydney-1" + realmKeyPropertyName = "realmKey" // e.g. "oc1" + realmDomainComponentPropertyName = "realmDomainComponent" // e.g. "oraclecloud.com" + regionKeyPropertyName = "regionKey" // e.g. "SYD" +) + +// External region metadata info flag, used to control adding these metadata region info only once. +var readCfgFile, readEnvVar, visitIMDS bool = true, true, false + +// getRegionInfoFromInstanceMetadataService gets the region information +var getRegionInfoFromInstanceMetadataService = getRegionInfoFromInstanceMetadataServiceProd + +// Endpoint returns a endpoint for a service +func (region Region) Endpoint(service string) string { + return fmt.Sprintf("%s.%s.%s", service, region, region.secondLevelDomain()) +} + +// EndpointForTemplate returns a endpoint for a service based on template, only unknown region name can fall back to "oc1", but not short code region name. +func (region Region) EndpointForTemplate(service string, serviceEndpointTemplate string) string { + if serviceEndpointTemplate == "" { + return region.Endpoint(service) + } + + // replace service prefix + endpoint := strings.Replace(serviceEndpointTemplate, "{serviceEndpointPrefix}", service, 1) + + // replace region + endpoint = strings.Replace(endpoint, "{region}", string(region), 1) + + // replace second level domain + endpoint = strings.Replace(endpoint, "{secondLevelDomain}", region.secondLevelDomain(), 1) + + return endpoint +} + +func (region Region) secondLevelDomain() string { + if realmID, ok := regionRealm[region]; ok { + if secondLevelDomain, ok := realm[realmID]; ok { + return secondLevelDomain + } + } + if value, ok := os.LookupEnv(defaultRealmEnvVarName); ok { + return value + } + Debugf("cannot find realm for region : %s, return default realm value.", region) + return realm["oc1"] +} + +// RealmID is used for getting realmID from region, if no region found, directly throw error +func (region Region) RealmID() (string, error) { + if realmID, ok := regionRealm[region]; ok { + return realmID, nil + } + + return "", fmt.Errorf("cannot find realm for region : %s", region) +} + +//StringToRegion convert a string to Region type +func StringToRegion(stringRegion string) (r Region) { + regionStr := strings.ToLower(stringRegion) + // check if short region name provided + if region, ok := shortNameRegion[regionStr]; ok { + r = region + return + } + // check if normal region name provided + potentialRegion := Region(regionStr) + if _, ok := regionRealm[potentialRegion]; ok { + r = potentialRegion + return + } + + Debugf("region named: %s, is not recognized from hard-coded region list, will check Region metadata info", stringRegion) + r = checkAndAddRegionMetadata(stringRegion) + + return +} + +// canStringBeRegion test if the string can be a region, if it can, returns the string as is, otherwise it +// returns an error +var blankRegex = regexp.MustCompile("\\s") + +func canStringBeRegion(stringRegion string) (region string, err error) { + if blankRegex.MatchString(stringRegion) || stringRegion == "" { + return "", fmt.Errorf("region can not be empty or have spaces") + } + return stringRegion, nil +} + +// check region info from original map +func checkAndAddRegionMetadata(region string) Region { + switch { + case setRegionMetadataFromCfgFile(®ion): + case setRegionMetadataFromEnvVar(®ion): + case setRegionFromInstanceMetadataService(®ion): + default: + //err := fmt.Errorf("failed to get region metadata information.") + return Region(region) + } + return Region(region) +} + +// EnableInstanceMetadataServiceLookup provides the interface to lookup IMDS region info +func EnableInstanceMetadataServiceLookup() { + Debugf("Set visitIMDS 'true' to enable IMDS Lookup.") + visitIMDS = true +} + +// setRegionMetadataFromEnvVar checks if region metadata env variable is provided, once it's there, parse and added it +// to region map, and it can make sure the env var can only be visited once. +// Once successfully find the expected region(region name or short code), return true, region name will be stored in +// the input pointer. +func setRegionMetadataFromEnvVar(region *string) bool { + if readEnvVar == false { + Debugf("metadata region env variable had already been checked, no need to check again.") + return false //no need to check it again. + } + // Mark readEnvVar Flag as false since it has already been visited. + readEnvVar = false + // check from env variable + if jsonStr, existed := os.LookupEnv(regionMetadataEnvVarName); existed { + Debugf("Raw content of region metadata env var:", jsonStr) + var regionSchema map[string]string + if err := json.Unmarshal([]byte(jsonStr), ®ionSchema); err != nil { + Debugf("Can't unmarshal env var, the error info is", err) + return false + } + // check if the specified region is in the env var. + if checkSchemaItems(regionSchema) { + // set mapping table + addRegionSchema(regionSchema) + if regionSchema[regionKeyPropertyName] == *region || + regionSchema[regionIdentifierPropertyName] == *region { + *region = regionSchema[regionIdentifierPropertyName] + return true + } + } + return false + } + Debugf("The Region Metadata Schema wasn't set in env variable - OCI_REGION_METADATA.") + return false +} + +// setRegionMetadataFromCfgFile checks if region metadata config file is provided, once it's there, parse and add all +// the valid regions to region map, the configuration file can only be visited once. +// Once successfully find the expected region(region name or short code), return true, region name will be stored in +// the input pointer. +func setRegionMetadataFromCfgFile(region *string) bool { + if readCfgFile == false { + Debugf("metadata region config file had already been checked, no need to check again.") + return false //no need to check it again. + } + // Mark readCfgFile Flag as false since it has already been visited. + readCfgFile = false + homeFolder := getHomeFolder() + configFile := path.Join(homeFolder, regionMetadataCfgDirName, regionMetadataCfgFileName) + if jsonArr, ok := readAndParseConfigFile(&configFile); ok { + added := false + for _, jsonItem := range jsonArr { + if checkSchemaItems(jsonItem) { + addRegionSchema(jsonItem) + if jsonItem[regionKeyPropertyName] == *region || + jsonItem[regionIdentifierPropertyName] == *region { + *region = jsonItem[regionIdentifierPropertyName] + added = true + } + } + } + return added + } + return false +} + +func readAndParseConfigFile(configFileName *string) (fileContent []map[string]string, ok bool) { + + if content, err := ioutil.ReadFile(*configFileName); err == nil { + Debugf("Raw content of region metadata config file content:", string(content[:])) + if err := json.Unmarshal(content, &fileContent); err != nil { + Debugf("Can't unmarshal config file, the error info is", err) + return + } + ok = true + return + } + Debugf("No Region Metadata Config File provided.") + return + +} + +// check map regionRealm's region name, if it's already there, no need to add it. +func addRegionSchema(regionSchema map[string]string) { + r := Region(strings.ToLower(regionSchema[regionIdentifierPropertyName])) + if _, ok := regionRealm[r]; !ok { + // set mapping table + shortNameRegion[regionSchema[regionKeyPropertyName]] = r + realm[regionSchema[realmKeyPropertyName]] = regionSchema[realmDomainComponentPropertyName] + regionRealm[r] = regionSchema[realmKeyPropertyName] + return + } + Debugf("Region {} has already been added, no need to add again.", regionSchema[regionIdentifierPropertyName]) +} + +// check region schema content if all the required contents are provided +func checkSchemaItems(regionSchema map[string]string) bool { + if checkSchemaItem(regionSchema, regionIdentifierPropertyName) && + checkSchemaItem(regionSchema, realmKeyPropertyName) && + checkSchemaItem(regionSchema, realmDomainComponentPropertyName) && + checkSchemaItem(regionSchema, regionKeyPropertyName) { + return true + } + return false +} + +// check region schema item is valid, if so, convert it to lower case. +func checkSchemaItem(regionSchema map[string]string, key string) bool { + if val, ok := regionSchema[key]; ok { + if val != "" { + regionSchema[key] = strings.ToLower(val) + return true + } + Debugf("Region metadata schema {} is provided,but content is empty.", key) + return false + } + Debugf("Region metadata schema {} is not provided, please update the content", key) + return false +} + +// setRegionFromInstanceMetadataService checks if region metadata can be provided from InstanceMetadataService. +// Once successfully find the expected region(region name or short code), return true, region name will be stored in +// the input pointer. +// setRegionFromInstanceMetadataService will only be checked on the instance, by default it will not be enabled unless +// user explicitly enable it. +func setRegionFromInstanceMetadataService(region *string) bool { + // example of content: + // { + // "realmKey" : "oc1", + // "realmDomainComponent" : "oraclecloud.com", + // "regionKey" : "YUL", + // "regionIdentifier" : "ca-montreal-1" + // } + // Mark visitIMDS Flag as false since it has already been visited. + if visitIMDS == false { + Debugf("check from IMDS is disabled or IMDS had already been successfully visited, no need to check again.") + return false + } + content, err := getRegionInfoFromInstanceMetadataService() + if err != nil { + Debugf("Failed to get instance metadata. Error: %v", err) + return false + } + + // Mark visitIMDS Flag as false since we have already successfully get the region info from IMDS. + visitIMDS = false + + var regionInfo map[string]string + err = json.Unmarshal(content, ®ionInfo) + if err != nil { + Debugf("Failed to unmarshal the response content: %v \nError: %v", string(content), err) + return false + } + + if checkSchemaItems(regionInfo) { + addRegionSchema(regionInfo) + if regionInfo[regionKeyPropertyName] == *region || + regionInfo[regionIdentifierPropertyName] == *region { + *region = regionInfo[regionIdentifierPropertyName] + } + } else { + Debugf("Region information is not valid.") + return false + } + + return true +} + +// getRegionInfoFromInstanceMetadataServiceProd calls instance metadata service and get the region information +func getRegionInfoFromInstanceMetadataServiceProd() ([]byte, error) { + request, err := http.NewRequest(http.MethodGet, instanceMetadataRegionInfoURLV2, nil) + request.Header.Add("Authorization", "Bearer Oracle") + + client := &http.Client{ + Timeout: time.Second * 10, + } + resp, err := client.Do(request) + if err != nil { + return nil, fmt.Errorf("Failed to call instance metadata service. Error: %v", err) + } + + statusCode := resp.StatusCode + + defer resp.Body.Close() + + content, err := ioutil.ReadAll(resp.Body) + if err != nil { + return nil, fmt.Errorf("Failed to get region information from response body. Error: %v", err) + } + + if statusCode != http.StatusOK { + err = fmt.Errorf("HTTP Get failed: URL: %s, Status: %s, Message: %s", + instanceMetadataRegionInfoURLV2, resp.Status, string(content)) + return nil, err + } + + return content, nil +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/configuration.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/configuration.go new file mode 100644 index 000000000..90019f70f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/configuration.go @@ -0,0 +1,659 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package common + +import ( + "crypto/rsa" + "errors" + "fmt" + "io/ioutil" + "os" + "path" + "regexp" + "strings" +) + +// AuthenticationType for auth +type AuthenticationType string + +const ( + // UserPrincipal is default auth type + UserPrincipal AuthenticationType = "user_principal" + // InstancePrincipal is used for instance principle auth type + InstancePrincipal AuthenticationType = "instance_principal" + // InstancePrincipalDelegationToken is used for instance principle delegation token auth type + InstancePrincipalDelegationToken AuthenticationType = "instance_principle_delegation_token" + // UnknownAuthenticationType is used for none meaningful auth type + UnknownAuthenticationType AuthenticationType = "unknown_auth_type" +) + +// AuthConfig is used for getting auth related paras in config file +type AuthConfig struct { + AuthType AuthenticationType + // IsFromConfigFile is used to point out if the authConfig is from configuration file + IsFromConfigFile bool + OboToken *string +} + +// ConfigurationProvider wraps information about the account owner +type ConfigurationProvider interface { + KeyProvider + TenancyOCID() (string, error) + UserOCID() (string, error) + KeyFingerprint() (string, error) + Region() (string, error) + // AuthType() is used for specify the needed auth type, like UserPrincipal, InstancePrincipal, etc. + AuthType() (AuthConfig, error) +} + +// IsConfigurationProviderValid Tests all parts of the configuration provider do not return an error, this method will +// not check AuthType(), since authType() is not required to be there. +func IsConfigurationProviderValid(conf ConfigurationProvider) (ok bool, err error) { + baseFn := []func() (string, error){conf.TenancyOCID, conf.UserOCID, conf.KeyFingerprint, conf.Region, conf.KeyID} + for _, fn := range baseFn { + _, err = fn() + ok = err == nil + if err != nil { + return + } + } + + _, err = conf.PrivateRSAKey() + ok = err == nil + if err != nil { + return + } + return true, nil +} + +// rawConfigurationProvider allows a user to simply construct a configuration provider from raw values. +type rawConfigurationProvider struct { + tenancy string + user string + region string + fingerprint string + privateKey string + privateKeyPassphrase *string +} + +// NewRawConfigurationProvider will create a ConfigurationProvider with the arguments of the function +func NewRawConfigurationProvider(tenancy, user, region, fingerprint, privateKey string, privateKeyPassphrase *string) ConfigurationProvider { + return rawConfigurationProvider{tenancy, user, region, fingerprint, privateKey, privateKeyPassphrase} +} + +func (p rawConfigurationProvider) PrivateRSAKey() (key *rsa.PrivateKey, err error) { + return PrivateKeyFromBytes([]byte(p.privateKey), p.privateKeyPassphrase) +} + +func (p rawConfigurationProvider) KeyID() (keyID string, err error) { + tenancy, err := p.TenancyOCID() + if err != nil { + return + } + + user, err := p.UserOCID() + if err != nil { + return + } + + fingerprint, err := p.KeyFingerprint() + if err != nil { + return + } + + return fmt.Sprintf("%s/%s/%s", tenancy, user, fingerprint), nil +} + +func (p rawConfigurationProvider) TenancyOCID() (string, error) { + if p.tenancy == "" { + return "", fmt.Errorf("tenancy OCID can not be empty") + } + return p.tenancy, nil +} + +func (p rawConfigurationProvider) UserOCID() (string, error) { + if p.user == "" { + return "", fmt.Errorf("user OCID can not be empty") + } + return p.user, nil +} + +func (p rawConfigurationProvider) KeyFingerprint() (string, error) { + if p.fingerprint == "" { + return "", fmt.Errorf("fingerprint can not be empty") + } + return p.fingerprint, nil +} + +func (p rawConfigurationProvider) Region() (string, error) { + return canStringBeRegion(p.region) +} + +func (p rawConfigurationProvider) AuthType() (AuthConfig, error) { + return AuthConfig{UnknownAuthenticationType, false, nil}, nil +} + +// environmentConfigurationProvider reads configuration from environment variables +type environmentConfigurationProvider struct { + PrivateKeyPassword string + EnvironmentVariablePrefix string +} + +// ConfigurationProviderEnvironmentVariables creates a ConfigurationProvider from a uniform set of environment variables starting with a prefix +// The env variables should look like: [prefix]_private_key_path, [prefix]_tenancy_ocid, [prefix]_user_ocid, [prefix]_fingerprint +// [prefix]_region +func ConfigurationProviderEnvironmentVariables(environmentVariablePrefix, privateKeyPassword string) ConfigurationProvider { + return environmentConfigurationProvider{EnvironmentVariablePrefix: environmentVariablePrefix, + PrivateKeyPassword: privateKeyPassword} +} + +func (p environmentConfigurationProvider) String() string { + return fmt.Sprintf("Configuration provided by environment variables prefixed with: %s", p.EnvironmentVariablePrefix) +} + +func (p environmentConfigurationProvider) PrivateRSAKey() (key *rsa.PrivateKey, err error) { + environmentVariable := fmt.Sprintf("%s_%s", p.EnvironmentVariablePrefix, "private_key_path") + var ok bool + var value string + if value, ok = os.LookupEnv(environmentVariable); !ok { + return nil, fmt.Errorf("can not read PrivateKey from env variable: %s", environmentVariable) + } + + expandedPath := expandPath(value) + pemFileContent, err := ioutil.ReadFile(expandedPath) + if err != nil { + Debugln("Can not read PrivateKey location from environment variable: " + environmentVariable) + return + } + + key, err = PrivateKeyFromBytes(pemFileContent, &p.PrivateKeyPassword) + return +} + +func (p environmentConfigurationProvider) KeyID() (keyID string, err error) { + ocid, err := p.TenancyOCID() + if err != nil { + return + } + + userocid, err := p.UserOCID() + if err != nil { + return + } + + fingerprint, err := p.KeyFingerprint() + if err != nil { + return + } + + return fmt.Sprintf("%s/%s/%s", ocid, userocid, fingerprint), nil +} + +func (p environmentConfigurationProvider) TenancyOCID() (value string, err error) { + environmentVariable := fmt.Sprintf("%s_%s", p.EnvironmentVariablePrefix, "tenancy_ocid") + var ok bool + if value, ok = os.LookupEnv(environmentVariable); !ok { + err = fmt.Errorf("can not read Tenancy from environment variable %s", environmentVariable) + } + return +} + +func (p environmentConfigurationProvider) UserOCID() (value string, err error) { + environmentVariable := fmt.Sprintf("%s_%s", p.EnvironmentVariablePrefix, "user_ocid") + var ok bool + if value, ok = os.LookupEnv(environmentVariable); !ok { + err = fmt.Errorf("can not read user id from environment variable %s", environmentVariable) + } + return +} + +func (p environmentConfigurationProvider) KeyFingerprint() (value string, err error) { + environmentVariable := fmt.Sprintf("%s_%s", p.EnvironmentVariablePrefix, "fingerprint") + var ok bool + if value, ok = os.LookupEnv(environmentVariable); !ok { + err = fmt.Errorf("can not read fingerprint from environment variable %s", environmentVariable) + } + return +} + +func (p environmentConfigurationProvider) Region() (value string, err error) { + environmentVariable := fmt.Sprintf("%s_%s", p.EnvironmentVariablePrefix, "region") + var ok bool + if value, ok = os.LookupEnv(environmentVariable); !ok { + err = fmt.Errorf("can not read region from environment variable %s", environmentVariable) + return value, err + } + + return canStringBeRegion(value) +} + +func (p environmentConfigurationProvider) AuthType() (AuthConfig, error) { + return AuthConfig{UnknownAuthenticationType, false, nil}, + fmt.Errorf("unsupported, keep the interface") +} + +// fileConfigurationProvider. reads configuration information from a file +type fileConfigurationProvider struct { + //The path to the configuration file + ConfigPath string + + //The password for the private key + PrivateKeyPassword string + + //The profile for the configuration + Profile string + + //ConfigFileInfo + FileInfo *configFileInfo +} + +// ConfigurationProviderFromFile creates a configuration provider from a configuration file +// by reading the "DEFAULT" profile +func ConfigurationProviderFromFile(configFilePath, privateKeyPassword string) (ConfigurationProvider, error) { + if configFilePath == "" { + return nil, fmt.Errorf("config file path can not be empty") + } + + return fileConfigurationProvider{ + ConfigPath: configFilePath, + PrivateKeyPassword: privateKeyPassword, + Profile: "DEFAULT"}, nil +} + +// ConfigurationProviderFromFileWithProfile creates a configuration provider from a configuration file +// and the given profile +func ConfigurationProviderFromFileWithProfile(configFilePath, profile, privateKeyPassword string) (ConfigurationProvider, error) { + if configFilePath == "" { + return nil, fmt.Errorf("config file path can not be empty") + } + + return fileConfigurationProvider{ + ConfigPath: configFilePath, + PrivateKeyPassword: privateKeyPassword, + Profile: profile}, nil +} + +type configFileInfo struct { + UserOcid, Fingerprint, KeyFilePath, TenancyOcid, Region, Passphrase, SecurityTokenFilePath, DelegationTokenFilePath, + AuthenticationType string + PresentConfiguration rune +} + +const ( + hasTenancy = 1 << iota + hasUser + hasFingerprint + hasRegion + hasKeyFile + hasPassphrase + hasSecurityTokenFile + hasDelegationTokenFile + hasAuthenticationType + none +) + +var profileRegex = regexp.MustCompile(`^\[(.*)\]`) + +func parseConfigFile(data []byte, profile string) (info *configFileInfo, err error) { + + if len(data) == 0 { + return nil, fmt.Errorf("configuration file content is empty") + } + + content := string(data) + splitContent := strings.Split(content, "\n") + + //Look for profile + for i, line := range splitContent { + if match := profileRegex.FindStringSubmatch(line); match != nil && len(match) > 1 && match[1] == profile { + start := i + 1 + return parseConfigAtLine(start, splitContent) + } + } + + return nil, fmt.Errorf("configuration file did not contain profile: %s", profile) +} + +func parseConfigAtLine(start int, content []string) (info *configFileInfo, err error) { + var configurationPresent rune + info = &configFileInfo{} + for i := start; i < len(content); i++ { + line := content[i] + if profileRegex.MatchString(line) { + break + } + + if !strings.Contains(line, "=") { + continue + } + + splits := strings.Split(line, "=") + switch key, value := strings.TrimSpace(splits[0]), strings.TrimSpace(splits[1]); strings.ToLower(key) { + case "passphrase", "pass_phrase": + configurationPresent = configurationPresent | hasPassphrase + info.Passphrase = value + case "user": + configurationPresent = configurationPresent | hasUser + info.UserOcid = value + case "fingerprint": + configurationPresent = configurationPresent | hasFingerprint + info.Fingerprint = value + case "key_file": + configurationPresent = configurationPresent | hasKeyFile + info.KeyFilePath = value + case "tenancy": + configurationPresent = configurationPresent | hasTenancy + info.TenancyOcid = value + case "region": + configurationPresent = configurationPresent | hasRegion + info.Region = value + case "security_token_file": + configurationPresent = configurationPresent | hasSecurityTokenFile + info.SecurityTokenFilePath = value + case "delegation_token_file": + configurationPresent = configurationPresent | hasDelegationTokenFile + info.DelegationTokenFilePath = value + case "authentication_type": + configurationPresent = configurationPresent | hasAuthenticationType + info.AuthenticationType = value + } + } + info.PresentConfiguration = configurationPresent + return + +} + +// cleans and expands the path if it contains a tilde , returns the expanded path or the input path as is if not expansion +// was performed +func expandPath(filepath string) (expandedPath string) { + cleanedPath := path.Clean(filepath) + expandedPath = cleanedPath + if strings.HasPrefix(cleanedPath, "~") { + rest := cleanedPath[2:] + expandedPath = path.Join(getHomeFolder(), rest) + } + return +} + +func openConfigFile(configFilePath string) (data []byte, err error) { + expandedPath := expandPath(configFilePath) + data, err = ioutil.ReadFile(expandedPath) + if err != nil { + err = fmt.Errorf("can not read config file: %s due to: %s", configFilePath, err.Error()) + } + + return +} + +func (p fileConfigurationProvider) String() string { + return fmt.Sprintf("Configuration provided by file: %s", p.ConfigPath) +} + +func (p fileConfigurationProvider) readAndParseConfigFile() (info *configFileInfo, err error) { + if p.FileInfo != nil { + return p.FileInfo, nil + } + + if p.ConfigPath == "" { + return nil, fmt.Errorf("configuration path can not be empty") + } + + data, err := openConfigFile(p.ConfigPath) + if err != nil { + err = fmt.Errorf("error while parsing config file: %s. Due to: %s", p.ConfigPath, err.Error()) + return + } + + p.FileInfo, err = parseConfigFile(data, p.Profile) + return p.FileInfo, err +} + +func presentOrError(value string, expectedConf, presentConf rune, confMissing string) (string, error) { + if presentConf&expectedConf == expectedConf { + return value, nil + } + return "", errors.New(confMissing + " configuration is missing from file") +} + +func (p fileConfigurationProvider) TenancyOCID() (value string, err error) { + info, err := p.readAndParseConfigFile() + if err != nil { + err = fmt.Errorf("can not read tenancy configuration due to: %s", err.Error()) + return + } + + value, err = presentOrError(info.TenancyOcid, hasTenancy, info.PresentConfiguration, "tenancy") + return +} + +func (p fileConfigurationProvider) UserOCID() (value string, err error) { + info, err := p.readAndParseConfigFile() + if err != nil { + err = fmt.Errorf("can not read tenancy configuration due to: %s", err.Error()) + return + } + + if value, err = presentOrError(info.UserOcid, hasUser, info.PresentConfiguration, "user"); err != nil { + // need to check if securityTokenPath is provided, if security token is provided, userOCID can be "". + if _, stErr := presentOrError(info.SecurityTokenFilePath, hasSecurityTokenFile, info.PresentConfiguration, + "securityTokenPath"); stErr == nil { + err = nil + } + } + return +} + +func (p fileConfigurationProvider) KeyFingerprint() (value string, err error) { + info, err := p.readAndParseConfigFile() + if err != nil { + err = fmt.Errorf("can not read tenancy configuration due to: %s", err.Error()) + return + } + value, err = presentOrError(info.Fingerprint, hasFingerprint, info.PresentConfiguration, "fingerprint") + return +} + +func (p fileConfigurationProvider) KeyID() (keyID string, err error) { + info, err := p.readAndParseConfigFile() + if err != nil { + err = fmt.Errorf("can not read tenancy configuration due to: %s", err.Error()) + return + } + if info.PresentConfiguration&hasUser == hasUser { + return fmt.Sprintf("%s/%s/%s", info.TenancyOcid, info.UserOcid, info.Fingerprint), nil + } + if filePath, err := presentOrError(info.SecurityTokenFilePath, hasSecurityTokenFile, info.PresentConfiguration, "securityTokenFilePath"); err == nil { + rawString, err := getTokenContent(filePath) + if err != nil { + return "", err + } + return "ST$" + rawString, nil + } + err = fmt.Errorf("can not read SecurityTokenFilePath from configuration file due to: %s", err.Error()) + return +} + +func (p fileConfigurationProvider) PrivateRSAKey() (key *rsa.PrivateKey, err error) { + info, err := p.readAndParseConfigFile() + if err != nil { + err = fmt.Errorf("can not read tenancy configuration due to: %s", err.Error()) + return + } + + filePath, err := presentOrError(info.KeyFilePath, hasKeyFile, info.PresentConfiguration, "key file path") + if err != nil { + return + } + + expandedPath := expandPath(filePath) + pemFileContent, err := ioutil.ReadFile(expandedPath) + if err != nil { + err = fmt.Errorf("can not read PrivateKey from configuration file due to: %s", err.Error()) + return + } + + password := p.PrivateKeyPassword + + if password == "" && ((info.PresentConfiguration & hasPassphrase) == hasPassphrase) { + password = info.Passphrase + } + + key, err = PrivateKeyFromBytes(pemFileContent, &password) + return +} + +func (p fileConfigurationProvider) Region() (value string, err error) { + info, err := p.readAndParseConfigFile() + if err != nil { + err = fmt.Errorf("can not read region configuration due to: %s", err.Error()) + return + } + + value, err = presentOrError(info.Region, hasRegion, info.PresentConfiguration, "region") + if err != nil { + val, error := getRegionFromEnvVar() + if error != nil { + err = fmt.Errorf("region configuration is missing from file, nor for OCI_REGION env var") + return + } + value = val + } + + return canStringBeRegion(value) +} + +func (p fileConfigurationProvider) AuthType() (AuthConfig, error) { + info, err := p.readAndParseConfigFile() + if err != nil { + err = fmt.Errorf("can not read tenancy configuration due to: %s", err.Error()) + return AuthConfig{UnknownAuthenticationType, true, nil}, err + } + val, err := presentOrError(info.AuthenticationType, hasAuthenticationType, info.PresentConfiguration, "authentication_type") + + if val == "instance_principal" { + if filePath, err := presentOrError(info.DelegationTokenFilePath, hasDelegationTokenFile, info.PresentConfiguration, "delegationTokenFilePath"); err == nil { + if delegationToken, err := getTokenContent(filePath); err == nil && delegationToken != "" { + Debugf("delegation token content is %s, and error is %s ", delegationToken, err) + return AuthConfig{InstancePrincipalDelegationToken, true, &delegationToken}, nil + } + return AuthConfig{UnknownAuthenticationType, true, nil}, err + + } + // normal instance principle + return AuthConfig{InstancePrincipal, true, nil}, nil + } + + // by default, if no "authentication_type" is provided, just treated as user principle type, and will not return error + return AuthConfig{UserPrincipal, true, nil}, nil +} + +func getTokenContent(filePath string) (string, error) { + expandedPath := expandPath(filePath) + tokenFileContent, err := ioutil.ReadFile(expandedPath) + if err != nil { + err = fmt.Errorf("can not read token content from configuration file due to: %s", err.Error()) + return "", err + } + return fmt.Sprintf("%s", tokenFileContent), nil +} + +// A configuration provider that look for information in multiple configuration providers +type composingConfigurationProvider struct { + Providers []ConfigurationProvider +} + +// ComposingConfigurationProvider creates a composing configuration provider with the given slice of configuration providers +// A composing provider will return the configuration of the first provider that has the required property +// if no provider has the property it will return an error. +func ComposingConfigurationProvider(providers []ConfigurationProvider) (ConfigurationProvider, error) { + if len(providers) == 0 { + return nil, fmt.Errorf("providers can not be an empty slice") + } + + for i, p := range providers { + if p == nil { + return nil, fmt.Errorf("provider in position: %d is nil. ComposingConfiurationProvider does not support nil values", i) + } + } + return composingConfigurationProvider{Providers: providers}, nil +} + +func (c composingConfigurationProvider) TenancyOCID() (string, error) { + for _, p := range c.Providers { + val, err := p.TenancyOCID() + if err == nil { + return val, nil + } + } + return "", fmt.Errorf("did not find a proper configuration for tenancy") +} + +func (c composingConfigurationProvider) UserOCID() (string, error) { + for _, p := range c.Providers { + val, err := p.UserOCID() + if err == nil { + return val, nil + } + } + return "", fmt.Errorf("did not find a proper configuration for user") +} + +func (c composingConfigurationProvider) KeyFingerprint() (string, error) { + for _, p := range c.Providers { + val, err := p.KeyFingerprint() + if err == nil { + return val, nil + } + } + return "", fmt.Errorf("did not find a proper configuration for keyFingerprint") +} +func (c composingConfigurationProvider) Region() (string, error) { + for _, p := range c.Providers { + val, err := p.Region() + if err == nil { + return val, nil + } + } + if val, err := getRegionFromEnvVar(); err == nil { + return val, nil + } + return "", fmt.Errorf("did not find a proper configuration for region, nor for OCI_REGION env var") +} + +func (c composingConfigurationProvider) KeyID() (string, error) { + for _, p := range c.Providers { + val, err := p.KeyID() + if err == nil { + return val, nil + } + } + return "", fmt.Errorf("did not find a proper configuration for key id") +} + +func (c composingConfigurationProvider) PrivateRSAKey() (*rsa.PrivateKey, error) { + for _, p := range c.Providers { + val, err := p.PrivateRSAKey() + if err == nil { + return val, nil + } + } + return nil, fmt.Errorf("did not find a proper configuration for private key") +} + +func (c composingConfigurationProvider) AuthType() (AuthConfig, error) { + // only check the first default fileConfigProvider + authConfig, err := c.Providers[0].AuthType() + if err == nil && authConfig.AuthType != UnknownAuthenticationType { + return authConfig, nil + } + return AuthConfig{UnknownAuthenticationType, false, nil}, fmt.Errorf("did not find a proper configuration for auth type") +} + +func getRegionFromEnvVar() (string, error) { + regionEnvVar := "OCI_REGION" + if region, existed := os.LookupEnv(regionEnvVar); existed { + return region, nil + } + return "", fmt.Errorf("did not find OCI_REGION env var") +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/errors.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/errors.go new file mode 100644 index 000000000..0b358b74b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/errors.go @@ -0,0 +1,136 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package common + +import ( + "encoding/json" + "fmt" + "github.com/sony/gobreaker" + "io/ioutil" + "net" + "net/http" +) + +// ServiceError models all potential errors generated the service call +type ServiceError interface { + // The http status code of the error + GetHTTPStatusCode() int + + // The human-readable error string as sent by the service + GetMessage() string + + // A short error code that defines the error, meant for programmatic parsing. + // See https://docs.cloud.oracle.com/Content/API/References/apierrors.htm + GetCode() string + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + GetOpcRequestID() string +} + +type servicefailure struct { + StatusCode int + Code string `json:"code,omitempty"` + Message string `json:"message,omitempty"` + OpcRequestID string `json:"opc-request-id"` +} + +func newServiceFailureFromResponse(response *http.Response) error { + var err error + + se := servicefailure{ + StatusCode: response.StatusCode, + Code: "BadErrorResponse", + OpcRequestID: response.Header.Get("opc-request-id")} + + //If there is an error consume the body, entirely + body, err := ioutil.ReadAll(response.Body) + if err != nil { + se.Message = fmt.Sprintf("The body of the response was not readable, due to :%s", err.Error()) + return se + } + + err = json.Unmarshal(body, &se) + if err != nil { + Debugf("Error response could not be parsed due to: %s", err.Error()) + se.Message = fmt.Sprintf("Failed to parse json from response body due to: %s. With response body %s.", err.Error(), string(body[:])) + return se + } + return se +} + +func (se servicefailure) Error() string { + return fmt.Sprintf("Service error:%s. %s. http status code: %d. Opc request id: %s", + se.Code, se.Message, se.StatusCode, se.OpcRequestID) +} + +func (se servicefailure) GetHTTPStatusCode() int { + return se.StatusCode + +} + +func (se servicefailure) GetMessage() string { + return se.Message +} + +func (se servicefailure) GetCode() string { + return se.Code +} + +func (se servicefailure) GetOpcRequestID() string { + return se.OpcRequestID +} + +// IsServiceError returns false if the error is not service side, otherwise true +// additionally it returns an interface representing the ServiceError +func IsServiceError(err error) (failure ServiceError, ok bool) { + failure, ok = err.(servicefailure) + return +} + +type deadlineExceededByBackoffError struct{} + +func (deadlineExceededByBackoffError) Error() string { + return "now() + computed backoff duration exceeds request deadline" +} + +// DeadlineExceededByBackoff is the error returned by Call() when GetNextDuration() returns a time.Duration that would +// force the user to wait past the request deadline before re-issuing a request. This enables us to exit early, since +// we cannot succeed based on the configured retry policy. +var DeadlineExceededByBackoff error = deadlineExceededByBackoffError{} + +// NonSeekableRequestRetryFailure is the error returned when the request is with binary request body, and is configured +// retry, but the request body is not retryable +type NonSeekableRequestRetryFailure struct { + err error +} + +func (ne NonSeekableRequestRetryFailure) Error() string { + if ne.err == nil { + return fmt.Sprintf("Unable to perform Retry on this request body type, which did not implement seek() interface") + } + return fmt.Sprintf("%s. Unable to perform Retry on this request body type, which did not implement seek() interface", ne.err.Error()) +} + +// IsNetworkError validates if an error is a net.Error and check if it's temporary or timeout +func IsNetworkError(err error) bool { + if r, ok := err.(net.Error); ok && (r.Temporary() || r.Timeout()) { + return true + } + return false +} + +// IsCircuitBreakerError validates if an error's text is Open state ErrOpenState or HalfOpen state ErrTooManyRequests +func IsCircuitBreakerError(err error) bool { + if err.Error() == gobreaker.ErrOpenState.Error() || err.Error() == gobreaker.ErrTooManyRequests.Error() { + return true + } + return false +} + +// StatErrCode is a type which wraps error's statusCode and errorCode from service end +type StatErrCode struct { + statusCode int + errorCode string +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/helpers.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/helpers.go new file mode 100644 index 000000000..39e3cb697 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/helpers.go @@ -0,0 +1,298 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package common + +import ( + "crypto/rand" + "crypto/rsa" + "crypto/x509" + "encoding/pem" + "fmt" + "net/textproto" + "os" + "reflect" + "strconv" + "strings" + "time" +) + +// String returns a pointer to the provided string +func String(value string) *string { + return &value +} + +// Int returns a pointer to the provided int +func Int(value int) *int { + return &value +} + +// Int64 returns a pointer to the provided int64 +func Int64(value int64) *int64 { + return &value +} + +// Uint returns a pointer to the provided uint +func Uint(value uint) *uint { + return &value +} + +//Float32 returns a pointer to the provided float32 +func Float32(value float32) *float32 { + return &value +} + +//Float64 returns a pointer to the provided float64 +func Float64(value float64) *float64 { + return &value +} + +//Bool returns a pointer to the provided bool +func Bool(value bool) *bool { + return &value +} + +//PointerString prints the values of pointers in a struct +//Producing a human friendly string for an struct with pointers. +//useful when debugging the values of a struct +func PointerString(datastruct interface{}) (representation string) { + val := reflect.ValueOf(datastruct) + typ := reflect.TypeOf(datastruct) + all := make([]string, 2) + all = append(all, "{") + for i := 0; i < typ.NumField(); i++ { + sf := typ.Field(i) + + //unexported + if sf.PkgPath != "" && !sf.Anonymous { + continue + } + + sv := val.Field(i) + stringValue := "" + if isNil(sv) { + stringValue = fmt.Sprintf("%s=", sf.Name) + } else { + if sv.Type().Kind() == reflect.Ptr { + sv = sv.Elem() + } + stringValue = fmt.Sprintf("%s=%v", sf.Name, sv) + } + all = append(all, stringValue) + } + all = append(all, "}") + representation = strings.TrimSpace(strings.Join(all, " ")) + return +} + +// SDKTime a struct that parses/renders to/from json using RFC339 date-time information +type SDKTime struct { + time.Time +} + +// SDKDate a struct that parses/renders to/from json using only date information +type SDKDate struct { + //Date date information + Date time.Time +} + +func sdkTimeFromTime(t time.Time) SDKTime { + return SDKTime{t} +} + +func sdkDateFromTime(t time.Time) SDKDate { + return SDKDate{Date: t} +} + +func formatTime(t SDKTime) string { + return t.Format(sdkTimeFormat) +} + +func formatDate(t SDKDate) string { + return t.Date.Format(sdkDateFormat) +} + +func now() *SDKTime { + t := SDKTime{time.Now()} + return &t +} + +var timeType = reflect.TypeOf(SDKTime{}) +var timeTypePtr = reflect.TypeOf(&SDKTime{}) + +var sdkDateType = reflect.TypeOf(SDKDate{}) +var sdkDateTypePtr = reflect.TypeOf(&SDKDate{}) + +//Formats for sdk supported time representations +const sdkTimeFormat = time.RFC3339Nano +const rfc1123OptionalLeadingDigitsInDay = "Mon, _2 Jan 2006 15:04:05 MST" +const sdkDateFormat = "2006-01-02" + +func tryParsingTimeWithValidFormatsForHeaders(data []byte, headerName string) (t time.Time, err error) { + header := strings.ToLower(headerName) + switch header { + case "lastmodified", "date": + t, err = tryParsing(data, time.RFC3339Nano, time.RFC3339, time.RFC1123, rfc1123OptionalLeadingDigitsInDay, time.RFC850, time.ANSIC) + return + default: //By default we parse with RFC3339 + t, err = time.Parse(sdkTimeFormat, string(data)) + return + } +} + +func tryParsing(data []byte, layouts ...string) (tm time.Time, err error) { + datestring := string(data) + for _, l := range layouts { + tm, err = time.Parse(l, datestring) + if err == nil { + return + } + } + err = fmt.Errorf("Could not parse time: %s with formats: %s", datestring, layouts[:]) + return +} + +// String returns string representation of SDKDate +func (t *SDKDate) String() string { + return t.Date.Format(sdkDateFormat) +} + +// NewSDKDateFromString parses the dateString into SDKDate +func NewSDKDateFromString(dateString string) (*SDKDate, error) { + parsedTime, err := time.Parse(sdkDateFormat, dateString) + if err != nil { + return nil, err + } + + return &SDKDate{Date: parsedTime}, nil +} + +// UnmarshalJSON unmarshals from json +func (t *SDKTime) UnmarshalJSON(data []byte) (e error) { + s := string(data) + if s == "null" { + t.Time = time.Time{} + } else { + //Try parsing with RFC3339 + t.Time, e = time.Parse(`"`+sdkTimeFormat+`"`, string(data)) + } + return +} + +// MarshalJSON marshals to JSON +func (t *SDKTime) MarshalJSON() (buff []byte, e error) { + s := t.Format(sdkTimeFormat) + buff = []byte(`"` + s + `"`) + return +} + +// UnmarshalJSON unmarshals from json +func (t *SDKDate) UnmarshalJSON(data []byte) (e error) { + if string(data) == `"null"` { + t.Date = time.Time{} + return + } + + t.Date, e = tryParsing(data, + strconv.Quote(sdkDateFormat), + ) + return +} + +// MarshalJSON marshals to JSON +func (t *SDKDate) MarshalJSON() (buff []byte, e error) { + s := t.Date.Format(sdkDateFormat) + buff = []byte(strconv.Quote(s)) + return +} + +// PrivateKeyFromBytes is a helper function that will produce a RSA private +// key from bytes. This function is deprecated in favour of PrivateKeyFromBytesWithPassword +// Deprecated +func PrivateKeyFromBytes(pemData []byte, password *string) (key *rsa.PrivateKey, e error) { + if password == nil { + return PrivateKeyFromBytesWithPassword(pemData, nil) + } + + return PrivateKeyFromBytesWithPassword(pemData, []byte(*password)) +} + +// PrivateKeyFromBytesWithPassword is a helper function that will produce a RSA private +// key from bytes and a password. +func PrivateKeyFromBytesWithPassword(pemData, password []byte) (key *rsa.PrivateKey, e error) { + if pemBlock, _ := pem.Decode(pemData); pemBlock != nil { + decrypted := pemBlock.Bytes + if x509.IsEncryptedPEMBlock(pemBlock) { + if password == nil { + e = fmt.Errorf("private key password is required for encrypted private keys") + return + } + if decrypted, e = x509.DecryptPEMBlock(pemBlock, password); e != nil { + return + } + } + + key, e = parsePKCSPrivateKey(decrypted) + + } else { + e = fmt.Errorf("PEM data was not found in buffer") + return + } + return +} + +// ParsePrivateKey using PKCS1 or PKCS8 +func parsePKCSPrivateKey(decryptedKey []byte) (*rsa.PrivateKey, error) { + if key, err := x509.ParsePKCS1PrivateKey(decryptedKey); err == nil { + return key, nil + } + if key, err := x509.ParsePKCS8PrivateKey(decryptedKey); err == nil { + switch key := key.(type) { + case *rsa.PrivateKey: + return key, nil + default: + return nil, fmt.Errorf("unsupportesd private key type in PKCS8 wrapping") + } + } + return nil, fmt.Errorf("failed to parse private key") +} + +// parseContentLength trims whitespace from cl and returns -1 if can't purse uint, or the value if it's no less than 0 +func parseContentLength(cl string) int64 { + cl = textproto.TrimString(cl) + n, err := strconv.ParseUint(cl, 10, 63) + if err != nil { + return -1 + } + return int64(n) +} + +func generateRandUUID() (string, error) { + b := make([]byte, 16) + _, err := rand.Read(b) + if err != nil { + return "", err + } + uuid := fmt.Sprintf("%x%x%x%x%x", b[0:4], b[4:6], b[6:8], b[8:10], b[10:]) + + return uuid, nil +} + +func makeACopy(original []string) []string { + tmp := make([]string, len(original)) + copy(tmp, original) + return tmp +} + +// IsEnvVarFalse is used for checking if an environment variable is explicitly set to false, otherwise would set it true by default +func IsEnvVarFalse(envVarKey string) bool { + return false + val, existed := os.LookupEnv(envVarKey) + return existed && strings.ToLower(val) == "false" +} + +// IsEnvVarTrue is used for checking if an environment variable is explicitly set to true, otherwise would set it true by default +func IsEnvVarTrue(envVarKey string) bool { + val, existed := os.LookupEnv(envVarKey) + return existed && strings.ToLower(val) == "true" +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/http.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/http.go new file mode 100644 index 000000000..a88e46fed --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/http.go @@ -0,0 +1,1070 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package common + +import ( + "bytes" + "encoding/json" + "fmt" + "io" + "io/ioutil" + "net/http" + "net/url" + "os" + "reflect" + "regexp" + "strconv" + "strings" + "time" +) + +const ( + //UsingExpectHeaderEnvVar is the key to determine whether expect 100-continue is enabled or not + UsingExpectHeaderEnvVar = "OCI_GOSDK_USING_EXPECT_HEADER" +) + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//Request Marshaling +//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +func isNil(v reflect.Value) bool { + return v.Kind() == reflect.Ptr && v.IsNil() +} + +// Returns the string representation of a reflect.Value +// Only transforms primitive values +func toStringValue(v reflect.Value, field reflect.StructField) (string, error) { + if v.Kind() == reflect.Ptr { + if v.IsNil() { + return "", fmt.Errorf("can not marshal a nil pointer") + } + v = v.Elem() + } + + if v.Type() == timeType { + t := v.Interface().(SDKTime) + return formatTime(t), nil + } + + if v.Type() == sdkDateType { + t := v.Interface().(SDKDate) + return formatDate(t), nil + } + + switch v.Kind() { + case reflect.Bool: + return strconv.FormatBool(v.Bool()), nil + case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: + return strconv.FormatInt(v.Int(), 10), nil + case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64, reflect.Uintptr: + return strconv.FormatUint(v.Uint(), 10), nil + case reflect.String: + return v.String(), nil + case reflect.Float32: + return strconv.FormatFloat(v.Float(), 'f', -1, 32), nil + case reflect.Float64: + return strconv.FormatFloat(v.Float(), 'f', -1, 64), nil + default: + return "", fmt.Errorf("marshaling structure to a http.Request does not support field named: %s of type: %v", + field.Name, v.Type().String()) + } +} + +func addBinaryBody(request *http.Request, value reflect.Value, field reflect.StructField) (e error) { + readCloser, ok := value.Interface().(io.ReadCloser) + isMandatory, err := strconv.ParseBool(field.Tag.Get("mandatory")) + if err != nil { + return fmt.Errorf("mandatory tag is not valid for field %s", field.Name) + } + + if isMandatory && !ok { + e = fmt.Errorf("body of the request is mandatory and needs to be an io.ReadCloser interface. Can not marshal body of binary request") + return + } + + request.Body = readCloser + + //Set the default content type to application/octet-stream if not set + if request.Header.Get(requestHeaderContentType) == "" { + request.Header.Set(requestHeaderContentType, "application/octet-stream") + } + return nil +} + +// getTaggedNilFieldNameOrError, evaluates if a field with json and non mandatory tags is nil +// returns the json tag name, or an error if the tags are incorrectly present +func getTaggedNilFieldNameOrError(field reflect.StructField, fieldValue reflect.Value) (bool, string, error) { + currentTag := field.Tag + jsonTag := currentTag.Get("json") + + if jsonTag == "" { + return false, "", fmt.Errorf("json tag is not valid for field %s", field.Name) + } + + partsJSONTag := strings.Split(jsonTag, ",") + nameJSONField := partsJSONTag[0] + + if _, ok := currentTag.Lookup("mandatory"); !ok { + //No mandatory field set, no-op + return false, nameJSONField, nil + } + isMandatory, err := strconv.ParseBool(currentTag.Get("mandatory")) + if err != nil { + return false, "", fmt.Errorf("mandatory tag is not valid for field %s", field.Name) + } + + // If the field is marked as mandatory, no-op + if isMandatory { + return false, nameJSONField, nil + } + + Debugf("Adjusting tag: mandatory is false and json tag is valid on field: %s", field.Name) + + // If the field can not be nil, then no-op + if !isNillableType(&fieldValue) { + Debugf("WARNING json field is tagged with mandatory flags, but the type can not be nil, field name: %s", field.Name) + return false, nameJSONField, nil + } + + // If field value is nil, tag it as omitEmpty + return fieldValue.IsNil(), nameJSONField, nil + +} + +// isNillableType returns true if the filed can be nil +func isNillableType(value *reflect.Value) bool { + k := value.Kind() + switch k { + case reflect.Chan, reflect.Func, reflect.Map, reflect.Ptr, reflect.Interface, reflect.Slice: + return true + } + return false +} + +// omitNilFieldsInJSON, removes json keys whose struct value is nil, and the field is tagged with the json and +// mandatory:false tags +func omitNilFieldsInJSON(data interface{}, value reflect.Value) (interface{}, error) { + switch value.Kind() { + case reflect.Struct: + jsonMap := data.(map[string]interface{}) + fieldType := value.Type() + for i := 0; i < fieldType.NumField(); i++ { + currentField := fieldType.Field(i) + //unexported skip + if currentField.PkgPath != "" { + continue + } + + //Does not have json tag, no-op + if _, ok := currentField.Tag.Lookup("json"); !ok { + continue + } + + currentFieldValue := value.Field(i) + ok, jsonFieldName, err := getTaggedNilFieldNameOrError(currentField, currentFieldValue) + if err != nil { + return nil, fmt.Errorf("can not omit nil fields for field: %s, due to: %s", + currentField.Name, err.Error()) + } + + //Delete the struct field from the json representation + if ok { + delete(jsonMap, jsonFieldName) + continue + } + + // Check to make sure the field is part of the json representation of the value + if _, contains := jsonMap[jsonFieldName]; !contains { + Debugf("Field %s is not present in json, omitting", jsonFieldName) + continue + } + + if currentFieldValue.Type() == timeType || currentFieldValue.Type() == timeTypePtr || + currentField.Type == sdkDateType || currentField.Type == sdkDateTypePtr { + continue + } + // does it need to be adjusted? + var adjustedValue interface{} + adjustedValue, err = omitNilFieldsInJSON(jsonMap[jsonFieldName], currentFieldValue) + if err != nil { + return nil, fmt.Errorf("can not omit nil fields for field: %s, due to: %s", + currentField.Name, err.Error()) + } + jsonMap[jsonFieldName] = adjustedValue + } + return jsonMap, nil + case reflect.Slice, reflect.Array: + // Special case: a []byte may have been marshalled as a string + if data != nil && reflect.TypeOf(data).Kind() == reflect.String && value.Type().Elem().Kind() == reflect.Uint8 { + return data, nil + } + jsonList, ok := data.([]interface{}) + if !ok { + return nil, fmt.Errorf("can not omit nil fields, data was expected to be a not-nil list") + } + newList := make([]interface{}, len(jsonList)) + var err error + for i, val := range jsonList { + newList[i], err = omitNilFieldsInJSON(val, value.Index(i)) + if err != nil { + return nil, err + } + } + return newList, nil + case reflect.Map: + jsonMap, ok := data.(map[string]interface{}) + if !ok { + return nil, fmt.Errorf("can not omit nil fields, data was expected to be a not-nil map") + } + newMap := make(map[string]interface{}, len(jsonMap)) + var err error + for key, val := range jsonMap { + newMap[key], err = omitNilFieldsInJSON(val, value.MapIndex(reflect.ValueOf(key))) + if err != nil { + return nil, err + } + } + return newMap, nil + case reflect.Ptr, reflect.Interface: + valPtr := value.Elem() + return omitNilFieldsInJSON(data, valPtr) + default: + //Otherwise no-op + return data, nil + } +} + +// removeNilFieldsInJSONWithTaggedStruct remove struct fields tagged with json and mandatory false +// that are nil +func removeNilFieldsInJSONWithTaggedStruct(rawJSON []byte, value reflect.Value) ([]byte, error) { + var rawInterface interface{} + decoder := json.NewDecoder(bytes.NewBuffer(rawJSON)) + decoder.UseNumber() + var err error + if err = decoder.Decode(&rawInterface); err != nil { + return nil, err + } + + fixedMap, err := omitNilFieldsInJSON(rawInterface, value) + if err != nil { + return nil, err + } + return json.Marshal(fixedMap) +} + +func addToBody(request *http.Request, value reflect.Value, field reflect.StructField, binaryBodySpecified *bool) (e error) { + Debugln("Marshaling to body from field:", field.Name) + if request.Body != nil { + Logf("The body of the request is already set. Structure: %s will overwrite it\n", field.Name) + } + tag := field.Tag + encoding := tag.Get("encoding") + + if encoding == "binary" { + *binaryBodySpecified = true + return addBinaryBody(request, value, field) + } + + rawJSON, e := json.Marshal(value.Interface()) + if e != nil { + return + } + marshaled, e := removeNilFieldsInJSONWithTaggedStruct(rawJSON, value) + if e != nil { + return + } + + if defaultLogger.LogLevel() == verboseLogging { + Debugf("Marshaled body is: %s\n", string(marshaled)) + } + + bodyBytes := bytes.NewReader(marshaled) + request.ContentLength = int64(bodyBytes.Len()) + request.Header.Set(requestHeaderContentLength, strconv.FormatInt(request.ContentLength, 10)) + request.Header.Set(requestHeaderContentType, "application/json") + request.Body = ioutil.NopCloser(bodyBytes) + snapshot := *bodyBytes + request.GetBody = func() (io.ReadCloser, error) { + r := snapshot + return ioutil.NopCloser(&r), nil + } + + return +} + +func checkBinaryBodyLength(request *http.Request) (contentLen int64, err error) { + if reflect.TypeOf(request.Body) == reflect.TypeOf(ioutil.NopCloser(nil)) { + ioReader := reflect.ValueOf(request.Body).Field(0).Interface().(io.Reader) + switch t := ioReader.(type) { + case *bytes.Reader: + return int64(t.Len()), nil + case *bytes.Buffer: + return int64(t.Len()), nil + case *strings.Reader: + return int64(t.Len()), nil + default: + return getNormalBinaryBodyLength(request) + } + } + if reflect.TypeOf(request.Body) == reflect.TypeOf((*os.File)(nil)) { + fi, err := (request.Body.(*os.File)).Stat() + if err != nil { + return contentLen, err + } + return fi.Size(), nil + } + return getNormalBinaryBodyLength(request) +} + +func getNormalBinaryBodyLength(request *http.Request) (contentLen int64, err error) { + dumpRequestBody := ioutil.NopCloser(bytes.NewBuffer(nil)) + if dumpRequestBody, request.Body, err = drainBody(request.Body); err != nil { + dumpRequestBody = ioutil.NopCloser(bytes.NewBuffer(nil)) + return contentLen, err + } + contentBody, err := ioutil.ReadAll(dumpRequestBody) + if err != nil { + return contentLen, err + } + return int64(len(contentBody)), nil +} + +func addToQuery(request *http.Request, value reflect.Value, field reflect.StructField) (e error) { + Debugln("Marshaling to query from field: ", field.Name) + if request.URL == nil { + request.URL = &url.URL{} + } + query := request.URL.Query() + var queryParameterValue, queryParameterName string + + if queryParameterName = field.Tag.Get("name"); queryParameterName == "" { + return fmt.Errorf("marshaling request to a query requires the 'name' tag for field: %s ", field.Name) + } + + mandatory, _ := strconv.ParseBool(strings.ToLower(field.Tag.Get("mandatory"))) + + //If mandatory and nil. Error out + if mandatory && isNil(value) { + return fmt.Errorf("marshaling request to a header requires not nil pointer for field: %s", field.Name) + } + + //if not mandatory and nil. Omit + if !mandatory && isNil(value) { + Debugf("Query parameter value is not mandatory and is nil pointer in field: %s. Skipping query", field.Name) + return + } + + encoding := strings.ToLower(field.Tag.Get("collectionFormat")) + var collectionFormatStringValues []string + switch encoding { + case "csv", "multi": + if value.Kind() != reflect.Slice && value.Kind() != reflect.Array { + e = fmt.Errorf("query parameter is tagged as csv or multi yet its type is neither an Array nor a Slice: %s", field.Name) + break + } + + numOfElements := value.Len() + collectionFormatStringValues = make([]string, numOfElements) + for i := 0; i < numOfElements; i++ { + collectionFormatStringValues[i], e = toStringValue(value.Index(i), field) + if e != nil { + break + } + } + queryParameterValue = strings.Join(collectionFormatStringValues, ",") + case "": + queryParameterValue, e = toStringValue(value, field) + default: + e = fmt.Errorf("encoding of type %s is not supported for query param: %s", encoding, field.Name) + } + + if e != nil { + return + } + + //check for tag "omitEmpty", this is done to accomodate unset fields that do not + //support an empty string: enums in query params + if omitEmpty, present := field.Tag.Lookup("omitEmpty"); present { + omitEmptyBool, _ := strconv.ParseBool(strings.ToLower(omitEmpty)) + if queryParameterValue != "" || !omitEmptyBool { + addToQueryForEncoding(&query, encoding, queryParameterName, queryParameterValue, collectionFormatStringValues) + } else { + Debugf("Omitting %s, is empty and omitEmpty tag is set", field.Name) + } + } else { + addToQueryForEncoding(&query, encoding, queryParameterName, queryParameterValue, collectionFormatStringValues) + } + + request.URL.RawQuery = query.Encode() + return +} + +func addToQueryForEncoding(query *url.Values, encoding string, queryParameterName string, queryParameterValue string, collectionFormatStringValues []string) { + if encoding == "multi" { + for _, stringValue := range collectionFormatStringValues { + query.Add(queryParameterName, stringValue) + } + } else { + query.Set(queryParameterName, queryParameterValue) + } +} + +// Adds to the path of the url in the order they appear in the structure +func addToPath(request *http.Request, value reflect.Value, field reflect.StructField) (e error) { + var additionalURLPathPart string + if additionalURLPathPart, e = toStringValue(value, field); e != nil { + return fmt.Errorf("can not marshal to path in request for field %s. Due to %s", field.Name, e.Error()) + } + + // path should not be empty for any operations + if len(additionalURLPathPart) == 0 { + return fmt.Errorf("value cannot be empty for field %s in path", field.Name) + } + + if request.URL == nil { + request.URL = &url.URL{} + request.URL.Path = "" + } + var currentURLPath = request.URL.Path + + var templatedPathRegex, _ = regexp.Compile(".*{.+}.*") + if !templatedPathRegex.MatchString(currentURLPath) { + Debugln("Marshaling request to path by appending field:", field.Name) + allPath := []string{currentURLPath, additionalURLPathPart} + request.URL.Path = strings.Join(allPath, "/") + } else { + var fieldName string + if fieldName = field.Tag.Get("name"); fieldName == "" { + e = fmt.Errorf("marshaling request to path name and template requires a 'name' tag for field: %s", field.Name) + return + } + urlTemplate := currentURLPath + Debugln("Marshaling to path from field: ", field.Name, " in template: ", urlTemplate) + request.URL.Path = strings.Replace(urlTemplate, "{"+fieldName+"}", additionalURLPathPart, -1) + } + return +} + +func setWellKnownHeaders(request *http.Request, headerName, headerValue string, contentLenSpecified *bool) (e error) { + switch strings.ToLower(headerName) { + case "content-length": + var len int + len, e = strconv.Atoi(headerValue) + if e != nil { + return + } + request.ContentLength = int64(len) + *contentLenSpecified = true + } + return nil +} + +func addToHeader(request *http.Request, value reflect.Value, field reflect.StructField, contentLenSpecified *bool) (e error) { + Debugln("Marshaling to header from field: ", field.Name) + if request.Header == nil { + request.Header = http.Header{} + } + + var headerName, headerValue string + if headerName = field.Tag.Get("name"); headerName == "" { + return fmt.Errorf("marshaling request to a header requires the 'name' tag for field: %s", field.Name) + } + + mandatory, _ := strconv.ParseBool(strings.ToLower(field.Tag.Get("mandatory"))) + //If mandatory and nil. Error out + if mandatory && isNil(value) { + return fmt.Errorf("marshaling request to a header requires not nil pointer for field: %s", field.Name) + } + + // generate opc-request-id if header value is nil and header name matches + value = generateOpcRequestID(headerName, value) + + //if not mandatory and nil. Omit + if !mandatory && isNil(value) { + Debugf("Header value is not mandatory and is nil pointer in field: %s. Skipping header", field.Name) + return + } + + //Otherwise get value and set header + if headerValue, e = toStringValue(value, field); e != nil { + return + } + + if e = setWellKnownHeaders(request, headerName, headerValue, contentLenSpecified); e != nil { + return + } + + if isUniqueHeaderRequired(headerName) { + request.Header.Set(headerName, headerValue) + } else { + request.Header.Add(headerName, headerValue) + } + return +} + +// Check if the header is required to be unique +func isUniqueHeaderRequired(headerName string) bool { + return strings.EqualFold(headerName, requestHeaderContentType) || strings.EqualFold(headerName, requestHeaderContentLength) +} + +// Header collection is a map of string to string that gets rendered as individual headers with a given prefix +func addToHeaderCollection(request *http.Request, value reflect.Value, field reflect.StructField) (e error) { + Debugln("Marshaling to header-collection from field:", field.Name) + if request.Header == nil { + request.Header = http.Header{} + } + + var headerPrefix string + if headerPrefix = field.Tag.Get("prefix"); headerPrefix == "" { + return fmt.Errorf("marshaling request to a header requires the 'prefix' tag for field: %s", field.Name) + } + + mandatory, _ := strconv.ParseBool(strings.ToLower(field.Tag.Get("mandatory"))) + //If mandatory and nil. Error out + if mandatory && isNil(value) { + return fmt.Errorf("marshaling request to a header requires not nil pointer for field: %s", field.Name) + } + + //if not mandatory and nil. Omit + if !mandatory && isNil(value) { + Debugf("Header value is not mandatory and is nil pointer in field: %s. Skipping header", field.Name) + return + } + + //cast to map + headerValues, ok := value.Interface().(map[string]string) + if !ok { + e = fmt.Errorf("header fields need to be of type map[string]string") + return + } + + for k, v := range headerValues { + headerName := fmt.Sprintf("%s%s", headerPrefix, k) + request.Header.Set(headerName, v) + } + return +} + +// Makes sure the incoming structure is able to be marshalled +// to a request +func checkForValidRequestStruct(s interface{}) (*reflect.Value, error) { + val := reflect.ValueOf(s) + for val.Kind() == reflect.Ptr { + if val.IsNil() { + return nil, fmt.Errorf("can not marshal to request a pointer to structure") + } + val = val.Elem() + } + + if s == nil { + return nil, fmt.Errorf("can not marshal to request a nil structure") + } + + if val.Kind() != reflect.Struct { + return nil, fmt.Errorf("can not marshal to request, expects struct input. Got %v", val.Kind()) + } + + return &val, nil +} + +// Populates the parts of a request by reading tags in the passed structure +// nested structs are followed recursively depth-first. +func structToRequestPart(request *http.Request, val reflect.Value) (err error) { + typ := val.Type() + contentLenSpecified := false + binaryBodySpecified := false + for i := 0; i < typ.NumField(); i++ { + if err != nil { + return + } + + sf := typ.Field(i) + //unexported + if sf.PkgPath != "" && !sf.Anonymous { + continue + } + + sv := val.Field(i) + tag := sf.Tag.Get("contributesTo") + switch tag { + case "header": + err = addToHeader(request, sv, sf, &contentLenSpecified) + case "header-collection": + err = addToHeaderCollection(request, sv, sf) + case "path": + err = addToPath(request, sv, sf) + case "query": + err = addToQuery(request, sv, sf) + case "body": + err = addToBody(request, sv, sf, &binaryBodySpecified) + case "": + Debugln(sf.Name, " does not contain contributes tag. Skipping.") + default: + err = fmt.Errorf("can not marshal field: %s. It needs to contain valid contributesTo tag", sf.Name) + } + } + + // if content-length is not specified but with binary body, calculate the content length according to request body + if !contentLenSpecified && binaryBodySpecified && request.Body != nil && request.Body != http.NoBody { + contentLen, err := checkBinaryBodyLength(request) + if err == nil { + request.Header.Set(requestHeaderContentLength, strconv.FormatInt(contentLen, 10)) + request.ContentLength = contentLen + } + } + + //If content length is zero, to avoid sending transfer-coding: chunked header, need to explicitly set the body to nil/Nobody. + if request.Header != nil && request.Body != nil && request.Body != http.NoBody && + parseContentLength(request.Header.Get(requestHeaderContentLength)) == 0 { + request.Body = http.NoBody + } + //If headers are and the content type was not set, we default to application/json + if request.Header != nil && request.Header.Get(requestHeaderContentType) == "" { + request.Header.Set(requestHeaderContentType, "application/json") + } + + return +} + +// HTTPRequestMarshaller marshals a structure to an http request using tag values in the struct +// The marshaller tag should like the following +// type A struct { +// ANumber string `contributesTo="query" name="number"` +// TheBody `contributesTo="body"` +// } +// where the contributesTo tag can be: header, path, query, body +// and the 'name' tag is the name of the value used in the http request(not applicable for path) +// If path is specified as part of the tag, the values are appened to the url path +// in the order they appear in the structure +// The current implementation only supports primitive types, except for the body tag, which needs a struct type. +// The body of a request will be marshaled using the tags of the structure +func HTTPRequestMarshaller(requestStruct interface{}, httpRequest *http.Request) (err error) { + var val *reflect.Value + if val, err = checkForValidRequestStruct(requestStruct); err != nil { + return + } + + Debugln("Marshaling to Request: ", val.Type().Name()) + err = structToRequestPart(httpRequest, *val) + return +} + +// MakeDefaultHTTPRequest creates the basic http request with the necessary headers set +func MakeDefaultHTTPRequest(method, path string) (httpRequest http.Request) { + httpRequest = http.Request{ + Proto: "HTTP/1.1", + ProtoMajor: 1, + ProtoMinor: 1, + Header: make(http.Header), + URL: &url.URL{}, + } + + httpRequest.Header.Set(requestHeaderContentLength, "0") + httpRequest.Header.Set(requestHeaderDate, time.Now().UTC().Format(http.TimeFormat)) + httpRequest.Header.Set(requestHeaderOpcClientInfo, strings.Join([]string{defaultSDKMarker, Version()}, "/")) + httpRequest.Header.Set(requestHeaderAccept, "*/*") + httpRequest.Method = method + httpRequest.URL.Path = path + return +} + +// MakeDefaultHTTPRequestWithTaggedStruct creates an http request from an struct with tagged fields, see HTTPRequestMarshaller +// for more information +func MakeDefaultHTTPRequestWithTaggedStruct(method, path string, requestStruct interface{}) (httpRequest http.Request, err error) { + httpRequest = MakeDefaultHTTPRequest(method, path) + err = HTTPRequestMarshaller(requestStruct, &httpRequest) + if err != nil { + return + } + + return +} + +// MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders creates an http request from an struct with tagged fields, see HTTPRequestMarshaller +// for more information +func MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path string, requestStruct interface{}, extraHeaders map[string]string) (httpRequest http.Request, err error) { + httpRequest, err = MakeDefaultHTTPRequestWithTaggedStruct(method, path, requestStruct) + for key, val := range extraHeaders { + httpRequest.Header.Set(key, val) + } + return +} + +// UpdateRequestBinaryBody updates the http request's body once it is binary request and the request body is seekable +// if the content length is zero, no need to update request body(since it's already been set to http.Nody) +func UpdateRequestBinaryBody(httpRequest *http.Request, rsc *OCIReadSeekCloser) { + if parseContentLength(httpRequest.Header.Get(requestHeaderContentLength)) == 0 { + return + } + httpRequest.Body = rsc + return +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//Request UnMarshaling +//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +// Makes sure the incoming structure is able to be unmarshaled +// to a request +func checkForValidResponseStruct(s interface{}) (*reflect.Value, error) { + val := reflect.ValueOf(s) + for val.Kind() == reflect.Ptr { + if val.IsNil() { + return nil, fmt.Errorf("can not unmarshal to response a pointer to nil structure") + } + val = val.Elem() + } + + if s == nil { + return nil, fmt.Errorf("can not unmarshal to response a nil structure") + } + + if val.Kind() != reflect.Struct { + return nil, fmt.Errorf("can not unmarshal to response, expects struct input. Got %v", val.Kind()) + } + + return &val, nil +} + +func intSizeFromKind(kind reflect.Kind) int { + switch kind { + case reflect.Int8, reflect.Uint8: + return 8 + case reflect.Int16, reflect.Uint16: + return 16 + case reflect.Int32, reflect.Uint32: + return 32 + case reflect.Int64, reflect.Uint64: + return 64 + case reflect.Int, reflect.Uint: + return strconv.IntSize + default: + Debugf("The type is not valid: %v. Returing int size for arch\n", kind.String()) + return strconv.IntSize + } + +} + +func analyzeValue(stringValue string, kind reflect.Kind, field reflect.StructField) (val reflect.Value, valPointer reflect.Value, err error) { + switch kind { + case timeType.Kind(): + var t time.Time + t, err = tryParsingTimeWithValidFormatsForHeaders([]byte(stringValue), field.Name) + if err != nil { + return + } + sdkTime := sdkTimeFromTime(t) + val = reflect.ValueOf(sdkTime) + valPointer = reflect.ValueOf(&sdkTime) + return + case sdkDateType.Kind(): + var t time.Time + t, err = tryParsingTimeWithValidFormatsForHeaders([]byte(stringValue), field.Name) + if err != nil { + return + } + sdkDate := sdkDateFromTime(t) + val = reflect.ValueOf(sdkDate) + valPointer = reflect.ValueOf(&sdkDate) + return + case reflect.Bool: + var bVal bool + if bVal, err = strconv.ParseBool(stringValue); err != nil { + return + } + val = reflect.ValueOf(bVal) + valPointer = reflect.ValueOf(&bVal) + return + case reflect.Int: + size := intSizeFromKind(kind) + var iVal int64 + if iVal, err = strconv.ParseInt(stringValue, 10, size); err != nil { + return + } + var iiVal int + iiVal = int(iVal) + val = reflect.ValueOf(iiVal) + valPointer = reflect.ValueOf(&iiVal) + return + case reflect.Int64: + size := intSizeFromKind(kind) + var iVal int64 + if iVal, err = strconv.ParseInt(stringValue, 10, size); err != nil { + return + } + val = reflect.ValueOf(iVal) + valPointer = reflect.ValueOf(&iVal) + return + case reflect.Uint: + size := intSizeFromKind(kind) + var iVal uint64 + if iVal, err = strconv.ParseUint(stringValue, 10, size); err != nil { + return + } + var uiVal uint + uiVal = uint(iVal) + val = reflect.ValueOf(uiVal) + valPointer = reflect.ValueOf(&uiVal) + return + case reflect.String: + val = reflect.ValueOf(stringValue) + valPointer = reflect.ValueOf(&stringValue) + case reflect.Float32: + var fVal float64 + if fVal, err = strconv.ParseFloat(stringValue, 32); err != nil { + return + } + var ffVal float32 + ffVal = float32(fVal) + val = reflect.ValueOf(ffVal) + valPointer = reflect.ValueOf(&ffVal) + return + case reflect.Float64: + var fVal float64 + if fVal, err = strconv.ParseFloat(stringValue, 64); err != nil { + return + } + val = reflect.ValueOf(fVal) + valPointer = reflect.ValueOf(&fVal) + return + default: + err = fmt.Errorf("value for kind: %s not supported", kind) + } + return +} + +// Sets the field of a struct, with the appropriate value of the string +// Only sets basic types +func fromStringValue(newValue string, val *reflect.Value, field reflect.StructField) (err error) { + + if !val.CanSet() { + err = fmt.Errorf("can not set field name: %s of type: %v", field.Name, val.Type().String()) + return + } + + kind := val.Kind() + isPointer := false + if val.Kind() == reflect.Ptr { + isPointer = true + kind = field.Type.Elem().Kind() + } + + value, valPtr, err := analyzeValue(newValue, kind, field) + valueType := val.Type() + if err != nil { + return + } + if !isPointer { + val.Set(value.Convert(valueType)) + } else { + val.Set(valPtr) + } + return +} + +// PolymorphicJSONUnmarshaler is the interface to unmarshal polymorphic json payloads +type PolymorphicJSONUnmarshaler interface { + UnmarshalPolymorphicJSON(data []byte) (interface{}, error) +} + +func valueFromPolymorphicJSON(content []byte, unmarshaler PolymorphicJSONUnmarshaler) (val interface{}, err error) { + err = json.Unmarshal(content, unmarshaler) + if err != nil { + return + } + val, err = unmarshaler.UnmarshalPolymorphicJSON(content) + return +} + +func valueFromJSONBody(response *http.Response, value *reflect.Value, unmarshaler PolymorphicJSONUnmarshaler) (val interface{}, err error) { + //Consumes the body, consider implementing it + //without body consumption + var content []byte + content, err = ioutil.ReadAll(response.Body) + if err != nil { + return + } + + if unmarshaler != nil { + val, err = valueFromPolymorphicJSON(content, unmarshaler) + return + } + + val = reflect.New(value.Type()).Interface() + err = json.Unmarshal(content, &val) + return +} + +func addFromBody(response *http.Response, value *reflect.Value, field reflect.StructField, unmarshaler PolymorphicJSONUnmarshaler) (err error) { + Debugln("Unmarshalling from body to field: ", field.Name) + if response.Body == nil { + Debugln("Unmarshalling body skipped due to nil body content for field: ", field.Name) + return nil + } + + tag := field.Tag + encoding := tag.Get("encoding") + var iVal interface{} + switch encoding { + case "binary": + value.Set(reflect.ValueOf(response.Body)) + return + case "plain-text": + //Expects UTF-8 + byteArr, e := ioutil.ReadAll(response.Body) + if e != nil { + return e + } + str := string(byteArr) + value.Set(reflect.ValueOf(&str)) + return + default: //If the encoding is not set. we'll decode with json + iVal, err = valueFromJSONBody(response, value, unmarshaler) + if err != nil { + return + } + + newVal := reflect.ValueOf(iVal) + if newVal.Kind() == reflect.Ptr { + newVal = newVal.Elem() + } + value.Set(newVal) + return + } +} + +func addFromHeader(response *http.Response, value *reflect.Value, field reflect.StructField) (err error) { + Debugln("Unmarshaling from header to field: ", field.Name) + var headerName string + if headerName = field.Tag.Get("name"); headerName == "" { + return fmt.Errorf("unmarshaling response to a header requires the 'name' tag for field: %s", field.Name) + } + + headerValue := response.Header.Get(headerName) + if headerValue == "" { + Debugf("Unmarshalling did not find header with name:%s", headerName) + return nil + } + + if err = fromStringValue(headerValue, value, field); err != nil { + return fmt.Errorf("unmarshaling response to a header failed for field %s, due to %s", field.Name, + err.Error()) + } + return +} + +func addFromHeaderCollection(response *http.Response, value *reflect.Value, field reflect.StructField) error { + Debugln("Unmarshaling from header-collection to field:", field.Name) + var headerPrefix string + if headerPrefix = field.Tag.Get("prefix"); headerPrefix == "" { + return fmt.Errorf("Unmarshaling response to a header-collection requires the 'prefix' tag for field: %s", field.Name) + } + + mapCollection := make(map[string]string) + for name, value := range response.Header { + nameLowerCase := strings.ToLower(name) + if strings.HasPrefix(nameLowerCase, headerPrefix) { + headerNoPrefix := strings.TrimPrefix(nameLowerCase, headerPrefix) + mapCollection[headerNoPrefix] = value[0] + } + } + + Debugln("Marshalled header collection is:", mapCollection) + value.Set(reflect.ValueOf(mapCollection)) + return nil +} + +// Populates a struct from parts of a request by reading tags of the struct +func responseToStruct(response *http.Response, val *reflect.Value, unmarshaler PolymorphicJSONUnmarshaler) (err error) { + typ := val.Type() + for i := 0; i < typ.NumField(); i++ { + if err != nil { + return + } + + sf := typ.Field(i) + + //unexported + if sf.PkgPath != "" { + continue + } + + sv := val.Field(i) + tag := sf.Tag.Get("presentIn") + switch tag { + case "header": + err = addFromHeader(response, &sv, sf) + case "header-collection": + err = addFromHeaderCollection(response, &sv, sf) + case "body": + err = addFromBody(response, &sv, sf, unmarshaler) + case "": + Debugln(sf.Name, " does not contain presentIn tag. Skipping") + default: + err = fmt.Errorf("can not unmarshal field: %s. It needs to contain valid presentIn tag", sf.Name) + } + } + return +} + +// UnmarshalResponse hydrates the fields of a struct with the values of a http response, guided +// by the field tags. The directive tag is "presentIn" and it can be either +// - "header": Will look for the header tagged as "name" in the headers of the struct and set it value to that +// - "body": It will try to marshal the body from a json string to a struct tagged with 'presentIn: "body"'. +// Further this method will consume the body it should be safe to close it after this function +// Notice the current implementation only supports native types:int, strings, floats, bool as the field types +func UnmarshalResponse(httpResponse *http.Response, responseStruct interface{}) (err error) { + + var val *reflect.Value + if val, err = checkForValidResponseStruct(responseStruct); err != nil { + return + } + + if err = responseToStruct(httpResponse, val, nil); err != nil { + return + } + + return nil +} + +// UnmarshalResponseWithPolymorphicBody similar to UnmarshalResponse but assumes the body of the response +// contains polymorphic json. This function will use the unmarshaler argument to unmarshal json content +func UnmarshalResponseWithPolymorphicBody(httpResponse *http.Response, responseStruct interface{}, unmarshaler PolymorphicJSONUnmarshaler) (err error) { + + var val *reflect.Value + if val, err = checkForValidResponseStruct(responseStruct); err != nil { + return + } + + if err = responseToStruct(httpResponse, val, unmarshaler); err != nil { + return + } + + return nil +} + +// generate request id if user not provided and for each retry operation re-gen a new request id +func generateOpcRequestID(headerName string, value reflect.Value) (newValue reflect.Value) { + newValue = value + isNilValue := isNil(newValue) + isOpcRequestIDHeader := headerName == requestHeaderOpcRequestID || headerName == requestHeaderOpcClientRequestID + + if isNilValue && isOpcRequestIDHeader { + requestID, err := generateRandUUID() + + if err != nil { + // this will not fail the request, just skip add opc-request-id + Debugf("unable to generate opc-request-id. %s", err.Error()) + } else { + newValue = reflect.ValueOf(String(requestID)) + Debugf("add request id for header: %s, with value: %s", headerName, requestID) + } + } + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/http_signer.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/http_signer.go new file mode 100644 index 000000000..f678e17bb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/http_signer.go @@ -0,0 +1,270 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package common + +import ( + "bytes" + "crypto" + "crypto/rand" + "crypto/rsa" + "crypto/sha256" + "encoding/base64" + "fmt" + "io" + "io/ioutil" + "net/http" + "strings" +) + +// HTTPRequestSigner the interface to sign a request +type HTTPRequestSigner interface { + Sign(r *http.Request) error +} + +// KeyProvider interface that wraps information about the key's account owner +type KeyProvider interface { + PrivateRSAKey() (*rsa.PrivateKey, error) + KeyID() (string, error) +} + +const signerVersion = "1" + +// SignerBodyHashPredicate a function that allows to disable/enable body hashing +// of requests and headers associated with body content +type SignerBodyHashPredicate func(r *http.Request) bool + +// ociRequestSigner implements the http-signatures-draft spec +// as described in https://tools.ietf.org/html/draft-cavage-http-signatures-08 +type ociRequestSigner struct { + KeyProvider KeyProvider + GenericHeaders []string + BodyHeaders []string + ShouldHashBody SignerBodyHashPredicate +} + +var ( + defaultGenericHeaders = []string{"date", "(request-target)", "host"} + defaultBodyHeaders = []string{"content-length", "content-type", "x-content-sha256"} + defaultBodyHashPredicate = func(r *http.Request) bool { + return r.Method == http.MethodPost || r.Method == http.MethodPut || r.Method == http.MethodPatch + } +) + +// DefaultGenericHeaders list of default generic headers that is used in signing +func DefaultGenericHeaders() []string { + return makeACopy(defaultGenericHeaders) +} + +// DefaultBodyHeaders list of default body headers that is used in signing +func DefaultBodyHeaders() []string { + return makeACopy(defaultBodyHeaders) +} + +// DefaultRequestSigner creates a signer with default parameters. +func DefaultRequestSigner(provider KeyProvider) HTTPRequestSigner { + return RequestSigner(provider, defaultGenericHeaders, defaultBodyHeaders) +} + +// RequestSignerExcludeBody creates a signer without hash the body. +func RequestSignerExcludeBody(provider KeyProvider) HTTPRequestSigner { + bodyHashPredicate := func(r *http.Request) bool { + // week request signer will not hash the body + return false + } + return RequestSignerWithBodyHashingPredicate(provider, defaultGenericHeaders, defaultBodyHeaders, bodyHashPredicate) +} + +// NewSignerFromOCIRequestSigner creates a copy of the request signer and attaches the new SignerBodyHashPredicate +// returns an error if the passed signer is not of type ociRequestSigner +func NewSignerFromOCIRequestSigner(oldSigner HTTPRequestSigner, predicate SignerBodyHashPredicate) (HTTPRequestSigner, error) { + if oldS, ok := oldSigner.(ociRequestSigner); ok { + s := ociRequestSigner{ + KeyProvider: oldS.KeyProvider, + GenericHeaders: oldS.GenericHeaders, + BodyHeaders: oldS.BodyHeaders, + ShouldHashBody: predicate, + } + return s, nil + + } + return nil, fmt.Errorf("can not create a signer, input signer needs to be of type ociRequestSigner") +} + +// RequestSigner creates a signer that utilizes the specified headers for signing +// and the default predicate for using the body of the request as part of the signature +func RequestSigner(provider KeyProvider, genericHeaders, bodyHeaders []string) HTTPRequestSigner { + return ociRequestSigner{ + KeyProvider: provider, + GenericHeaders: genericHeaders, + BodyHeaders: bodyHeaders, + ShouldHashBody: defaultBodyHashPredicate} +} + +// RequestSignerWithBodyHashingPredicate creates a signer that utilizes the specified headers for signing, as well as a predicate for using +// the body of the request and bodyHeaders parameter as part of the signature +func RequestSignerWithBodyHashingPredicate(provider KeyProvider, genericHeaders, bodyHeaders []string, shouldHashBody SignerBodyHashPredicate) HTTPRequestSigner { + return ociRequestSigner{ + KeyProvider: provider, + GenericHeaders: genericHeaders, + BodyHeaders: bodyHeaders, + ShouldHashBody: shouldHashBody} +} + +func (signer ociRequestSigner) getSigningHeaders(r *http.Request) []string { + var result []string + result = append(result, signer.GenericHeaders...) + + if signer.ShouldHashBody(r) { + result = append(result, signer.BodyHeaders...) + } + + return result +} + +func (signer ociRequestSigner) getSigningString(request *http.Request) string { + signingHeaders := signer.getSigningHeaders(request) + signingParts := make([]string, len(signingHeaders)) + for i, part := range signingHeaders { + var value string + part = strings.ToLower(part) + switch part { + case "(request-target)": + value = getRequestTarget(request) + case "host": + value = request.URL.Host + if len(value) == 0 { + value = request.Host + } + default: + value = request.Header.Get(part) + } + signingParts[i] = fmt.Sprintf("%s: %s", part, value) + } + + signingString := strings.Join(signingParts, "\n") + return signingString + +} + +func getRequestTarget(request *http.Request) string { + lowercaseMethod := strings.ToLower(request.Method) + return fmt.Sprintf("%s %s", lowercaseMethod, request.URL.RequestURI()) +} + +func calculateHashOfBody(request *http.Request) (err error) { + var hash string + hash, err = GetBodyHash(request) + if err != nil { + return + } + request.Header.Set(requestHeaderXContentSHA256, hash) + return +} + +// drainBody reads all of b to memory and then returns two equivalent +// ReadClosers yielding the same bytes. +// +// It returns an error if the initial slurp of all bytes fails. It does not attempt +// to make the returned ReadClosers have identical error-matching behavior. +func drainBody(b io.ReadCloser) (r1, r2 io.ReadCloser, err error) { + if b == http.NoBody { + // No copying needed. Preserve the magic sentinel meaning of NoBody. + return http.NoBody, http.NoBody, nil + } + var buf bytes.Buffer + if _, err = buf.ReadFrom(b); err != nil { + return nil, b, err + } + if err = b.Close(); err != nil { + return nil, b, err + } + return ioutil.NopCloser(&buf), ioutil.NopCloser(bytes.NewReader(buf.Bytes())), nil +} + +func hashAndEncode(data []byte) string { + hashedContent := sha256.Sum256(data) + hash := base64.StdEncoding.EncodeToString(hashedContent[:]) + return hash +} + +// GetBodyHash creates a base64 string from the hash of body the request +func GetBodyHash(request *http.Request) (hashString string, err error) { + if request.Body == nil { + request.ContentLength = 0 + request.Header.Set(requestHeaderContentLength, fmt.Sprintf("%v", request.ContentLength)) + return hashAndEncode([]byte("")), nil + } + + var data []byte + bReader := request.Body + bReader, request.Body, err = drainBody(request.Body) + if err != nil { + return "", fmt.Errorf("can not read body of request while calculating body hash: %s", err.Error()) + } + + data, err = ioutil.ReadAll(bReader) + if err != nil { + return "", fmt.Errorf("can not read body of request while calculating body hash: %s", err.Error()) + } + + // Since the request can be coming from a binary body. Make an attempt to set the body length + request.ContentLength = int64(len(data)) + request.Header.Set(requestHeaderContentLength, fmt.Sprintf("%v", request.ContentLength)) + + hashString = hashAndEncode(data) + return +} + +func (signer ociRequestSigner) computeSignature(request *http.Request) (signature string, err error) { + signingString := signer.getSigningString(request) + hasher := sha256.New() + hasher.Write([]byte(signingString)) + hashed := hasher.Sum(nil) + + privateKey, err := signer.KeyProvider.PrivateRSAKey() + if err != nil { + return + } + + var unencodedSig []byte + unencodedSig, e := rsa.SignPKCS1v15(rand.Reader, privateKey, crypto.SHA256, hashed) + if e != nil { + err = fmt.Errorf("can not compute signature while signing the request %s: ", e.Error()) + return + } + + signature = base64.StdEncoding.EncodeToString(unencodedSig) + return +} + +// Sign signs the http request, by inspecting the necessary headers. Once signed +// the request will have the proper 'Authorization' header set, otherwise +// and error is returned +func (signer ociRequestSigner) Sign(request *http.Request) (err error) { + if signer.ShouldHashBody(request) { + err = calculateHashOfBody(request) + if err != nil { + return + } + } + + var signature string + if signature, err = signer.computeSignature(request); err != nil { + return + } + + signingHeaders := strings.Join(signer.getSigningHeaders(request), " ") + + var keyID string + if keyID, err = signer.KeyProvider.KeyID(); err != nil { + return + } + + authValue := fmt.Sprintf("Signature version=\"%s\",headers=\"%s\",keyId=\"%s\",algorithm=\"rsa-sha256\",signature=\"%s\"", + signerVersion, signingHeaders, keyID, signature) + + request.Header.Set(requestHeaderAuthorization, authValue) + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/log.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/log.go new file mode 100644 index 000000000..b9578fa35 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/log.go @@ -0,0 +1,230 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package common + +import ( + "fmt" + "io" + "io/ioutil" + "log" + "os" + "strings" + "sync" + "time" +) + +//sdkLogger an interface for logging in the SDK +type sdkLogger interface { + //LogLevel returns the log level of sdkLogger + LogLevel() int + + //Log logs v with the provided format if the current log level is loglevel + Log(logLevel int, format string, v ...interface{}) error +} + +//noLogging no logging messages +const noLogging = 0 + +//infoLogging minimal logging messages +const infoLogging = 1 + +//debugLogging some logging messages +const debugLogging = 2 + +//verboseLogging all logging messages +const verboseLogging = 3 + +//defaultSDKLogger the default implementation of the sdkLogger +type defaultSDKLogger struct { + currentLoggingLevel int + verboseLogger *log.Logger + debugLogger *log.Logger + infoLogger *log.Logger + nullLogger *log.Logger +} + +//defaultLogger is the defaultLogger in the SDK +var defaultLogger sdkLogger +var loggerLock sync.Mutex +var file *os.File + +//initializes the SDK defaultLogger as a defaultLogger +func init() { + l, _ := newSDKLogger() + setSDKLogger(l) +} + +//setSDKLogger sets the logger used by the sdk +func setSDKLogger(logger sdkLogger) { + loggerLock.Lock() + defaultLogger = logger + loggerLock.Unlock() +} + +// newSDKLogger creates a defaultSDKLogger +// Debug logging is turned on/off by the presence of the environment variable "OCI_GO_SDK_DEBUG" +// The value of the "OCI_GO_SDK_DEBUG" environment variable controls the logging level. +// "null" outputs no log messages +// "i" or "info" outputs minimal log messages +// "d" or "debug" outputs some logs messages +// "v" or "verbose" outputs all logs messages, including body of requests +func newSDKLogger() (defaultSDKLogger, error) { + logger := defaultSDKLogger{} + + logger.currentLoggingLevel = noLogging + logger.verboseLogger = log.New(os.Stderr, "VERBOSE ", log.Ldate|log.Lmicroseconds|log.Lshortfile) + logger.debugLogger = log.New(os.Stderr, "DEBUG ", log.Ldate|log.Lmicroseconds|log.Lshortfile) + logger.infoLogger = log.New(os.Stderr, "INFO ", log.Ldate|log.Lmicroseconds|log.Lshortfile) + logger.nullLogger = log.New(ioutil.Discard, "", log.Ldate|log.Lmicroseconds|log.Lshortfile) + + configured, isLogEnabled := os.LookupEnv("OCI_GO_SDK_DEBUG") + + // If env variable not present turn logging off + if !isLogEnabled { + logger.currentLoggingLevel = noLogging + } else { + logOutputModeConfig(logger) + + switch strings.ToLower(configured) { + case "null": + logger.currentLoggingLevel = noLogging + break + case "i", "info": + logger.currentLoggingLevel = infoLogging + break + case "d", "debug": + logger.currentLoggingLevel = debugLogging + break + //1 here for backwards compatibility + case "v", "verbose", "1": + logger.currentLoggingLevel = verboseLogging + break + default: + logger.currentLoggingLevel = infoLogging + } + logger.infoLogger.Println("logger level set to: ", logger.currentLoggingLevel) + } + + return logger, nil +} + +func (l defaultSDKLogger) getLoggerForLevel(logLevel int) *log.Logger { + if logLevel > l.currentLoggingLevel { + return l.nullLogger + } + + switch logLevel { + case noLogging: + return l.nullLogger + case infoLogging: + return l.infoLogger + case debugLogging: + return l.debugLogger + case verboseLogging: + return l.verboseLogger + default: + return l.nullLogger + } +} + +// Set SDK Log output mode +// Output mode is switched based on environment variable "OCI_GO_SDK_LOG_OUPUT_MODE" +// "file" outputs log to a specific file +// "combine" outputs log to both stderr and specific file +// other unsupported value outputs log to stderr +// output file can be set via environment variable "OCI_GO_SDK_LOG_FILE" +// if this environment variable is not set, a default log file will be created under project root path +func logOutputModeConfig(logger defaultSDKLogger) { + logMode, isLogOutputModeEnabled := os.LookupEnv("OCI_GO_SDK_LOG_OUTPUT_MODE") + if !isLogOutputModeEnabled { + return + } + fileName, isLogFileNameProvided := os.LookupEnv("OCI_GO_SDK_LOG_FILE") + if !isLogFileNameProvided { + fileName = fmt.Sprintf("logging_%v%s", time.Now().Unix(), ".log") + } + + switch strings.ToLower(logMode) { + case "file", "f": + file = openLogOutputFile(logger, fileName) + logger.infoLogger.SetOutput(file) + logger.debugLogger.SetOutput(file) + logger.verboseLogger.SetOutput(file) + break + case "combine", "c": + file = openLogOutputFile(logger, fileName) + wrt := io.MultiWriter(os.Stderr, file) + + logger.infoLogger.SetOutput(wrt) + logger.debugLogger.SetOutput(wrt) + logger.verboseLogger.SetOutput(wrt) + break + } +} + +func openLogOutputFile(logger defaultSDKLogger, fileName string) *os.File { + file, err := os.OpenFile(fileName, os.O_WRONLY|os.O_CREATE|os.O_APPEND, 0644) + if err != nil { + logger.verboseLogger.Fatal(err) + } + return file +} + +//CloseLogFile close the logging file and return error +func CloseLogFile() error { + return file.Close() +} + +//LogLevel returns the current debug level +func (l defaultSDKLogger) LogLevel() int { + return l.currentLoggingLevel +} + +func (l defaultSDKLogger) Log(logLevel int, format string, v ...interface{}) error { + logger := l.getLoggerForLevel(logLevel) + logger.Output(4, fmt.Sprintf(format, v...)) + return nil +} + +//Logln logs v appending a new line at the end +//Deprecated +func Logln(v ...interface{}) { + defaultLogger.Log(infoLogging, "%v\n", v...) +} + +// Logf logs v with the provided format +func Logf(format string, v ...interface{}) { + defaultLogger.Log(infoLogging, format, v...) +} + +// Debugf logs v with the provided format if debug mode is set +func Debugf(format string, v ...interface{}) { + defaultLogger.Log(debugLogging, format, v...) +} + +// Debug logs v if debug mode is set +func Debug(v ...interface{}) { + m := fmt.Sprint(v...) + defaultLogger.Log(debugLogging, "%s", m) +} + +// Debugln logs v appending a new line if debug mode is set +func Debugln(v ...interface{}) { + m := fmt.Sprint(v...) + defaultLogger.Log(debugLogging, "%s\n", m) +} + +// IfDebug executes closure if debug is enabled +func IfDebug(fn func()) { + if defaultLogger.LogLevel() >= debugLogging { + fn() + } +} + +// IfInfo executes closure if info is enabled +func IfInfo(fn func()) { + if defaultLogger.LogLevel() >= infoLogging { + fn() + } +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/regions.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/regions.go new file mode 100644 index 000000000..fa16cb133 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/regions.go @@ -0,0 +1,173 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package common + +const ( + //RegionAPChuncheon1 region Chuncheon + RegionAPChuncheon1 Region = "ap-chuncheon-1" + //RegionAPHyderabad1 region Hyderabad + RegionAPHyderabad1 Region = "ap-hyderabad-1" + //RegionAPMelbourne1 region Melbourne + RegionAPMelbourne1 Region = "ap-melbourne-1" + //RegionAPMumbai1 region Mumbai + RegionAPMumbai1 Region = "ap-mumbai-1" + //RegionAPOsaka1 region Osaka + RegionAPOsaka1 Region = "ap-osaka-1" + //RegionAPSeoul1 region Seoul + RegionAPSeoul1 Region = "ap-seoul-1" + //RegionAPSydney1 region Sydney + RegionAPSydney1 Region = "ap-sydney-1" + //RegionAPTokyo1 region Tokyo + RegionAPTokyo1 Region = "ap-tokyo-1" + //RegionCAMontreal1 region Montreal + RegionCAMontreal1 Region = "ca-montreal-1" + //RegionCAToronto1 region Toronto + RegionCAToronto1 Region = "ca-toronto-1" + //RegionEUAmsterdam1 region Amsterdam + RegionEUAmsterdam1 Region = "eu-amsterdam-1" + //RegionFRA region Frankfurt + RegionFRA Region = "eu-frankfurt-1" + //RegionEUZurich1 region Zurich + RegionEUZurich1 Region = "eu-zurich-1" + //RegionMEJeddah1 region Jeddah + RegionMEJeddah1 Region = "me-jeddah-1" + //RegionMEDubai1 region Dubai + RegionMEDubai1 Region = "me-dubai-1" + //RegionSASaopaulo1 region Saopaulo + RegionSASaopaulo1 Region = "sa-saopaulo-1" + //RegionUKCardiff1 region Cardiff + RegionUKCardiff1 Region = "uk-cardiff-1" + //RegionLHR region London + RegionLHR Region = "uk-london-1" + //RegionIAD region Ashburn + RegionIAD Region = "us-ashburn-1" + //RegionPHX region Phoenix + RegionPHX Region = "us-phoenix-1" + //RegionSJC1 region Sanjose + RegionSJC1 Region = "us-sanjose-1" + //RegionSAVinhedo1 region Vinhedo + RegionSAVinhedo1 Region = "sa-vinhedo-1" + //RegionSASantiago1 region Santiago + RegionSASantiago1 Region = "sa-santiago-1" + //RegionILJerusalem1 region Jerusalem + RegionILJerusalem1 Region = "il-jerusalem-1" + //RegionEUMarseille1 region Marseille + RegionEUMarseille1 Region = "eu-marseille-1" + //RegionAPSingapore1 region Singapore + RegionAPSingapore1 Region = "ap-singapore-1" + //RegionMEAbudhabi1 region Abudhabi + RegionMEAbudhabi1 Region = "me-abudhabi-1" + //RegionEUMilan1 region Milan + RegionEUMilan1 Region = "eu-milan-1" + //RegionUSLangley1 region Langley + RegionUSLangley1 Region = "us-langley-1" + //RegionUSLuke1 region Luke + RegionUSLuke1 Region = "us-luke-1" + //RegionUSGovAshburn1 gov region Ashburn + RegionUSGovAshburn1 Region = "us-gov-ashburn-1" + //RegionUSGovChicago1 gov region Chicago + RegionUSGovChicago1 Region = "us-gov-chicago-1" + //RegionUSGovPhoenix1 gov region Phoenix + RegionUSGovPhoenix1 Region = "us-gov-phoenix-1" + //RegionUKGovLondon1 gov region London + RegionUKGovLondon1 Region = "uk-gov-london-1" + //RegionUKGovCardiff1 gov region Cardiff + RegionUKGovCardiff1 Region = "uk-gov-cardiff-1" + //RegionAPChiyoda1 region Chiyoda + RegionAPChiyoda1 Region = "ap-chiyoda-1" + //RegionAPIbaraki1 region Ibaraki + RegionAPIbaraki1 Region = "ap-ibaraki-1" +) + +var shortNameRegion = map[string]Region{ + "yny": RegionAPChuncheon1, + "hyd": RegionAPHyderabad1, + "mel": RegionAPMelbourne1, + "bom": RegionAPMumbai1, + "kix": RegionAPOsaka1, + "icn": RegionAPSeoul1, + "syd": RegionAPSydney1, + "nrt": RegionAPTokyo1, + "yul": RegionCAMontreal1, + "yyz": RegionCAToronto1, + "ams": RegionEUAmsterdam1, + "fra": RegionFRA, + "zrh": RegionEUZurich1, + "jed": RegionMEJeddah1, + "dxb": RegionMEDubai1, + "gru": RegionSASaopaulo1, + "cwl": RegionUKCardiff1, + "lhr": RegionLHR, + "iad": RegionIAD, + "phx": RegionPHX, + "sjc": RegionSJC1, + "vcp": RegionSAVinhedo1, + "scl": RegionSASantiago1, + "mtz": RegionILJerusalem1, + "mrs": RegionEUMarseille1, + "sin": RegionAPSingapore1, + "auh": RegionMEAbudhabi1, + "lin": RegionEUMilan1, + "lfi": RegionUSLangley1, + "luf": RegionUSLuke1, + "ric": RegionUSGovAshburn1, + "pia": RegionUSGovChicago1, + "tus": RegionUSGovPhoenix1, + "ltn": RegionUKGovLondon1, + "brs": RegionUKGovCardiff1, + "nja": RegionAPChiyoda1, + "ukb": RegionAPIbaraki1, +} + +var realm = map[string]string{ + "oc1": "oraclecloud.com", + "oc2": "oraclegovcloud.com", + "oc3": "oraclegovcloud.com", + "oc4": "oraclegovcloud.uk", + "oc8": "oraclecloud8.com", +} + +var regionRealm = map[Region]string{ + RegionAPChuncheon1: "oc1", + RegionAPHyderabad1: "oc1", + RegionAPMelbourne1: "oc1", + RegionAPMumbai1: "oc1", + RegionAPOsaka1: "oc1", + RegionAPSeoul1: "oc1", + RegionAPSydney1: "oc1", + RegionAPTokyo1: "oc1", + RegionCAMontreal1: "oc1", + RegionCAToronto1: "oc1", + RegionEUAmsterdam1: "oc1", + RegionFRA: "oc1", + RegionEUZurich1: "oc1", + RegionMEJeddah1: "oc1", + RegionMEDubai1: "oc1", + RegionSASaopaulo1: "oc1", + RegionUKCardiff1: "oc1", + RegionLHR: "oc1", + RegionIAD: "oc1", + RegionPHX: "oc1", + RegionSJC1: "oc1", + RegionSAVinhedo1: "oc1", + RegionSASantiago1: "oc1", + RegionILJerusalem1: "oc1", + RegionEUMarseille1: "oc1", + RegionAPSingapore1: "oc1", + RegionMEAbudhabi1: "oc1", + RegionEUMilan1: "oc1", + + RegionUSLangley1: "oc2", + RegionUSLuke1: "oc2", + + RegionUSGovAshburn1: "oc3", + RegionUSGovChicago1: "oc3", + RegionUSGovPhoenix1: "oc3", + + RegionUKGovLondon1: "oc4", + RegionUKGovCardiff1: "oc4", + + RegionAPChiyoda1: "oc8", + RegionAPIbaraki1: "oc8", +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/regions.json b/vendor/github.com/oracle/oci-go-sdk/v54/common/regions.json new file mode 100644 index 000000000..64484086d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/regions.json @@ -0,0 +1,224 @@ +[ + { + "regionKey": "yny", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "ap-chuncheon-1", + "realmKey": "oc1" + }, + { + "regionKey": "hyd", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "ap-hyderabad-1", + "realmKey": "oc1" + }, + { + "regionKey": "mel", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "ap-melbourne-1", + "realmKey": "oc1" + }, + { + "regionKey": "bom", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "ap-mumbai-1", + "realmKey": "oc1" + }, + { + "regionKey": "kix", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "ap-osaka-1", + "realmKey": "oc1" + }, + { + "regionKey": "icn", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "ap-seoul-1", + "realmKey": "oc1" + }, + { + "regionKey": "syd", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "ap-sydney-1", + "realmKey": "oc1" + }, + { + "regionKey": "nrt", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "ap-tokyo-1", + "realmKey": "oc1" + }, + { + "regionKey": "yul", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "ca-montreal-1", + "realmKey": "oc1" + }, + { + "regionKey": "yyz", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "ca-toronto-1", + "realmKey": "oc1" + }, + { + "regionKey": "ams", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "eu-amsterdam-1", + "realmKey": "oc1" + }, + { + "regionKey": "fra", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "eu-frankfurt-1", + "realmKey": "oc1" + }, + { + "regionKey": "zrh", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "eu-zurich-1", + "realmKey": "oc1" + }, + { + "regionKey": "jed", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "me-jeddah-1", + "realmKey": "oc1" + }, + { + "regionKey": "dxb", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "me-dubai-1", + "realmKey": "oc1" + }, + { + "regionKey": "gru", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "sa-saopaulo-1", + "realmKey": "oc1" + }, + { + "regionKey": "cwl", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "uk-cardiff-1", + "realmKey": "oc1" + }, + { + "regionKey": "lhr", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "uk-london-1", + "realmKey": "oc1" + }, + { + "regionKey": "iad", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "us-ashburn-1", + "realmKey": "oc1" + }, + { + "regionKey": "phx", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "us-phoenix-1", + "realmKey": "oc1" + }, + { + "regionKey": "sjc", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "us-sanjose-1", + "realmKey": "oc1" + }, + { + "regionKey": "vcp", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "sa-vinhedo-1", + "realmKey": "oc1" + }, + { + "regionKey": "scl", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "sa-santiago-1", + "realmKey": "oc1" + }, + { + "regionKey": "lfi", + "realmDomainComponent": "oraclegovcloud.com", + "regionIdentifier": "us-langley-1", + "realmKey": "oc2" + }, + { + "regionKey": "luf", + "realmDomainComponent": "oraclegovcloud.com", + "regionIdentifier": "us-luke-1", + "realmKey": "oc2" + }, + { + "regionKey": "ric", + "realmDomainComponent": "oraclegovcloud.com", + "regionIdentifier": "us-gov-ashburn-1", + "realmKey": "oc3" + }, + { + "regionKey": "pia", + "realmDomainComponent": "oraclegovcloud.com", + "regionIdentifier": "us-gov-chicago-1", + "realmKey": "oc3" + }, + { + "regionKey": "tus", + "realmDomainComponent": "oraclegovcloud.com", + "regionIdentifier": "us-gov-phoenix-1", + "realmKey": "oc3" + }, + { + "regionKey": "ltn", + "realmDomainComponent": "oraclegovcloud.uk", + "regionIdentifier": "uk-gov-london-1", + "realmKey": "oc4" + }, + { + "regionKey": "brs", + "realmDomainComponent": "oraclegovcloud.uk", + "regionIdentifier": "uk-gov-cardiff-1", + "realmKey": "oc4" + }, + { + "regionKey": "nja", + "realmDomainComponent": "oraclecloud8.com", + "regionIdentifier": "ap-chiyoda-1", + "realmKey": "oc8" + }, + { + "regionKey": "ukb", + "realmDomainComponent": "oraclecloud8.com", + "regionIdentifier": "ap-ibaraki-1", + "realmKey": "oc8" + }, + { + "regionKey": "mtz", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "il-jerusalem-1", + "realmKey": "oc1" + }, + { + "regionKey": "mrs", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "eu-marseille-1", + "realmKey": "oc1" + }, + { + "regionKey": "sin", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "ap-singapore-1", + "realmKey": "oc1" + }, + { + "regionKey": "auh", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "me-abudhabi-1", + "realmKey": "oc1" + }, + { + "regionKey": "lin", + "realmDomainComponent": "oraclecloud.com", + "regionIdentifier": "eu-milan-1", + "realmKey": "oc1" + } +] \ No newline at end of file diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/retry.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/retry.go new file mode 100644 index 000000000..84b925e15 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/retry.go @@ -0,0 +1,1052 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package common + +import ( + "bytes" + "context" + "errors" + "fmt" + "io" + "math" + "math/rand" + "os" + "runtime" + "strconv" + "strings" + "sync" + "sync/atomic" + "time" +) + +const ( + // UnlimitedNumAttemptsValue is the value for indicating unlimited attempts for reaching success + UnlimitedNumAttemptsValue = uint(0) + + // number of characters contained in the generated retry token + generatedRetryTokenLength = 32 +) + +// OCIRetryableRequest represents a request that can be reissued according to the specified policy. +type OCIRetryableRequest interface { + // Any retryable request must implement the OCIRequest interface + OCIRequest + + // Each operation should implement this method, if has binary body, return OCIReadSeekCloser and true, otherwise return nil, false + BinaryRequestBody() (*OCIReadSeekCloser, bool) + + // Each operation specifies default retry behavior. By passing no arguments to this method, the default retry + // behavior, as determined on a per-operation-basis, will be honored. Variadic retry policy option arguments + // passed to this method will override the default behavior. + RetryPolicy() *RetryPolicy +} + +// OCIOperationResponse represents the output of an OCIOperation, with additional context of error message +// and operation attempt number. +type OCIOperationResponse struct { + // Response from OCI Operation + Response OCIResponse + + // Error from OCI Operation + Error error + + // Operation Attempt Number (one-based) + AttemptNumber uint + + // End of eventually consistent effects, or nil if no such effects + EndOfWindowTime *time.Time + + // Backoff scaling factor (only used for dealing with eventual consistency) + BackoffScalingFactor float64 + + // Time of the initial attempt + InitialAttemptTime time.Time +} + +// EventuallyConsistentContext contains the information about the end of the eventually consistent window. +type EventuallyConsistentContext struct { + endOfWindow atomic.Value + lock sync.RWMutex + timeNowProvider func() time.Time +} + +// getGID returns the Goroutine id. This is purely for logging and debugging. +// See https://blog.sgmansfield.com/2015/12/goroutine-ids/ +func getGID() uint64 { + b := make([]byte, 64) + b = b[:runtime.Stack(b, false)] + b = bytes.TrimPrefix(b, []byte("goroutine ")) + b = b[:bytes.IndexByte(b, ' ')] + n, _ := strconv.ParseUint(string(b), 10, 64) + return n +} + +// Debugf logs v with the provided format if debug mode is set. +// There is no mutex synchronization. You should have acquired e.lock first. +func ecDebugf(format string, v ...interface{}) { + defer func() { + // recover from panic if one occured. + if recover() != nil { + Debugln("ecDebugf failed") + } + }() + + str := fmt.Sprintf(format, v...) + // prefix message with "(pid=25140, gid=5)" + Debugf("(pid=%d, gid=%d) %s", os.Getpid(), getGID(), str) +} + +// Debug logs v if debug mode is set. +// There is no mutex synchronization. You should have acquired e.lock first. +func ecDebug(v ...interface{}) { + defer func() { + // recover from panic if one occured. + if recover() != nil { + Debugln("ecDebug failed") + } + }() + + // prefix message with "(pid=25140, gid=5)" + Debug(append([]interface{}{"(pid=", os.Getpid(), ", gid=", getGID(), ") "}, v...)...) +} + +// Debugln logs v appending a new line if debug mode is set +// There is no mutex synchronization. You should have acquired e.lock first. +func ecDebugln(v ...interface{}) { + defer func() { + // recover from panic if one occured. + if recover() != nil { + Debugln("ecDebugln failed") + } + }() + + // prefix message with "(pid=25140, gid=5)" + Debugln(append([]interface{}{"(pid=", os.Getpid(), ", gid=", getGID(), ") "}, v...)...) +} + +// GetEndOfWindow returns the end time an eventually consistent window, +// or nil if no eventually consistent requests were made +func (e *EventuallyConsistentContext) GetEndOfWindow() *time.Time { + e.lock.RLock() // synchronize with potential writers + defer e.lock.RUnlock() + + endOfWindowTime := e.getEndOfWindowUnsynchronized() + + // TODO: this is noisy logging, consider removing + if endOfWindowTime != nil { + ecDebugln(fmt.Sprintf("EcContext.GetEndOfWindow returns %s", endOfWindowTime)) + } else { + ecDebugln("EcContext.GetEndOfWindow returns ") + } + + return endOfWindowTime +} + +// getEndOfWindow_unsynchronized returns the end time an eventually consistent window, +// or nil if no eventually consistent requests were made. +// There is no mutex synchronization. +func (e *EventuallyConsistentContext) getEndOfWindowUnsynchronized() *time.Time { + untyped := e.endOfWindow.Load() // returns nil if there has been no call to Store for this Value + if untyped == nil { + return (*time.Time)(nil) + } + t := untyped.(*time.Time) + + return t +} + +// UpdateEndOfWindow sets the end time of the eventually consistent window the specified +// duration into the future +func (e *EventuallyConsistentContext) UpdateEndOfWindow(windowSize time.Duration) *time.Time { + e.lock.Lock() // synchronize with other potential writers + defer e.lock.Unlock() + + currentEndOfWindowTime := e.getEndOfWindowUnsynchronized() + var newEndOfWindowTime = e.timeNowProvider().Add(windowSize) + if currentEndOfWindowTime == nil || newEndOfWindowTime.After(*currentEndOfWindowTime) { + e.endOfWindow.Store(&newEndOfWindowTime) // atomically replace the current object with the new one + + // TODO: this is noisy logging, consider removing + ecDebugln(fmt.Sprintf("EcContext.UpdateEndOfWindow to %s", newEndOfWindowTime)) + + return &newEndOfWindowTime + } + return currentEndOfWindowTime +} + +// setEndTimeOfEventuallyConsistentWindow sets the last time an eventually consistent request was made +// to the specified time +func (e *EventuallyConsistentContext) setEndOfWindow(newTime *time.Time) *time.Time { + e.lock.Lock() // synchronize with other potential writers + defer e.lock.Unlock() + + e.endOfWindow.Store(newTime) // atomically replace the current object with the new one + + // TODO: this is noisy logging, consider removing + if newTime != nil { + ecDebugln(fmt.Sprintf("EcContext.setEndOfWindow to %s", *newTime)) + } else { + ecDebugln("EcContext.setEndOfWindow to ") + } + + return newTime +} + +// EcContext contains the information about the end of the eventually consistent window for this process. +var EcContext = EventuallyConsistentContext{ + timeNowProvider: func() time.Time { return time.Now() }, +} + +const ( + defaultMaximumNumberAttempts = uint(8) + defaultExponentialBackoffBase = 2.0 + defaultMinSleepBetween = 0.0 + defaultMaxSleepBetween = 30.0 + + ecMaximumNumberAttempts = uint(9) + ecExponentialBackoffBase = 3.52 + ecMinSleepBetween = 0.0 + ecMaxSleepBetween = 45.0 +) + +var ( + defaultRetryStatusCodeMap = map[StatErrCode]bool{ + {409, "IncorrectState"}: true, + {429, "TooManyRequests"}: true, + + {501, "MethodNotImplemented"}: false, + } + affectedByEventualConsistencyRetryStatusCodeMap = map[StatErrCode]bool{ + {400, "RelatedResourceNotAuthorizedOrNotFound"}: true, + {404, "NotAuthorizedOrNotFound"}: true, + {409, "NotAuthorizedOrResourceAlreadyExists"}: true, + } +) + +// IsErrorAffectedByEventualConsistency returns true if the error is affected by eventual consistency. +func IsErrorAffectedByEventualConsistency(Error error) bool { + if err, ok := IsServiceError(Error); ok { + return affectedByEventualConsistencyRetryStatusCodeMap[StatErrCode{err.GetHTTPStatusCode(), err.GetCode()}] + } + return false +} + +// IsErrorRetryableByDefault returns true if the error is retryable by OCI default retry policy +func IsErrorRetryableByDefault(Error error) bool { + if Error == nil { + return false + } + + if IsNetworkError(Error) { + return true + } + + if err, ok := IsServiceError(Error); ok { + if shouldRetry, ok := defaultRetryStatusCodeMap[StatErrCode{err.GetHTTPStatusCode(), err.GetCode()}]; ok { + return shouldRetry + } + + return 500 <= err.GetHTTPStatusCode() && err.GetHTTPStatusCode() < 505 + } + + return false +} + +// NewOCIOperationResponse assembles an OCI Operation Response object. +// Note that InitialAttemptTime is not set, nor is EndOfWindowTime, and BackoffScalingFactor is set to 1.0. +// EndOfWindowTime and BackoffScalingFactor are only important for eventual consistency. +// InitialAttemptTime can be useful for time-based (as opposed to count-based) retry policies. +func NewOCIOperationResponse(response OCIResponse, err error, attempt uint) OCIOperationResponse { + return OCIOperationResponse{ + Response: response, + Error: err, + AttemptNumber: attempt, + BackoffScalingFactor: 1.0, + } +} + +// NewOCIOperationResponseExtended assembles an OCI Operation Response object, with the value for the EndOfWindowTime, BackoffScalingFactor, and InitialAttemptTime set. +// EndOfWindowTime and BackoffScalingFactor are only important for eventual consistency. +// InitialAttemptTime can be useful for time-based (as opposed to count-based) retry policies. +func NewOCIOperationResponseExtended(response OCIResponse, err error, attempt uint, endOfWindowTime *time.Time, backoffScalingFactor float64, + initialAttemptTime time.Time) OCIOperationResponse { + return OCIOperationResponse{ + Response: response, + Error: err, + AttemptNumber: attempt, + EndOfWindowTime: endOfWindowTime, + BackoffScalingFactor: backoffScalingFactor, + InitialAttemptTime: initialAttemptTime, + } +} + +// +// RetryPolicy +// + +// RetryPolicy is the class that holds all relevant information for retrying operations. +type RetryPolicy struct { + // MaximumNumberAttempts is the maximum number of times to retry a request. Zero indicates an unlimited + // number of attempts. + MaximumNumberAttempts uint + + // ShouldRetryOperation inspects the http response, error, and operation attempt number, and + // - returns true if we should retry the operation + // - returns false otherwise + ShouldRetryOperation func(OCIOperationResponse) bool + + // GetNextDuration computes the duration to pause between operation retries. + NextDuration func(OCIOperationResponse) time.Duration + + // minimum sleep between attempts in seconds + MinSleepBetween float64 + + // maximum sleep between attempts in seconds + MaxSleepBetween float64 + + // the base for the exponential backoff + ExponentialBackoffBase float64 + + // DeterminePolicyToUse may modify the policy to handle eventual consistency; the return values are + // the retry policy to use, the end of the eventually consistent time window, and the backoff scaling factor + // If eventual consistency is not considered, this function should return the unmodified policy that was + // provided as input, along with (*time.Time)(nil) (no time window), and 1.0 (unscaled backoff). + DeterminePolicyToUse func(policy RetryPolicy) (RetryPolicy, *time.Time, float64) + + // if the retry policy considers eventual consistency, but there is no eventual consistency present + // the retries will fall back to the policy specified here; recommendation is to set this to DefaultRetryPolicyWithoutEventualConsistency() + NonEventuallyConsistentPolicy *RetryPolicy + + // Stores the maximum cumulative backoff in seconds. This can usually be calculated using + // MaximumNumberAttempts, MinSleepBetween, MaxSleepBetween, and ExponentialBackoffBase, + // but if MaximumNumberAttempts is 0 (unlimited attempts), then this needs to be set explicitly + // for Eventual Consistency retries to work. + MaximumCumulativeBackoffWithoutJitter float64 +} + +// GlobalRetry is user defined global level retry policy, it would impact all services, the precedence is lower +// than user defined client/request level retry policy +var GlobalRetry *RetryPolicy = nil + +// RetryPolicyOption is the type of the options for NewRetryPolicy. +type RetryPolicyOption func(rp *RetryPolicy) + +// Convert retry policy to human-readable string representation +func (rp RetryPolicy) String() string { + return fmt.Sprintf("{MaximumNumberAttempts=%v, MinSleepBetween=%v, MaxSleepBetween=%v, ExponentialBackoffBase=%v, NonEventuallyConsistentPolicy=%v}", + rp.MaximumNumberAttempts, rp.MinSleepBetween, rp.MaxSleepBetween, rp.ExponentialBackoffBase, rp.NonEventuallyConsistentPolicy) +} + +// Validate returns true if the RetryPolicy is valid; if not, it also returns an error. +func (rp *RetryPolicy) validate() (success bool, err error) { + var errorStrings []string + if rp.ShouldRetryOperation == nil { + errorStrings = append(errorStrings, "ShouldRetryOperation may not be nil") + } + if rp.NextDuration == nil { + errorStrings = append(errorStrings, "NextDuration may not be nil") + } + if rp.NonEventuallyConsistentPolicy != nil { + if rp.MaximumNumberAttempts == 0 && rp.MaximumCumulativeBackoffWithoutJitter <= 0 { + errorStrings = append(errorStrings, "If eventual consistency is handled, and the MaximumNumberAttempts of the EC retry policy is 0 (unlimited attempts), then the MaximumCumulativeBackoffWithoutJitter of the EC retry policy must be positive; used WithUnlimitedAttempts instead") + } + nonEcRp := rp.NonEventuallyConsistentPolicy + if nonEcRp.MaximumNumberAttempts == 0 && nonEcRp.MaximumCumulativeBackoffWithoutJitter <= 0 { + errorStrings = append(errorStrings, "If eventual consistency is handled, and the MaximumNumberAttempts of the non-EC retry policy is 0 (unlimited attempts), then the MaximumCumulativeBackoffWithoutJitter of the non-EC retry policy must be positive; used WithUnlimitedAttempts instead") + } + } + if len(errorStrings) > 0 { + return false, errors.New(strings.Join(errorStrings, ", ")) + } + + // some legacy code constructing RetryPolicy instances directly may not have set DeterminePolicyToUse. + // In that case, just assume that it doesn't handle eventual consistency. + if rp.DeterminePolicyToUse == nil { + rp.DeterminePolicyToUse = returnSamePolicy + } + + return true, nil +} + +// GetMaximumCumulativeBackoffWithoutJitter returns the maximum cumulative backoff the retry policy would do, +// taking into account whether eventually consistency is considered or not. +// This function uses either GetMaximumCumulativeBackoffWithoutJitter or GetMaximumCumulativeEventuallyConsistentBackoffWithoutJitter, +// whichever is appropriate +func (rp RetryPolicy) GetMaximumCumulativeBackoffWithoutJitter() time.Duration { + if rp.NonEventuallyConsistentPolicy == nil { + return GetMaximumCumulativeBackoffWithoutJitter(rp) + } + return GetMaximumCumulativeEventuallyConsistentBackoffWithoutJitter(rp) +} + +// +// Functions to calculate backoff and maximum cumulative backoff +// + +// GetBackoffWithoutJitter calculates the backoff without jitter for the attempt, given the retry policy. +func GetBackoffWithoutJitter(policy RetryPolicy, attempt uint) time.Duration { + return time.Duration(getBackoffWithoutJitterHelper(policy.MinSleepBetween, policy.MaxSleepBetween, policy.ExponentialBackoffBase, attempt)) * time.Second +} + +// getBackoffWithoutJitterHelper calculates the backoff without jitter for the attempt, given the loose retry policy values. +func getBackoffWithoutJitterHelper(minSleepBetween float64, maxSleepBetween float64, exponentialBackoffBase float64, attempt uint) float64 { + sleepTime := math.Pow(exponentialBackoffBase, float64(attempt-1)) + if sleepTime < minSleepBetween { + sleepTime = minSleepBetween + } + if sleepTime > maxSleepBetween { + sleepTime = maxSleepBetween + } + return sleepTime +} + +// GetMaximumCumulativeBackoffWithoutJitter calculates the maximum backoff without jitter, according to the retry +// policy, if every retry attempt is made. +func GetMaximumCumulativeBackoffWithoutJitter(policy RetryPolicy) time.Duration { + return getMaximumCumulativeBackoffWithoutJitterHelper(policy.MinSleepBetween, policy.MaxSleepBetween, policy.ExponentialBackoffBase, policy.MaximumNumberAttempts, policy.MaximumCumulativeBackoffWithoutJitter) +} + +func getMaximumCumulativeBackoffWithoutJitterHelper(minSleepBetween float64, maxSleepBetween float64, exponentialBackoffBase float64, MaximumNumberAttempts uint, MaximumCumulativeBackoffWithoutJitter float64) time.Duration { + var cumulative time.Duration = 0 + + if MaximumNumberAttempts == 0 { + // unlimited + return time.Duration(MaximumCumulativeBackoffWithoutJitter) * time.Second + } + + // use a one-based counter because it's easier to think about operation retry in terms of attempt numbering + for currentOperationAttempt := uint(1); currentOperationAttempt < MaximumNumberAttempts; currentOperationAttempt++ { + cumulative += time.Duration(getBackoffWithoutJitterHelper(minSleepBetween, maxSleepBetween, exponentialBackoffBase, currentOperationAttempt)) * time.Second + } + return cumulative +} + +// +// Functions to calculate backoff and maximum cumulative backoff for eventual consistency +// + +// GetEventuallyConsistentBackoffWithoutJitter calculates the backoff without jitter for the attempt, given the retry policy +// and dealing with eventually consistent effects. The result is then multiplied by backoffScalingFactor. +func GetEventuallyConsistentBackoffWithoutJitter(policy RetryPolicy, attempt uint, backoffScalingFactor float64) time.Duration { + return time.Duration(getEventuallyConsistentBackoffWithoutJitterHelper(policy.MinSleepBetween, policy.MaxSleepBetween, policy.ExponentialBackoffBase, attempt, backoffScalingFactor, + func(minSleepBetween float64, maxSleepBetween float64, exponentialBackoffBase float64, attempt uint) float64 { + rp := policy.NonEventuallyConsistentPolicy + return getBackoffWithoutJitterHelper(rp.MinSleepBetween, rp.MaxSleepBetween, rp.ExponentialBackoffBase, attempt) + })*1000) * time.Millisecond +} + +// getEventuallyConsistentBackoffWithoutJitterHelper calculates the backoff without jitter for the attempt, given the loose retry policy values, +// and dealing with eventually consistent effects. The result is then multiplied by backoffScalingFactor. +func getEventuallyConsistentBackoffWithoutJitterHelper(minSleepBetween float64, maxSleepBetween float64, exponentialBackoffBase float64, attempt uint, backoffScalingFactor float64, + defaultBackoffWithoutJitterHelper func(minSleepBetween float64, maxSleepBetween float64, exponentialBackoffBase float64, attempt uint) float64) float64 { + var sleepTime = math.Pow(exponentialBackoffBase, float64(attempt-1)) + if sleepTime < minSleepBetween { + sleepTime = minSleepBetween + } + if sleepTime > maxSleepBetween { + sleepTime = maxSleepBetween + } + sleepTime = sleepTime * backoffScalingFactor + defaultSleepTime := defaultBackoffWithoutJitterHelper(minSleepBetween, maxSleepBetween, exponentialBackoffBase, attempt) + if defaultSleepTime > sleepTime { + sleepTime = defaultSleepTime + } + return sleepTime +} + +// GetMaximumCumulativeEventuallyConsistentBackoffWithoutJitter calculates the maximum backoff without jitter, according to the retry +// policy and taking eventually consistent effects into account, if every retry attempt is made. +func GetMaximumCumulativeEventuallyConsistentBackoffWithoutJitter(policy RetryPolicy) time.Duration { + return getMaximumCumulativeEventuallyConsistentBackoffWithoutJitterHelper(policy.MinSleepBetween, policy.MaxSleepBetween, policy.ExponentialBackoffBase, + policy.MaximumNumberAttempts, policy.MaximumCumulativeBackoffWithoutJitter, + func(minSleepBetween float64, maxSleepBetween float64, exponentialBackoffBase float64, attempt uint) float64 { + rp := policy.NonEventuallyConsistentPolicy + return getBackoffWithoutJitterHelper(rp.MinSleepBetween, rp.MaxSleepBetween, rp.ExponentialBackoffBase, attempt) + }) +} + +func getMaximumCumulativeEventuallyConsistentBackoffWithoutJitterHelper(minSleepBetween float64, maxSleepBetween float64, exponentialBackoffBase float64, MaximumNumberAttempts uint, + MaximumCumulativeBackoffWithoutJitter float64, + defaultBackoffWithoutJitterHelper func(minSleepBetween float64, maxSleepBetween float64, exponentialBackoffBase float64, attempt uint) float64) time.Duration { + if MaximumNumberAttempts == 0 { + // unlimited + return time.Duration(MaximumCumulativeBackoffWithoutJitter) * time.Second + } + + var cumulative time.Duration = 0 + // use a one-based counter because it's easier to think about operation retry in terms of attempt numbering + for currentOperationAttempt := uint(1); currentOperationAttempt < MaximumNumberAttempts; currentOperationAttempt++ { + cumulative += time.Duration(getEventuallyConsistentBackoffWithoutJitterHelper(minSleepBetween, maxSleepBetween, exponentialBackoffBase, currentOperationAttempt, 1.0, defaultBackoffWithoutJitterHelper)*1000) * time.Millisecond + } + return cumulative +} + +func returnSamePolicy(policy RetryPolicy) (RetryPolicy, *time.Time, float64) { + // we're returning the end of window time nonetheless, even though the default non-eventual consistency (EC) + // retry policy doesn't use it; this is useful in case developers wants to write an EC-aware retry policy + // on their own + return policy, EcContext.GetEndOfWindow(), 1.0 +} + +// NoRetryPolicy is a helper method that assembles and returns a return policy that indicates an operation should +// never be retried (the operation is performed exactly once). +func NoRetryPolicy() RetryPolicy { + dontRetryOperation := func(OCIOperationResponse) bool { return false } + zeroNextDuration := func(OCIOperationResponse) time.Duration { return 0 * time.Second } + return newRetryPolicyWithOptionsNoDefault( + WithMaximumNumberAttempts(1), + WithShouldRetryOperation(dontRetryOperation), + WithNextDuration(zeroNextDuration), + withMinSleepBetween(0.0*time.Second), + withMaxSleepBetween(0.0*time.Second), + withExponentialBackoffBase(0.0), + withDeterminePolicyToUse(returnSamePolicy), + withNonEventuallyConsistentPolicy(nil)) +} + +// DefaultShouldRetryOperation is the function that should be used for RetryPolicy.ShouldRetryOperation when +// not taking eventual consistency into account. +func DefaultShouldRetryOperation(r OCIOperationResponse) bool { + if r.Error == nil && 199 < r.Response.HTTPResponse().StatusCode && r.Response.HTTPResponse().StatusCode < 300 { + // success + return false + } + return IsErrorRetryableByDefault(r.Error) +} + +// DefaultRetryPolicy is a helper method that assembles and returns a return policy that is defined to be a default one +// The default retry policy will retry on (409, IncorrectState), (429, TooManyRequests) and any 5XX errors except (501, MethodNotImplemented) +// The default retry behavior is using exponential backoff with jitter, the maximum wait time is 30s plus 1s jitter +// The maximum cumulative backoff after all 8 attempts have been made is about 1.5 minutes. +// It will also retry on errors affected by eventual consistency. +// The eventual consistency retry behavior is using exponential backoff with jitter, the maximum wait time is 45s plus 1s jitter +// Under eventual consistency, the maximum cumulative backoff after all 9 attempts have been made is about 4 minutes. +func DefaultRetryPolicy() RetryPolicy { + return NewRetryPolicyWithOptions( + ReplaceWithValuesFromRetryPolicy(DefaultRetryPolicyWithoutEventualConsistency()), + WithEventualConsistency()) +} + +// DefaultRetryPolicyWithoutEventualConsistency is a helper method that assembles and returns a return policy that is defined to be a default one +// The default retry policy will retry on (409, IncorrectState), (429, TooManyRequests) and any 5XX errors except (501, MethodNotImplemented) +// It will not retry on errors affected by eventual consistency. +// The default retry behavior is using exponential backoff with jitter, the maximum wait time is 30s plus 1s jitter +func DefaultRetryPolicyWithoutEventualConsistency() RetryPolicy { + exponentialBackoffWithJitter := func(r OCIOperationResponse) time.Duration { + sleepTime := getBackoffWithoutJitterHelper(defaultMinSleepBetween, defaultMaxSleepBetween, defaultExponentialBackoffBase, r.AttemptNumber) + nextDuration := time.Duration(1000.0*(sleepTime+rand.Float64())) * time.Millisecond + return nextDuration + } + return newRetryPolicyWithOptionsNoDefault( + WithMaximumNumberAttempts(defaultMaximumNumberAttempts), + WithShouldRetryOperation(DefaultShouldRetryOperation), + WithNextDuration(exponentialBackoffWithJitter), + withMinSleepBetween(defaultMinSleepBetween*time.Second), + withMaxSleepBetween(defaultMaxSleepBetween*time.Second), + withExponentialBackoffBase(defaultExponentialBackoffBase), + withDeterminePolicyToUse(returnSamePolicy), + withNonEventuallyConsistentPolicy(nil)) +} + +// EventuallyConsistentShouldRetryOperation is the function that should be used for RetryPolicy.ShouldRetryOperation when +// taking eventual consistency into account +func EventuallyConsistentShouldRetryOperation(r OCIOperationResponse) bool { + if r.Error == nil && 199 < r.Response.HTTPResponse().StatusCode && r.Response.HTTPResponse().StatusCode < 300 { + // success + Debugln(fmt.Sprintf("EC.ShouldRetryOperation, status = %v, 2xx, returning false", r.Response.HTTPResponse().StatusCode)) + return false + } + if IsErrorRetryableByDefault(r.Error) { + return true + } + // not retryable by default + if _, ok := IsServiceError(r.Error); ok { + now := EcContext.timeNowProvider() + if r.EndOfWindowTime == nil || r.EndOfWindowTime.Before(now) { + // either no eventually consistent effects, or they have disappeared by now + Debugln(fmt.Sprintf("EC.ShouldRetryOperation, no EC or in the past, returning false: endOfWindowTime = %v, now = %v", r.EndOfWindowTime, now)) + return false + } + // there were eventually consistent effects present at the time of the first request + // and they could still affect the retries + if IsErrorAffectedByEventualConsistency(r.Error) { + // and it's one of the three affected error codes + Debugln(fmt.Sprintf("EC.ShouldRetryOperation, affected by EC, EC is present: endOfWindowTime = %v, now = %v", r.EndOfWindowTime, now)) + return true + } + return false + } + + return false +} + +// EventuallyConsistentRetryPolicy is a helper method that assembles and returns a return policy that is defined to be a default one +// plus dealing with errors affected by eventual consistency. +// The default retry behavior is using exponential backoff with jitter, the maximum wait time is 45s plus 1s jitter +func EventuallyConsistentRetryPolicy(nonEventuallyConsistentPolicy RetryPolicy) RetryPolicy { + if nonEventuallyConsistentPolicy.NonEventuallyConsistentPolicy != nil { + // already deals with eventual consistency + return nonEventuallyConsistentPolicy + } + exponentialBackoffWithJitter := func(r OCIOperationResponse) time.Duration { + sleepTime := getEventuallyConsistentBackoffWithoutJitterHelper(ecMinSleepBetween, ecMaxSleepBetween, ecExponentialBackoffBase, r.AttemptNumber, r.BackoffScalingFactor, + func(minSleepBetween float64, maxSleepBetween float64, exponentialBackoffBase float64, attempt uint) float64 { + rp := nonEventuallyConsistentPolicy + return getBackoffWithoutJitterHelper(rp.MinSleepBetween, rp.MaxSleepBetween, rp.ExponentialBackoffBase, attempt) + }) + nextDuration := time.Duration(1000.0*(sleepTime+rand.Float64())) * time.Millisecond + Debugln(fmt.Sprintf("EventuallyConsistentRetryPolicy.NextDuration for attempt %v: sleepTime = %.1fs, nextDuration = %v", r.AttemptNumber, sleepTime, nextDuration)) + return nextDuration + } + returnModifiedPolicy := func(policy RetryPolicy) (RetryPolicy, *time.Time, float64) { return determinePolicyToUse(policy) } + nonEventuallyConsistentPolicyCopy := newRetryPolicyWithOptionsNoDefault( + ReplaceWithValuesFromRetryPolicy(nonEventuallyConsistentPolicy)) + return newRetryPolicyWithOptionsNoDefault( + WithMaximumNumberAttempts(ecMaximumNumberAttempts), + WithShouldRetryOperation(EventuallyConsistentShouldRetryOperation), + WithNextDuration(exponentialBackoffWithJitter), + withMinSleepBetween(ecMinSleepBetween*time.Second), + withMaxSleepBetween(ecMaxSleepBetween*time.Second), + withExponentialBackoffBase(ecExponentialBackoffBase), + withDeterminePolicyToUse(returnModifiedPolicy), + withNonEventuallyConsistentPolicy(&nonEventuallyConsistentPolicyCopy)) +} + +// NewRetryPolicy is a helper method for assembling a Retry Policy object. It does not handle eventual consistency, so as to not break existing code. +// If you want to handle eventual consistency, the simplest way to do that is to replace the code +// NewRetryPolicy(a, r, n) +// with the code +// NewRetryPolicyWithOptions( +// WithMaximumNumberAttempts(a), +// WithFixedBackoff(fb) // fb is the fixed backoff duration +// WithShouldRetryOperation(r)) +// or +// NewRetryPolicyWithOptions( +// WithMaximumNumberAttempts(a), +// WithExponentialBackoff(mb, e) // mb is the maximum backoff duration, and e is the base for exponential backoff, e.g. 2.0 +// WithShouldRetryOperation(r)) +// or, if a == 0 (the maximum number of attempts is unlimited) +// NewRetryPolicyWithEventualConsistencyUnlimitedAttempts(a, r, n, mcb) // mcb is the maximum cumulative backoff duration without jitter +func NewRetryPolicy(attempts uint, retryOperation func(OCIOperationResponse) bool, nextDuration func(OCIOperationResponse) time.Duration) RetryPolicy { + return NewRetryPolicyWithOptions( + ReplaceWithValuesFromRetryPolicy(DefaultRetryPolicyWithoutEventualConsistency()), + WithMaximumNumberAttempts(attempts), + WithShouldRetryOperation(retryOperation), + WithNextDuration(nextDuration), + ) +} + +// NewRetryPolicyWithEventualConsistencyUnlimitedAttempts is a helper method for assembling a Retry Policy object. +// It does handle eventual consistency, but other than that, it is very similar to NewRetryPolicy. +// NewRetryPolicyWithEventualConsistency does not support limited attempts, use NewRetryPolicyWithEventualConsistency instead. +func NewRetryPolicyWithEventualConsistencyUnlimitedAttempts(attempts uint, retryOperation func(OCIOperationResponse) bool, nextDuration func(OCIOperationResponse) time.Duration, + maximumCumulativeBackoffWithoutJitter time.Duration) (*RetryPolicy, error) { + + if attempts != 0 { + return nil, fmt.Errorf("NewRetryPolicyWithEventualConsistencyUnlimitedAttempts cannot be used with attempts != 0 (limited attempts), use NewRetryPolicyWithEventualConsistency instead") + } + + result := NewRetryPolicyWithOptions( + ReplaceWithValuesFromRetryPolicy(DefaultRetryPolicyWithoutEventualConsistency()), + WithUnlimitedAttempts(maximumCumulativeBackoffWithoutJitter), + WithShouldRetryOperation(retryOperation), + WithNextDuration(nextDuration), + ) + return &result, nil +} + +// NewRetryPolicyWithOptions is a helper method for assembling a Retry Policy object. +// It starts out with the values returned by DefaultRetryPolicy() and does handle eventual consistency, +// unless you replace all options set using ReplaceWithValuesFromRetryPolicy(DefaultRetryPolicyWithoutEventualConsistency()). +func NewRetryPolicyWithOptions(opts ...RetryPolicyOption) RetryPolicy { + rp := &RetryPolicy{} + + // start with the default retry policy + ReplaceWithValuesFromRetryPolicy(DefaultRetryPolicyWithoutEventualConsistency())(rp) + WithEventualConsistency()(rp) + + // then allow changing values + for _, opt := range opts { + opt(rp) + } + + if rp.DeterminePolicyToUse == nil { + rp.DeterminePolicyToUse = returnSamePolicy + } + + return *rp +} + +// newRetryPolicyWithOptionsNoDefault is a helper method for assembling a Retry Policy object. +// Contrary to newRetryPolicyWithOptions, it does not start out with the values returned by +// DefaultRetryPolicy(). +func newRetryPolicyWithOptionsNoDefault(opts ...RetryPolicyOption) RetryPolicy { + rp := &RetryPolicy{} + + // then allow changing values + for _, opt := range opts { + opt(rp) + } + + if rp.DeterminePolicyToUse == nil { + rp.DeterminePolicyToUse = returnSamePolicy + } + + return *rp +} + +// WithMaximumNumberAttempts is the option for NewRetryPolicyWithOptions that sets the maximum number of attempts. +func WithMaximumNumberAttempts(attempts uint) RetryPolicyOption { + // this is the RetryPolicyOption function type + return func(rp *RetryPolicy) { + rp.MaximumNumberAttempts = attempts + } +} + +// WithUnlimitedAttempts is the option for NewRetryPolicyWithOptions that sets unlimited number of attempts, +// but it needs to set a MaximumCumulativeBackoffWithoutJitter duration. +// If you use WithUnlimitedAttempts, you should set your own NextDuration function using WithNextDuration. +func WithUnlimitedAttempts(maximumCumulativeBackoffWithoutJitter time.Duration) RetryPolicyOption { + // this is the RetryPolicyOption function type + return func(rp *RetryPolicy) { + rp.MaximumNumberAttempts = 0 + rp.MaximumCumulativeBackoffWithoutJitter = float64(maximumCumulativeBackoffWithoutJitter / time.Second) + } +} + +// WithShouldRetryOperation is the option for NewRetryPolicyWithOptions that sets the function that checks +// whether retries should be performed. +func WithShouldRetryOperation(retryOperation func(OCIOperationResponse) bool) RetryPolicyOption { + // this is the RetryPolicyOption function type + return func(rp *RetryPolicy) { + rp.ShouldRetryOperation = retryOperation + } +} + +// WithNextDuration is the option for NewRetryPolicyWithOptions that sets the function for computing the next +// backoff duration. +// It is preferred to use WithFixedBackoff or WithExponentialBackoff instead. +func WithNextDuration(nextDuration func(OCIOperationResponse) time.Duration) RetryPolicyOption { + // this is the RetryPolicyOption function type + return func(rp *RetryPolicy) { + rp.NextDuration = nextDuration + } +} + +// withMinSleepBetween is the option for NewRetryPolicyWithOptions that sets the minimum backoff duration. +func withMinSleepBetween(minSleepBetween time.Duration) RetryPolicyOption { + // this is the RetryPolicyOption function type + return func(rp *RetryPolicy) { + rp.MinSleepBetween = float64(minSleepBetween / time.Second) + } +} + +// withMaxsSleepBetween is the option for NewRetryPolicyWithOptions that sets the maximum backoff duration. +func withMaxSleepBetween(maxSleepBetween time.Duration) RetryPolicyOption { + // this is the RetryPolicyOption function type + return func(rp *RetryPolicy) { + rp.MaxSleepBetween = float64(maxSleepBetween / time.Second) + } +} + +// withExponentialBackoffBase is the option for NewRetryPolicyWithOptions that sets the base for the +// exponential backoff +func withExponentialBackoffBase(base float64) RetryPolicyOption { + // this is the RetryPolicyOption function type + return func(rp *RetryPolicy) { + rp.ExponentialBackoffBase = base + } +} + +// withDeterminePolicyToUse is the option for NewRetryPolicyWithOptions that sets the function that +// determines which polich should be used and if eventual consistency should be considered +func withDeterminePolicyToUse(determinePolicyToUse func(policy RetryPolicy) (RetryPolicy, *time.Time, float64)) RetryPolicyOption { + // this is the RetryPolicyOption function type + return func(rp *RetryPolicy) { + rp.DeterminePolicyToUse = determinePolicyToUse + } +} + +// withNonEventuallyConsistentPolicy is the option for NewRetryPolicyWithOptions that sets the fallback +// strategy if eventual consistency should not be considered +func withNonEventuallyConsistentPolicy(nonEventuallyConsistentPolicy *RetryPolicy) RetryPolicyOption { + // this is the RetryPolicyOption function type + return func(rp *RetryPolicy) { + // we want a non-EC policy for NonEventuallyConsistentPolicy; make sure that NonEventuallyConsistentPolicy is nil + for nonEventuallyConsistentPolicy != nil && nonEventuallyConsistentPolicy.NonEventuallyConsistentPolicy != nil { + nonEventuallyConsistentPolicy = nonEventuallyConsistentPolicy.NonEventuallyConsistentPolicy + } + rp.NonEventuallyConsistentPolicy = nonEventuallyConsistentPolicy + } +} + +// WithExponentialBackoff is an option for NewRetryPolicyWithOptions that sets the exponential backoff base, +// minimum and maximum sleep between attempts, and next duration function. +// Therefore, WithExponentialBackoff is a combination of WithNextDuration, withMinSleepBetween, withMaxSleepBetween, +// and withExponentialBackoffBase. +func WithExponentialBackoff(newMaxSleepBetween time.Duration, newExponentialBackoffBase float64) RetryPolicyOption { + exponentialBackoffWithJitter := func(r OCIOperationResponse) time.Duration { + sleepTime := getBackoffWithoutJitterHelper(defaultMinSleepBetween, newMaxSleepBetween.Seconds(), newExponentialBackoffBase, r.AttemptNumber) + nextDuration := time.Duration(1000.0*(sleepTime+rand.Float64())) * time.Millisecond + Debugln(fmt.Sprintf("NextDuration for attempt %v: sleepTime = %.1fs, nextDuration = %v", r.AttemptNumber, sleepTime, nextDuration)) + return nextDuration + } + + // this is the RetryPolicyOption function type + return func(rp *RetryPolicy) { + withMinSleepBetween(0)(rp) + withMaxSleepBetween(newMaxSleepBetween)(rp) + withExponentialBackoffBase(newExponentialBackoffBase)(rp) + WithNextDuration(exponentialBackoffWithJitter)(rp) + } +} + +// WithFixedBackoff is an option for NewRetryPolicyWithOptions that sets the backoff to always be exactly the same value. There is no jitter either. +// Therefore, WithFixedBackoff is a combination of WithNextDuration, withMinSleepBetween, withMaxSleepBetween, and withExponentialBackoffBase. +func WithFixedBackoff(newSleepBetween time.Duration) RetryPolicyOption { + fixedBackoffWithoutJitter := func(r OCIOperationResponse) time.Duration { + nextDuration := newSleepBetween + Debugln(fmt.Sprintf("NextDuration for attempt %v: nextDuration = %v", r.AttemptNumber, nextDuration)) + return nextDuration + } + + // this is the RetryPolicyOption function type + return func(rp *RetryPolicy) { + withMinSleepBetween(newSleepBetween)(rp) + withMaxSleepBetween(newSleepBetween)(rp) + withExponentialBackoffBase(1.0)(rp) + WithNextDuration(fixedBackoffWithoutJitter)(rp) + } +} + +// WithEventualConsistency is the option for NewRetryPolicyWithOptions that enables considering eventual backoff for the policy. +func WithEventualConsistency() RetryPolicyOption { + // this is the RetryPolicyOption function type + return func(rp *RetryPolicy) { + copy := RetryPolicy{ + MaximumNumberAttempts: rp.MaximumNumberAttempts, + ShouldRetryOperation: rp.ShouldRetryOperation, + NextDuration: rp.NextDuration, + MinSleepBetween: rp.MinSleepBetween, + MaxSleepBetween: rp.MaxSleepBetween, + ExponentialBackoffBase: rp.ExponentialBackoffBase, + DeterminePolicyToUse: rp.DeterminePolicyToUse, + NonEventuallyConsistentPolicy: rp.NonEventuallyConsistentPolicy, + } + ecrp := EventuallyConsistentRetryPolicy(copy) + rp.MaximumNumberAttempts = ecrp.MaximumNumberAttempts + rp.ShouldRetryOperation = ecrp.ShouldRetryOperation + rp.NextDuration = ecrp.NextDuration + rp.MinSleepBetween = ecrp.MinSleepBetween + rp.MaxSleepBetween = ecrp.MaxSleepBetween + rp.ExponentialBackoffBase = ecrp.ExponentialBackoffBase + rp.DeterminePolicyToUse = ecrp.DeterminePolicyToUse + rp.NonEventuallyConsistentPolicy = ecrp.NonEventuallyConsistentPolicy + } +} + +// WithConditionalOption is an option for NewRetryPolicyWithOptions that enables or disables another option. +func WithConditionalOption(enabled bool, otherOption RetryPolicyOption) RetryPolicyOption { + // this is the RetryPolicyOption function type + return func(rp *RetryPolicy) { + if enabled { + otherOption(rp) + } + } +} + +// ReplaceWithValuesFromRetryPolicy is an option for NewRetryPolicyWithOptions that copies over all settings from another RetryPolicy +func ReplaceWithValuesFromRetryPolicy(other RetryPolicy) RetryPolicyOption { + // this is the RetryPolicyOption function type + return func(rp *RetryPolicy) { + rp.MaximumNumberAttempts = other.MaximumNumberAttempts + rp.ShouldRetryOperation = other.ShouldRetryOperation + rp.NextDuration = other.NextDuration + rp.MinSleepBetween = other.MinSleepBetween + rp.MaxSleepBetween = other.MaxSleepBetween + rp.ExponentialBackoffBase = other.ExponentialBackoffBase + rp.DeterminePolicyToUse = other.DeterminePolicyToUse + rp.NonEventuallyConsistentPolicy = other.NonEventuallyConsistentPolicy + rp.MaximumCumulativeBackoffWithoutJitter = other.MaximumCumulativeBackoffWithoutJitter + } +} + +// shouldContinueIssuingRequests returns true if we should continue retrying a request, based on the current attempt +// number and the maximum number of attempts specified, or false otherwise. +func shouldContinueIssuingRequests(current, maximum uint) bool { + return maximum == UnlimitedNumAttemptsValue || current <= maximum +} + +// RetryToken generates a retry token that must be included on any request passed to the Retry method. +func RetryToken() string { + alphanumericChars := []rune("abcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ") + retryToken := make([]rune, generatedRetryTokenLength) + for i := range retryToken { + retryToken[i] = alphanumericChars[rand.Intn(len(alphanumericChars))] + } + return string(retryToken) +} + +func determinePolicyToUse(policy RetryPolicy) (RetryPolicy, *time.Time, float64) { + initialAttemptTime := EcContext.timeNowProvider() + var useDefaultTimingInstead = true + var endOfWindowTime = (*time.Time)(nil) + var backoffScalingFactor = 1.0 + var policyToUse RetryPolicy = policy + + eowt := EcContext.GetEndOfWindow() + if eowt != nil { + // there was an eventually consistent request + if eowt.After(initialAttemptTime) { + // and the eventually consistent effects may still be present + endOfWindowTime = eowt + // if the time between now and the end of the window is less than the time we normally would retry, use the default timing + durationToEndOfWindow := endOfWindowTime.Sub(initialAttemptTime) + maxCumulativeBackoffWithoutJitter := GetMaximumCumulativeBackoffWithoutJitter(*policy.NonEventuallyConsistentPolicy) + Debugln(fmt.Sprintf("durationToEndOfWindow = %v, maxCumulativeBackoffWithoutJitter = %v", durationToEndOfWindow, maxCumulativeBackoffWithoutJitter)) + if durationToEndOfWindow > maxCumulativeBackoffWithoutJitter { + // the end of the eventually consistent window is later than when default retries would end + // do not use default timing + maximumCumulativeBackoffWithoutJitter := GetMaximumCumulativeEventuallyConsistentBackoffWithoutJitter(policy) + backoffScalingFactor = float64(durationToEndOfWindow) / float64(maximumCumulativeBackoffWithoutJitter) + useDefaultTimingInstead = false + Debugln(fmt.Sprintf("Use eventually consistent timing, durationToEndOfWindow = %v, maximumCumulativeBackoffWithoutJitter = %v, backoffScalingFactor = %.2f", + durationToEndOfWindow, maximumCumulativeBackoffWithoutJitter, backoffScalingFactor)) + } else { + Debugln(fmt.Sprintf("Use default timing, end of EC window is sooner than default retries")) + } + } else { + useDefaultTimingInstead = false + policyToUse = *policy.NonEventuallyConsistentPolicy + Debugln(fmt.Sprintf("Use default timing and strategy, end of EC window is in the past")) + } + } else { + useDefaultTimingInstead = false + policyToUse = *policy.NonEventuallyConsistentPolicy + Debugln(fmt.Sprintf("Use default timing and strategy, no EC window set")) + } + + if useDefaultTimingInstead { + // use timing from defaultRetryPolicy, but whether to retry from the policy that was passed into this request + policyToUse = NewRetryPolicyWithOptions( + ReplaceWithValuesFromRetryPolicy(*policy.NonEventuallyConsistentPolicy), + WithShouldRetryOperation(policy.ShouldRetryOperation)) + } + + return policyToUse, endOfWindowTime, backoffScalingFactor +} + +// Retry is a package-level operation that executes the retryable request using the specified operation and retry policy. +func Retry(ctx context.Context, request OCIRetryableRequest, operation OCIOperation, policy RetryPolicy) (OCIResponse, error) { + type retrierResult struct { + response OCIResponse + err error + } + + var response OCIResponse + var err error + retrierChannel := make(chan retrierResult) + + validated, validateError := policy.validate() + if !validated { + return nil, validateError + } + + initialAttemptTime := time.Now() + + go func() { + + // Deal with panics more graciously + defer func() { + if r := recover(); r != nil { + stackBuffer := make([]byte, 1024) + bytesWritten := runtime.Stack(stackBuffer, false) + stack := string(stackBuffer[:bytesWritten]) + error := fmt.Errorf("panicked while retrying operation. Panic was: %s\nStack: %s", r, stack) + Debugln(error) + retrierChannel <- retrierResult{nil, error} + } + }() + + // if request body is binary request body and seekable, save the current position + var curPos int64 = 0 + isSeekable := false + rsc, isBinaryRequest := request.BinaryRequestBody() + if rsc != nil && rsc.rc != nil { + defer rsc.rc.Close() + } + if policy.MaximumNumberAttempts != uint(1) { + if rsc.Seekable() { + isSeekable = true + curPos, _ = rsc.Seek(0, io.SeekCurrent) + } + } + + // some legacy code constructing RetryPolicy instances directly may not have set DeterminePolicyToUse. + // In that case, just assume that it doesn't handle eventual consistency. + if policy.DeterminePolicyToUse == nil { + policy.DeterminePolicyToUse = returnSamePolicy + } + + // this determines which policy to use, when the eventual consistency window ends, and what the backoff + // scaling factor should be + policyToUse, endOfWindowTime, backoffScalingFactor := policy.DeterminePolicyToUse(policy) + Debugln(fmt.Sprintf("Retry policy to use: %v", policyToUse)) + + extraHeaders := make(map[string]string) + + if policy.MaximumNumberAttempts == 1 { + extraHeaders[requestHeaderOpcClientRetries] = "false" + } else { + extraHeaders[requestHeaderOpcClientRetries] = "true" + } + + // use a one-based counter because it's easier to think about operation retry in terms of attempt numbering + for currentOperationAttempt := uint(1); shouldContinueIssuingRequests(currentOperationAttempt, policyToUse.MaximumNumberAttempts); currentOperationAttempt++ { + Debugln(fmt.Sprintf("operation attempt #%v", currentOperationAttempt)) + // rewind body once needed + if isSeekable { + rsc = NewOCIReadSeekCloser(rsc.rc) + rsc.Seek(curPos, io.SeekStart) + } + response, err = operation(ctx, request, rsc, extraHeaders) + + operationResponse := NewOCIOperationResponseExtended(response, err, currentOperationAttempt, endOfWindowTime, backoffScalingFactor, initialAttemptTime) + + if !policyToUse.ShouldRetryOperation(operationResponse) { + // we should NOT retry operation based on response and/or error => return + retrierChannel <- retrierResult{response, err} + return + } + + // if the request body type is stream, requested retry but doesn't resettable, throw error and stop retrying + if isBinaryRequest && !isSeekable { + retrierChannel <- retrierResult{response, NonSeekableRequestRetryFailure{err}} + return + } + + duration := policyToUse.NextDuration(operationResponse) + //The following condition is kept for backwards compatibility reasons + if deadline, ok := ctx.Deadline(); ok && EcContext.timeNowProvider().Add(duration).After(deadline) { + // we want to retry the operation, but the policy is telling us to wait for a duration that exceeds + // the specified overall deadline for the operation => instead of waiting for however long that + // time period is and then aborting, abort now and save the cycles + retrierChannel <- retrierResult{response, DeadlineExceededByBackoff} + return + } + Debugln(fmt.Sprintf("waiting %v before retrying operation", duration)) + // sleep before retrying the operation + <-time.After(duration) + } + + retrierChannel <- retrierResult{response, err} + }() + + select { + case <-ctx.Done(): + return response, ctx.Err() + case result := <-retrierChannel: + return result.response, result.err + } +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/common/version.go b/vendor/github.com/oracle/oci-go-sdk/v54/common/version.go new file mode 100644 index 000000000..782ca99ab --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/common/version.go @@ -0,0 +1,37 @@ +// Copyright (c) 2016, 2018, 2020, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated by go generate; DO NOT EDIT + +package common + +import ( + "bytes" + "fmt" + "sync" +) + +const ( + major = "54" + minor = "0" + patch = "0" + tag = "" +) + +var once sync.Once +var version string + +// Version returns semantic version of the sdk +func Version() string { + once.Do(func() { + ver := fmt.Sprintf("%s.%s.%s", major, minor, patch) + verBuilder := bytes.NewBufferString(ver) + if tag != "" && tag != "-" { + _, err := verBuilder.WriteString(tag) + if err != nil { + verBuilder = bytes.NewBufferString(ver) + } + } + version = verBuilder.String() + }) + return version +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/accept_shielded_integrity_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/accept_shielded_integrity_policy_request_response.go new file mode 100644 index 000000000..a871d4bb6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/accept_shielded_integrity_policy_request_response.go @@ -0,0 +1,83 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AcceptShieldedIntegrityPolicyRequest wrapper for the AcceptShieldedIntegrityPolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AcceptShieldedIntegrityPolicy.go.html to see an example of how to use AcceptShieldedIntegrityPolicyRequest. +type AcceptShieldedIntegrityPolicyRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance. + InstanceId *string `mandatory:"true" contributesTo:"path" name:"instanceId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AcceptShieldedIntegrityPolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AcceptShieldedIntegrityPolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AcceptShieldedIntegrityPolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AcceptShieldedIntegrityPolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AcceptShieldedIntegrityPolicyResponse wrapper for the AcceptShieldedIntegrityPolicy operation +type AcceptShieldedIntegrityPolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response AcceptShieldedIntegrityPolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AcceptShieldedIntegrityPolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_distribution_statement_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_distribution_statement_details.go new file mode 100644 index 000000000..aaf8e70de --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_distribution_statement_details.go @@ -0,0 +1,95 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AddDrgRouteDistributionStatementDetails Details used to add a route distribution statement. +type AddDrgRouteDistributionStatementDetails struct { + + // The action is applied only if all of the match criteria is met. + // If there are no match criteria in a statement, match ALL is implied. + MatchCriteria []DrgRouteDistributionMatchCriteria `mandatory:"true" json:"matchCriteria"` + + // Accept: import/export the route "as is" + Action AddDrgRouteDistributionStatementDetailsActionEnum `mandatory:"true" json:"action"` + + // This field is used to specify the priority of each statement in a route distribution. + // The priority will be represented as a number between 0 and 65535 where a lower number + // indicates a higher priority. When a route is processed, statements are applied in the order + // defined by their priority. The first matching rule dictates the action that will be taken + // on the route. + Priority *int `mandatory:"true" json:"priority"` +} + +func (m AddDrgRouteDistributionStatementDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *AddDrgRouteDistributionStatementDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + MatchCriteria []drgroutedistributionmatchcriteria `json:"matchCriteria"` + Action AddDrgRouteDistributionStatementDetailsActionEnum `json:"action"` + Priority *int `json:"priority"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.MatchCriteria = make([]DrgRouteDistributionMatchCriteria, len(model.MatchCriteria)) + for i, n := range model.MatchCriteria { + nn, e = n.UnmarshalPolymorphicJSON(n.JsonData) + if e != nil { + return e + } + if nn != nil { + m.MatchCriteria[i] = nn.(DrgRouteDistributionMatchCriteria) + } else { + m.MatchCriteria[i] = nil + } + } + + m.Action = model.Action + + m.Priority = model.Priority + + return +} + +// AddDrgRouteDistributionStatementDetailsActionEnum Enum with underlying type: string +type AddDrgRouteDistributionStatementDetailsActionEnum string + +// Set of constants representing the allowable values for AddDrgRouteDistributionStatementDetailsActionEnum +const ( + AddDrgRouteDistributionStatementDetailsActionAccept AddDrgRouteDistributionStatementDetailsActionEnum = "ACCEPT" +) + +var mappingAddDrgRouteDistributionStatementDetailsAction = map[string]AddDrgRouteDistributionStatementDetailsActionEnum{ + "ACCEPT": AddDrgRouteDistributionStatementDetailsActionAccept, +} + +// GetAddDrgRouteDistributionStatementDetailsActionEnumValues Enumerates the set of values for AddDrgRouteDistributionStatementDetailsActionEnum +func GetAddDrgRouteDistributionStatementDetailsActionEnumValues() []AddDrgRouteDistributionStatementDetailsActionEnum { + values := make([]AddDrgRouteDistributionStatementDetailsActionEnum, 0) + for _, v := range mappingAddDrgRouteDistributionStatementDetailsAction { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_distribution_statements_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_distribution_statements_details.go new file mode 100644 index 000000000..0f370ccf7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_distribution_statements_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AddDrgRouteDistributionStatementsDetails Details request to add statements to a route distribution. +type AddDrgRouteDistributionStatementsDetails struct { + + // The collection of route distribution statements to insert into the route distribution. + Statements []AddDrgRouteDistributionStatementDetails `mandatory:"true" json:"statements"` +} + +func (m AddDrgRouteDistributionStatementsDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_distribution_statements_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_distribution_statements_request_response.go new file mode 100644 index 000000000..1b852d6a3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_distribution_statements_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AddDrgRouteDistributionStatementsRequest wrapper for the AddDrgRouteDistributionStatements operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AddDrgRouteDistributionStatements.go.html to see an example of how to use AddDrgRouteDistributionStatementsRequest. +type AddDrgRouteDistributionStatementsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route distribution. + DrgRouteDistributionId *string `mandatory:"true" contributesTo:"path" name:"drgRouteDistributionId"` + + // Request with one or more route distribution statements to be inserted into the route distribution. + AddDrgRouteDistributionStatementsDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AddDrgRouteDistributionStatementsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AddDrgRouteDistributionStatementsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AddDrgRouteDistributionStatementsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AddDrgRouteDistributionStatementsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AddDrgRouteDistributionStatementsResponse wrapper for the AddDrgRouteDistributionStatements operation +type AddDrgRouteDistributionStatementsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []DrgRouteDistributionStatement instance + Items []DrgRouteDistributionStatement `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response AddDrgRouteDistributionStatementsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AddDrgRouteDistributionStatementsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_rule_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_rule_details.go new file mode 100644 index 000000000..01a353cf3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_rule_details.go @@ -0,0 +1,63 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AddDrgRouteRuleDetails Details needed when adding a DRG route rule. +type AddDrgRouteRuleDetails struct { + + // Type of destination for the rule. Required if `direction` = `EGRESS`. + // Allowed values: + // * `CIDR_BLOCK`: If the rule's `destination` is an IP address range in CIDR notation. + DestinationType AddDrgRouteRuleDetailsDestinationTypeEnum `mandatory:"true" json:"destinationType"` + + // This is the range of IP addresses used for matching when routing + // traffic. Only CIDR_BLOCK values are allowed. + // Potential values: + // * IP address range in CIDR notation. This can be an IPv4 or IPv6 CIDR. For example: `192.168.1.0/24` + // or `2001:0db8:0123:45::/56`. + Destination *string `mandatory:"true" json:"destination"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the next hop DRG attachment. The next hop DRG attachment is responsible + // for reaching the network destination. + NextHopDrgAttachmentId *string `mandatory:"true" json:"nextHopDrgAttachmentId"` +} + +func (m AddDrgRouteRuleDetails) String() string { + return common.PointerString(m) +} + +// AddDrgRouteRuleDetailsDestinationTypeEnum Enum with underlying type: string +type AddDrgRouteRuleDetailsDestinationTypeEnum string + +// Set of constants representing the allowable values for AddDrgRouteRuleDetailsDestinationTypeEnum +const ( + AddDrgRouteRuleDetailsDestinationTypeCidrBlock AddDrgRouteRuleDetailsDestinationTypeEnum = "CIDR_BLOCK" +) + +var mappingAddDrgRouteRuleDetailsDestinationType = map[string]AddDrgRouteRuleDetailsDestinationTypeEnum{ + "CIDR_BLOCK": AddDrgRouteRuleDetailsDestinationTypeCidrBlock, +} + +// GetAddDrgRouteRuleDetailsDestinationTypeEnumValues Enumerates the set of values for AddDrgRouteRuleDetailsDestinationTypeEnum +func GetAddDrgRouteRuleDetailsDestinationTypeEnumValues() []AddDrgRouteRuleDetailsDestinationTypeEnum { + values := make([]AddDrgRouteRuleDetailsDestinationTypeEnum, 0) + for _, v := range mappingAddDrgRouteRuleDetailsDestinationType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_rules_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_rules_details.go new file mode 100644 index 000000000..de543e4bc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_rules_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AddDrgRouteRulesDetails Details used in a request to add static routes to a DRG route table. +type AddDrgRouteRulesDetails struct { + + // The collection of static rules used to insert routes into the DRG route table. + RouteRules []AddDrgRouteRuleDetails `mandatory:"false" json:"routeRules"` +} + +func (m AddDrgRouteRulesDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_rules_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_rules_request_response.go new file mode 100644 index 000000000..f5fca000c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_drg_route_rules_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AddDrgRouteRulesRequest wrapper for the AddDrgRouteRules operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AddDrgRouteRules.go.html to see an example of how to use AddDrgRouteRulesRequest. +type AddDrgRouteRulesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG route table. + DrgRouteTableId *string `mandatory:"true" contributesTo:"path" name:"drgRouteTableId"` + + // Request for one or more route rules to be inserted into the DRG route table. + AddDrgRouteRulesDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AddDrgRouteRulesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AddDrgRouteRulesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AddDrgRouteRulesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AddDrgRouteRulesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AddDrgRouteRulesResponse wrapper for the AddDrgRouteRules operation +type AddDrgRouteRulesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []DrgRouteRule instance + Items []DrgRouteRule `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response AddDrgRouteRulesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AddDrgRouteRulesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_image_shape_compatibility_entry_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_image_shape_compatibility_entry_details.go new file mode 100644 index 000000000..2410679dc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_image_shape_compatibility_entry_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AddImageShapeCompatibilityEntryDetails Image shape compatibility details. +type AddImageShapeCompatibilityEntryDetails struct { + MemoryConstraints *ImageMemoryConstraints `mandatory:"false" json:"memoryConstraints"` + + OcpuConstraints *ImageOcpuConstraints `mandatory:"false" json:"ocpuConstraints"` +} + +func (m AddImageShapeCompatibilityEntryDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_image_shape_compatibility_entry_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_image_shape_compatibility_entry_request_response.go new file mode 100644 index 000000000..b9bbead1f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_image_shape_compatibility_entry_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AddImageShapeCompatibilityEntryRequest wrapper for the AddImageShapeCompatibilityEntry operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AddImageShapeCompatibilityEntry.go.html to see an example of how to use AddImageShapeCompatibilityEntryRequest. +type AddImageShapeCompatibilityEntryRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the image. + ImageId *string `mandatory:"true" contributesTo:"path" name:"imageId"` + + // Shape name. + ShapeName *string `mandatory:"true" contributesTo:"path" name:"shapeName"` + + // Image shape compatibility details + AddImageShapeCompatibilityEntryDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AddImageShapeCompatibilityEntryRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AddImageShapeCompatibilityEntryRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AddImageShapeCompatibilityEntryRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AddImageShapeCompatibilityEntryRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AddImageShapeCompatibilityEntryResponse wrapper for the AddImageShapeCompatibilityEntry operation +type AddImageShapeCompatibilityEntryResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ImageShapeCompatibilityEntry instance + ImageShapeCompatibilityEntry `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response AddImageShapeCompatibilityEntryResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AddImageShapeCompatibilityEntryResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_ipv6_vcn_cidr_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_ipv6_vcn_cidr_request_response.go new file mode 100644 index 000000000..b45efeb66 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_ipv6_vcn_cidr_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AddIpv6VcnCidrRequest wrapper for the AddIpv6VcnCidr operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AddIpv6VcnCidr.go.html to see an example of how to use AddIpv6VcnCidrRequest. +type AddIpv6VcnCidrRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"true" contributesTo:"path" name:"vcnId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AddIpv6VcnCidrRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AddIpv6VcnCidrRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AddIpv6VcnCidrRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AddIpv6VcnCidrRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AddIpv6VcnCidrResponse wrapper for the AddIpv6VcnCidr operation +type AddIpv6VcnCidrResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response AddIpv6VcnCidrResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AddIpv6VcnCidrResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_network_security_group_security_rules_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_network_security_group_security_rules_details.go new file mode 100644 index 000000000..efdc3633a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_network_security_group_security_rules_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AddNetworkSecurityGroupSecurityRulesDetails The representation of AddNetworkSecurityGroupSecurityRulesDetails +type AddNetworkSecurityGroupSecurityRulesDetails struct { + + // The NSG security rules to add. + SecurityRules []AddSecurityRuleDetails `mandatory:"false" json:"securityRules"` +} + +func (m AddNetworkSecurityGroupSecurityRulesDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_network_security_group_security_rules_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_network_security_group_security_rules_request_response.go new file mode 100644 index 000000000..ae0951f06 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_network_security_group_security_rules_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AddNetworkSecurityGroupSecurityRulesRequest wrapper for the AddNetworkSecurityGroupSecurityRules operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AddNetworkSecurityGroupSecurityRules.go.html to see an example of how to use AddNetworkSecurityGroupSecurityRulesRequest. +type AddNetworkSecurityGroupSecurityRulesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network security group. + NetworkSecurityGroupId *string `mandatory:"true" contributesTo:"path" name:"networkSecurityGroupId"` + + // Request with one or more security rules to be associated with the network security group. + AddNetworkSecurityGroupSecurityRulesDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AddNetworkSecurityGroupSecurityRulesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AddNetworkSecurityGroupSecurityRulesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AddNetworkSecurityGroupSecurityRulesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AddNetworkSecurityGroupSecurityRulesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AddNetworkSecurityGroupSecurityRulesResponse wrapper for the AddNetworkSecurityGroupSecurityRules operation +type AddNetworkSecurityGroupSecurityRulesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The AddedNetworkSecurityGroupSecurityRules instance + AddedNetworkSecurityGroupSecurityRules `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response AddNetworkSecurityGroupSecurityRulesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AddNetworkSecurityGroupSecurityRulesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_public_ip_pool_capacity_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_public_ip_pool_capacity_details.go new file mode 100644 index 000000000..330bba7ff --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_public_ip_pool_capacity_details.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AddPublicIpPoolCapacityDetails The information used to add capacity to an IP pool. +type AddPublicIpPoolCapacityDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the `ByoipRange` resource to which the CIDR block belongs. + ByoipRangeId *string `mandatory:"true" json:"byoipRangeId"` + + // The CIDR block to add to the public IP pool. It could be all of the CIDR block identified in `byoipRangeId`, or a subrange. + // Example: `10.0.1.0/24` + CidrBlock *string `mandatory:"true" json:"cidrBlock"` +} + +func (m AddPublicIpPoolCapacityDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_public_ip_pool_capacity_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_public_ip_pool_capacity_request_response.go new file mode 100644 index 000000000..c52c58bf1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_public_ip_pool_capacity_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AddPublicIpPoolCapacityRequest wrapper for the AddPublicIpPoolCapacity operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AddPublicIpPoolCapacity.go.html to see an example of how to use AddPublicIpPoolCapacityRequest. +type AddPublicIpPoolCapacityRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the public IP pool. + PublicIpPoolId *string `mandatory:"true" contributesTo:"path" name:"publicIpPoolId"` + + // Byoip Range prefix and a cidr from it + AddPublicIpPoolCapacityDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AddPublicIpPoolCapacityRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AddPublicIpPoolCapacityRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AddPublicIpPoolCapacityRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AddPublicIpPoolCapacityRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AddPublicIpPoolCapacityResponse wrapper for the AddPublicIpPoolCapacity operation +type AddPublicIpPoolCapacityResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The PublicIpPool instance + PublicIpPool `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response AddPublicIpPoolCapacityResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AddPublicIpPoolCapacityResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_security_rule_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_security_rule_details.go new file mode 100644 index 000000000..a51725be3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_security_rule_details.go @@ -0,0 +1,172 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AddSecurityRuleDetails A rule for allowing inbound (INGRESS) or outbound (EGRESS) IP packets. +type AddSecurityRuleDetails struct { + + // Direction of the security rule. Set to `EGRESS` for rules to allow outbound IP packets, + // or `INGRESS` for rules to allow inbound IP packets. + Direction AddSecurityRuleDetailsDirectionEnum `mandatory:"true" json:"direction"` + + // The transport protocol. Specify either `all` or an IPv4 protocol number as + // defined in + // Protocol Numbers (http://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml). + // Options are supported only for ICMP ("1"), TCP ("6"), UDP ("17"), and ICMPv6 ("58"). + Protocol *string `mandatory:"true" json:"protocol"` + + // An optional description of your choice for the rule. Avoid entering confidential information. + Description *string `mandatory:"false" json:"description"` + + // Conceptually, this is the range of IP addresses that a packet originating from the instance + // can go to. + // Allowed values: + // * An IP address range in CIDR notation. For example: `192.168.1.0/24` or `2001:0db8:0123:45::/56` + // IPv6 addressing is supported for all commercial and government regions. See + // IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // * The `cidrBlock` value for a Service, if you're + // setting up a security rule for traffic destined for a particular `Service` through + // a service gateway. For example: `oci-phx-objectstorage`. + // * The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of a NetworkSecurityGroup in the same + // VCN. The value can be the NSG that the rule belongs to if the rule's intent is to control + // traffic between VNICs in the same NSG. + Destination *string `mandatory:"false" json:"destination"` + + // Type of destination for the rule. Required if `direction` = `EGRESS`. + // Allowed values: + // * `CIDR_BLOCK`: If the rule's `destination` is an IP address range in CIDR notation. + // * `SERVICE_CIDR_BLOCK`: If the rule's `destination` is the `cidrBlock` value for a + // Service (the rule is for traffic destined for a + // particular `Service` through a service gateway). + // * `NETWORK_SECURITY_GROUP`: If the rule's `destination` is the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of a + // NetworkSecurityGroup. + DestinationType AddSecurityRuleDetailsDestinationTypeEnum `mandatory:"false" json:"destinationType,omitempty"` + + IcmpOptions *IcmpOptions `mandatory:"false" json:"icmpOptions"` + + // A stateless rule allows traffic in one direction. Remember to add a corresponding + // stateless rule in the other direction if you need to support bidirectional traffic. For + // example, if egress traffic allows TCP destination port 80, there should be an ingress + // rule to allow TCP source port 80. Defaults to false, which means the rule is stateful + // and a corresponding rule is not necessary for bidirectional traffic. + IsStateless *bool `mandatory:"false" json:"isStateless"` + + // Conceptually, this is the range of IP addresses that a packet coming into the instance + // can come from. + // Allowed values: + // * An IP address range in CIDR notation. For example: `192.168.1.0/24` or `2001:0db8:0123:45::/56` + // IPv6 addressing is supported for all commercial and government regions. See + // IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // * The `cidrBlock` value for a Service, if you're + // setting up a security rule for traffic coming from a particular `Service` through + // a service gateway. For example: `oci-phx-objectstorage`. + // * The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of a NetworkSecurityGroup in the same + // VCN. The value can be the NSG that the rule belongs to if the rule's intent is to control + // traffic between VNICs in the same NSG. + Source *string `mandatory:"false" json:"source"` + + // Type of source for the rule. Required if `direction` = `INGRESS`. + // * `CIDR_BLOCK`: If the rule's `source` is an IP address range in CIDR notation. + // * `SERVICE_CIDR_BLOCK`: If the rule's `source` is the `cidrBlock` value for a + // Service (the rule is for traffic coming from a + // particular `Service` through a service gateway). + // * `NETWORK_SECURITY_GROUP`: If the rule's `source` is the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of a + // NetworkSecurityGroup. + SourceType AddSecurityRuleDetailsSourceTypeEnum `mandatory:"false" json:"sourceType,omitempty"` + + TcpOptions *TcpOptions `mandatory:"false" json:"tcpOptions"` + + UdpOptions *UdpOptions `mandatory:"false" json:"udpOptions"` +} + +func (m AddSecurityRuleDetails) String() string { + return common.PointerString(m) +} + +// AddSecurityRuleDetailsDestinationTypeEnum Enum with underlying type: string +type AddSecurityRuleDetailsDestinationTypeEnum string + +// Set of constants representing the allowable values for AddSecurityRuleDetailsDestinationTypeEnum +const ( + AddSecurityRuleDetailsDestinationTypeCidrBlock AddSecurityRuleDetailsDestinationTypeEnum = "CIDR_BLOCK" + AddSecurityRuleDetailsDestinationTypeServiceCidrBlock AddSecurityRuleDetailsDestinationTypeEnum = "SERVICE_CIDR_BLOCK" + AddSecurityRuleDetailsDestinationTypeNetworkSecurityGroup AddSecurityRuleDetailsDestinationTypeEnum = "NETWORK_SECURITY_GROUP" +) + +var mappingAddSecurityRuleDetailsDestinationType = map[string]AddSecurityRuleDetailsDestinationTypeEnum{ + "CIDR_BLOCK": AddSecurityRuleDetailsDestinationTypeCidrBlock, + "SERVICE_CIDR_BLOCK": AddSecurityRuleDetailsDestinationTypeServiceCidrBlock, + "NETWORK_SECURITY_GROUP": AddSecurityRuleDetailsDestinationTypeNetworkSecurityGroup, +} + +// GetAddSecurityRuleDetailsDestinationTypeEnumValues Enumerates the set of values for AddSecurityRuleDetailsDestinationTypeEnum +func GetAddSecurityRuleDetailsDestinationTypeEnumValues() []AddSecurityRuleDetailsDestinationTypeEnum { + values := make([]AddSecurityRuleDetailsDestinationTypeEnum, 0) + for _, v := range mappingAddSecurityRuleDetailsDestinationType { + values = append(values, v) + } + return values +} + +// AddSecurityRuleDetailsDirectionEnum Enum with underlying type: string +type AddSecurityRuleDetailsDirectionEnum string + +// Set of constants representing the allowable values for AddSecurityRuleDetailsDirectionEnum +const ( + AddSecurityRuleDetailsDirectionEgress AddSecurityRuleDetailsDirectionEnum = "EGRESS" + AddSecurityRuleDetailsDirectionIngress AddSecurityRuleDetailsDirectionEnum = "INGRESS" +) + +var mappingAddSecurityRuleDetailsDirection = map[string]AddSecurityRuleDetailsDirectionEnum{ + "EGRESS": AddSecurityRuleDetailsDirectionEgress, + "INGRESS": AddSecurityRuleDetailsDirectionIngress, +} + +// GetAddSecurityRuleDetailsDirectionEnumValues Enumerates the set of values for AddSecurityRuleDetailsDirectionEnum +func GetAddSecurityRuleDetailsDirectionEnumValues() []AddSecurityRuleDetailsDirectionEnum { + values := make([]AddSecurityRuleDetailsDirectionEnum, 0) + for _, v := range mappingAddSecurityRuleDetailsDirection { + values = append(values, v) + } + return values +} + +// AddSecurityRuleDetailsSourceTypeEnum Enum with underlying type: string +type AddSecurityRuleDetailsSourceTypeEnum string + +// Set of constants representing the allowable values for AddSecurityRuleDetailsSourceTypeEnum +const ( + AddSecurityRuleDetailsSourceTypeCidrBlock AddSecurityRuleDetailsSourceTypeEnum = "CIDR_BLOCK" + AddSecurityRuleDetailsSourceTypeServiceCidrBlock AddSecurityRuleDetailsSourceTypeEnum = "SERVICE_CIDR_BLOCK" + AddSecurityRuleDetailsSourceTypeNetworkSecurityGroup AddSecurityRuleDetailsSourceTypeEnum = "NETWORK_SECURITY_GROUP" +) + +var mappingAddSecurityRuleDetailsSourceType = map[string]AddSecurityRuleDetailsSourceTypeEnum{ + "CIDR_BLOCK": AddSecurityRuleDetailsSourceTypeCidrBlock, + "SERVICE_CIDR_BLOCK": AddSecurityRuleDetailsSourceTypeServiceCidrBlock, + "NETWORK_SECURITY_GROUP": AddSecurityRuleDetailsSourceTypeNetworkSecurityGroup, +} + +// GetAddSecurityRuleDetailsSourceTypeEnumValues Enumerates the set of values for AddSecurityRuleDetailsSourceTypeEnum +func GetAddSecurityRuleDetailsSourceTypeEnumValues() []AddSecurityRuleDetailsSourceTypeEnum { + values := make([]AddSecurityRuleDetailsSourceTypeEnum, 0) + for _, v := range mappingAddSecurityRuleDetailsSourceType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_vcn_cidr_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_vcn_cidr_details.go new file mode 100644 index 000000000..ddec68686 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_vcn_cidr_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AddVcnCidrDetails Details for adding a CIDR block to a VCN. +type AddVcnCidrDetails struct { + + // The CIDR block to add. + CidrBlock *string `mandatory:"true" json:"cidrBlock"` +} + +func (m AddVcnCidrDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/add_vcn_cidr_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_vcn_cidr_request_response.go new file mode 100644 index 000000000..e19533635 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/add_vcn_cidr_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AddVcnCidrRequest wrapper for the AddVcnCidr operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AddVcnCidr.go.html to see an example of how to use AddVcnCidrRequest. +type AddVcnCidrRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"true" contributesTo:"path" name:"vcnId"` + + // Details object for deleting a VCN CIDR. + AddVcnCidrDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AddVcnCidrRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AddVcnCidrRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AddVcnCidrRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AddVcnCidrRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AddVcnCidrResponse wrapper for the AddVcnCidr operation +type AddVcnCidrResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response AddVcnCidrResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AddVcnCidrResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/added_network_security_group_security_rules.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/added_network_security_group_security_rules.go new file mode 100644 index 000000000..1ecd14248 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/added_network_security_group_security_rules.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AddedNetworkSecurityGroupSecurityRules The representation of AddedNetworkSecurityGroupSecurityRules +type AddedNetworkSecurityGroupSecurityRules struct { + + // The NSG security rules that were added. + SecurityRules []SecurityRule `mandatory:"false" json:"securityRules"` +} + +func (m AddedNetworkSecurityGroupSecurityRules) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/advertise_byoip_range_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/advertise_byoip_range_request_response.go new file mode 100644 index 000000000..ebbfe76d5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/advertise_byoip_range_request_response.go @@ -0,0 +1,71 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AdvertiseByoipRangeRequest wrapper for the AdvertiseByoipRange operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AdvertiseByoipRange.go.html to see an example of how to use AdvertiseByoipRangeRequest. +type AdvertiseByoipRangeRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the `ByoipRange` resource containing the BYOIP CIDR block. + ByoipRangeId *string `mandatory:"true" contributesTo:"path" name:"byoipRangeId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AdvertiseByoipRangeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AdvertiseByoipRangeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AdvertiseByoipRangeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AdvertiseByoipRangeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AdvertiseByoipRangeResponse wrapper for the AdvertiseByoipRange operation +type AdvertiseByoipRangeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response AdvertiseByoipRangeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AdvertiseByoipRangeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/allowed_ike_ip_sec_parameters.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/allowed_ike_ip_sec_parameters.go new file mode 100644 index 000000000..08e5715ce --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/allowed_ike_ip_sec_parameters.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AllowedIkeIpSecParameters Allowed IKE IPSec Parameters +type AllowedIkeIpSecParameters struct { + AllowedPhaseOneParameters *AllowedPhaseOneParameters `mandatory:"true" json:"allowedPhaseOneParameters"` + + AllowedPhaseTwoParameters *AllowedPhaseTwoParameters `mandatory:"true" json:"allowedPhaseTwoParameters"` + + DefaultPhaseOneParameters *DefaultPhaseOneParameters `mandatory:"true" json:"defaultPhaseOneParameters"` + + DefaultPhaseTwoParameters *DefaultPhaseTwoParameters `mandatory:"true" json:"defaultPhaseTwoParameters"` +} + +func (m AllowedIkeIpSecParameters) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/allowed_phase_one_parameters.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/allowed_phase_one_parameters.go new file mode 100644 index 000000000..76d6fb530 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/allowed_phase_one_parameters.go @@ -0,0 +1,35 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AllowedPhaseOneParameters Phase One Parameters +type AllowedPhaseOneParameters struct { + + // Phase One Encryption Algorithms + EncryptionAlgorithms []string `mandatory:"false" json:"encryptionAlgorithms"` + + // Phase One Authentication Algorithms + AuthenticationAlgorithms []string `mandatory:"false" json:"authenticationAlgorithms"` + + // DH Groups + DhGroups []string `mandatory:"false" json:"dhGroups"` +} + +func (m AllowedPhaseOneParameters) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/allowed_phase_two_parameters.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/allowed_phase_two_parameters.go new file mode 100644 index 000000000..359507baa --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/allowed_phase_two_parameters.go @@ -0,0 +1,35 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AllowedPhaseTwoParameters Phase Two Parameters +type AllowedPhaseTwoParameters struct { + + // Phase Two Encryption Algorithms + EncryptionAlgorithms []string `mandatory:"false" json:"encryptionAlgorithms"` + + // Phase Two Authentication Algorithms + AuthenticationAlgorithms []string `mandatory:"false" json:"authenticationAlgorithms"` + + // PFS DH Groups + PfsDhGroups []string `mandatory:"false" json:"pfsDhGroups"` +} + +func (m AllowedPhaseTwoParameters) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_milan_bm_launch_instance_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_milan_bm_launch_instance_platform_config.go new file mode 100644 index 000000000..e11f3187b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_milan_bm_launch_instance_platform_config.go @@ -0,0 +1,96 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AmdMilanBmLaunchInstancePlatformConfig The platform configuration used when launching a bare metal instance with an E4 shape +// (the AMD Milan platform). +type AmdMilanBmLaunchInstancePlatformConfig struct { + + // Whether Secure Boot is enabled on the instance. + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + + // Whether the Measured Boot feature is enabled on the instance. + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` + + // The number of NUMA nodes per socket (NPS). + NumaNodesPerSocket AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum `mandatory:"false" json:"numaNodesPerSocket,omitempty"` +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m AmdMilanBmLaunchInstancePlatformConfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m AmdMilanBmLaunchInstancePlatformConfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m AmdMilanBmLaunchInstancePlatformConfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m AmdMilanBmLaunchInstancePlatformConfig) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m AmdMilanBmLaunchInstancePlatformConfig) MarshalJSON() (buff []byte, e error) { + type MarshalTypeAmdMilanBmLaunchInstancePlatformConfig AmdMilanBmLaunchInstancePlatformConfig + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeAmdMilanBmLaunchInstancePlatformConfig + }{ + "AMD_MILAN_BM", + (MarshalTypeAmdMilanBmLaunchInstancePlatformConfig)(m), + } + + return json.Marshal(&s) +} + +// AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum Enum with underlying type: string +type AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum string + +// Set of constants representing the allowable values for AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum +const ( + AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps0 AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum = "NPS0" + AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps1 AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum = "NPS1" + AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps2 AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum = "NPS2" + AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps4 AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum = "NPS4" +) + +var mappingAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocket = map[string]AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum{ + "NPS0": AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps0, + "NPS1": AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps1, + "NPS2": AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps2, + "NPS4": AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps4, +} + +// GetAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnumValues Enumerates the set of values for AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum +func GetAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnumValues() []AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum { + values := make([]AmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum, 0) + for _, v := range mappingAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocket { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_milan_bm_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_milan_bm_platform_config.go new file mode 100644 index 000000000..fc136676c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_milan_bm_platform_config.go @@ -0,0 +1,96 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AmdMilanBmPlatformConfig The platform configuration of a bare metal instance that uses an E4 shape +// (the AMD Milan platform). +type AmdMilanBmPlatformConfig struct { + + // Whether Secure Boot is enabled on the instance. + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + + // Whether the Measured Boot feature is enabled on the instance. + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` + + // The number of NUMA nodes per socket (NPS). + NumaNodesPerSocket AmdMilanBmPlatformConfigNumaNodesPerSocketEnum `mandatory:"false" json:"numaNodesPerSocket,omitempty"` +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m AmdMilanBmPlatformConfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m AmdMilanBmPlatformConfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m AmdMilanBmPlatformConfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m AmdMilanBmPlatformConfig) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m AmdMilanBmPlatformConfig) MarshalJSON() (buff []byte, e error) { + type MarshalTypeAmdMilanBmPlatformConfig AmdMilanBmPlatformConfig + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeAmdMilanBmPlatformConfig + }{ + "AMD_MILAN_BM", + (MarshalTypeAmdMilanBmPlatformConfig)(m), + } + + return json.Marshal(&s) +} + +// AmdMilanBmPlatformConfigNumaNodesPerSocketEnum Enum with underlying type: string +type AmdMilanBmPlatformConfigNumaNodesPerSocketEnum string + +// Set of constants representing the allowable values for AmdMilanBmPlatformConfigNumaNodesPerSocketEnum +const ( + AmdMilanBmPlatformConfigNumaNodesPerSocketNps0 AmdMilanBmPlatformConfigNumaNodesPerSocketEnum = "NPS0" + AmdMilanBmPlatformConfigNumaNodesPerSocketNps1 AmdMilanBmPlatformConfigNumaNodesPerSocketEnum = "NPS1" + AmdMilanBmPlatformConfigNumaNodesPerSocketNps2 AmdMilanBmPlatformConfigNumaNodesPerSocketEnum = "NPS2" + AmdMilanBmPlatformConfigNumaNodesPerSocketNps4 AmdMilanBmPlatformConfigNumaNodesPerSocketEnum = "NPS4" +) + +var mappingAmdMilanBmPlatformConfigNumaNodesPerSocket = map[string]AmdMilanBmPlatformConfigNumaNodesPerSocketEnum{ + "NPS0": AmdMilanBmPlatformConfigNumaNodesPerSocketNps0, + "NPS1": AmdMilanBmPlatformConfigNumaNodesPerSocketNps1, + "NPS2": AmdMilanBmPlatformConfigNumaNodesPerSocketNps2, + "NPS4": AmdMilanBmPlatformConfigNumaNodesPerSocketNps4, +} + +// GetAmdMilanBmPlatformConfigNumaNodesPerSocketEnumValues Enumerates the set of values for AmdMilanBmPlatformConfigNumaNodesPerSocketEnum +func GetAmdMilanBmPlatformConfigNumaNodesPerSocketEnumValues() []AmdMilanBmPlatformConfigNumaNodesPerSocketEnum { + values := make([]AmdMilanBmPlatformConfigNumaNodesPerSocketEnum, 0) + for _, v := range mappingAmdMilanBmPlatformConfigNumaNodesPerSocket { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_rome_bm_launch_instance_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_rome_bm_launch_instance_platform_config.go new file mode 100644 index 000000000..47e88af71 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_rome_bm_launch_instance_platform_config.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AmdRomeBmLaunchInstancePlatformConfig The platform configuration used when launching a bare metal instance with the AMD Rome platform. +type AmdRomeBmLaunchInstancePlatformConfig struct { + + // Whether Secure Boot is enabled on the instance. + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + + // Whether the Measured Boot feature is enabled on the instance. + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m AmdRomeBmLaunchInstancePlatformConfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m AmdRomeBmLaunchInstancePlatformConfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m AmdRomeBmLaunchInstancePlatformConfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m AmdRomeBmLaunchInstancePlatformConfig) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m AmdRomeBmLaunchInstancePlatformConfig) MarshalJSON() (buff []byte, e error) { + type MarshalTypeAmdRomeBmLaunchInstancePlatformConfig AmdRomeBmLaunchInstancePlatformConfig + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeAmdRomeBmLaunchInstancePlatformConfig + }{ + "AMD_ROME_BM", + (MarshalTypeAmdRomeBmLaunchInstancePlatformConfig)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_rome_bm_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_rome_bm_platform_config.go new file mode 100644 index 000000000..0f426bb44 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_rome_bm_platform_config.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AmdRomeBmPlatformConfig The platform configuration of a bare metal instance that uses the AMD Rome platform. +type AmdRomeBmPlatformConfig struct { + + // Whether Secure Boot is enabled on the instance. + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + + // Whether the Measured Boot feature is enabled on the instance. + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m AmdRomeBmPlatformConfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m AmdRomeBmPlatformConfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m AmdRomeBmPlatformConfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m AmdRomeBmPlatformConfig) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m AmdRomeBmPlatformConfig) MarshalJSON() (buff []byte, e error) { + type MarshalTypeAmdRomeBmPlatformConfig AmdRomeBmPlatformConfig + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeAmdRomeBmPlatformConfig + }{ + "AMD_ROME_BM", + (MarshalTypeAmdRomeBmPlatformConfig)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_vm_launch_instance_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_vm_launch_instance_platform_config.go new file mode 100644 index 000000000..77590bc5b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_vm_launch_instance_platform_config.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AmdVmLaunchInstancePlatformConfig The platform configuration used when launching a virtual machine instance with the AMD platform. +type AmdVmLaunchInstancePlatformConfig struct { + + // Whether Secure Boot is enabled on the instance. + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + + // Whether the Measured Boot feature is enabled on the instance. + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m AmdVmLaunchInstancePlatformConfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m AmdVmLaunchInstancePlatformConfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m AmdVmLaunchInstancePlatformConfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m AmdVmLaunchInstancePlatformConfig) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m AmdVmLaunchInstancePlatformConfig) MarshalJSON() (buff []byte, e error) { + type MarshalTypeAmdVmLaunchInstancePlatformConfig AmdVmLaunchInstancePlatformConfig + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeAmdVmLaunchInstancePlatformConfig + }{ + "AMD_VM", + (MarshalTypeAmdVmLaunchInstancePlatformConfig)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_vm_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_vm_platform_config.go new file mode 100644 index 000000000..8fa153199 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/amd_vm_platform_config.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AmdVmPlatformConfig The platform configuration of a virtual machine instance that uses the AMD platform. +type AmdVmPlatformConfig struct { + + // Whether Secure Boot is enabled on the instance. + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + + // Whether the Measured Boot feature is enabled on the instance. + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m AmdVmPlatformConfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m AmdVmPlatformConfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m AmdVmPlatformConfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m AmdVmPlatformConfig) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m AmdVmPlatformConfig) MarshalJSON() (buff []byte, e error) { + type MarshalTypeAmdVmPlatformConfig AmdVmPlatformConfig + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeAmdVmPlatformConfig + }{ + "AMD_VM", + (MarshalTypeAmdVmPlatformConfig)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing.go new file mode 100644 index 000000000..5f7e1cdf3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing.go @@ -0,0 +1,52 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AppCatalogListing Listing details. +type AppCatalogListing struct { + + // Listing's contact URL. + ContactUrl *string `mandatory:"false" json:"contactUrl"` + + // Description of the listing. + Description *string `mandatory:"false" json:"description"` + + // The OCID of the listing. + ListingId *string `mandatory:"false" json:"listingId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Date and time the listing was published, in RFC3339 (https://tools.ietf.org/html/rfc3339) format. + // Example: `2018-03-20T12:32:53.532Z` + TimePublished *common.SDKTime `mandatory:"false" json:"timePublished"` + + // Publisher's logo URL. + PublisherLogoUrl *string `mandatory:"false" json:"publisherLogoUrl"` + + // Name of the publisher who published this listing. + PublisherName *string `mandatory:"false" json:"publisherName"` + + // Summary of the listing. + Summary *string `mandatory:"false" json:"summary"` +} + +func (m AppCatalogListing) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_resource_version.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_resource_version.go new file mode 100644 index 000000000..7701f73a3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_resource_version.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AppCatalogListingResourceVersion Listing Resource Version +type AppCatalogListingResourceVersion struct { + + // The OCID of the listing this resource version belongs to. + ListingId *string `mandatory:"false" json:"listingId"` + + // Date and time the listing resource version was published, in RFC3339 (https://tools.ietf.org/html/rfc3339) format. + // Example: `2018-03-20T12:32:53.532Z` + TimePublished *common.SDKTime `mandatory:"false" json:"timePublished"` + + // OCID of the listing resource. + ListingResourceId *string `mandatory:"false" json:"listingResourceId"` + + // Resource Version. + ListingResourceVersion *string `mandatory:"false" json:"listingResourceVersion"` + + // List of regions that this listing resource version is available. + // For information about Regions, see + // Regions (https://docs.cloud.oracle.comGeneral/Concepts/regions.htm). + // Example: `["us-ashburn-1", "us-phoenix-1"]` + AvailableRegions []string `mandatory:"false" json:"availableRegions"` + + // Array of shapes compatible with this resource. + // You may enumerate all available shapes by calling listShapes. + // Example: `["VM.Standard1.1", "VM.Standard1.2"]` + CompatibleShapes []string `mandatory:"false" json:"compatibleShapes"` + + // List of accessible ports for instances launched with this listing resource version. + AccessiblePorts []int `mandatory:"false" json:"accessiblePorts"` + + // Allowed actions for the listing resource. + AllowedActions []AppCatalogListingResourceVersionAllowedActionsEnum `mandatory:"false" json:"allowedActions,omitempty"` +} + +func (m AppCatalogListingResourceVersion) String() string { + return common.PointerString(m) +} + +// AppCatalogListingResourceVersionAllowedActionsEnum Enum with underlying type: string +type AppCatalogListingResourceVersionAllowedActionsEnum string + +// Set of constants representing the allowable values for AppCatalogListingResourceVersionAllowedActionsEnum +const ( + AppCatalogListingResourceVersionAllowedActionsSnapshot AppCatalogListingResourceVersionAllowedActionsEnum = "SNAPSHOT" + AppCatalogListingResourceVersionAllowedActionsBootVolumeDetach AppCatalogListingResourceVersionAllowedActionsEnum = "BOOT_VOLUME_DETACH" + AppCatalogListingResourceVersionAllowedActionsPreserveBootVolume AppCatalogListingResourceVersionAllowedActionsEnum = "PRESERVE_BOOT_VOLUME" + AppCatalogListingResourceVersionAllowedActionsSerialConsoleAccess AppCatalogListingResourceVersionAllowedActionsEnum = "SERIAL_CONSOLE_ACCESS" + AppCatalogListingResourceVersionAllowedActionsBootRecovery AppCatalogListingResourceVersionAllowedActionsEnum = "BOOT_RECOVERY" + AppCatalogListingResourceVersionAllowedActionsBackupBootVolume AppCatalogListingResourceVersionAllowedActionsEnum = "BACKUP_BOOT_VOLUME" + AppCatalogListingResourceVersionAllowedActionsCaptureConsoleHistory AppCatalogListingResourceVersionAllowedActionsEnum = "CAPTURE_CONSOLE_HISTORY" +) + +var mappingAppCatalogListingResourceVersionAllowedActions = map[string]AppCatalogListingResourceVersionAllowedActionsEnum{ + "SNAPSHOT": AppCatalogListingResourceVersionAllowedActionsSnapshot, + "BOOT_VOLUME_DETACH": AppCatalogListingResourceVersionAllowedActionsBootVolumeDetach, + "PRESERVE_BOOT_VOLUME": AppCatalogListingResourceVersionAllowedActionsPreserveBootVolume, + "SERIAL_CONSOLE_ACCESS": AppCatalogListingResourceVersionAllowedActionsSerialConsoleAccess, + "BOOT_RECOVERY": AppCatalogListingResourceVersionAllowedActionsBootRecovery, + "BACKUP_BOOT_VOLUME": AppCatalogListingResourceVersionAllowedActionsBackupBootVolume, + "CAPTURE_CONSOLE_HISTORY": AppCatalogListingResourceVersionAllowedActionsCaptureConsoleHistory, +} + +// GetAppCatalogListingResourceVersionAllowedActionsEnumValues Enumerates the set of values for AppCatalogListingResourceVersionAllowedActionsEnum +func GetAppCatalogListingResourceVersionAllowedActionsEnumValues() []AppCatalogListingResourceVersionAllowedActionsEnum { + values := make([]AppCatalogListingResourceVersionAllowedActionsEnum, 0) + for _, v := range mappingAppCatalogListingResourceVersionAllowedActions { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_resource_version_agreements.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_resource_version_agreements.go new file mode 100644 index 000000000..9d60027cf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_resource_version_agreements.go @@ -0,0 +1,45 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AppCatalogListingResourceVersionAgreements Agreements for a listing resource version. +type AppCatalogListingResourceVersionAgreements struct { + + // The OCID of the listing associated with these agreements. + ListingId *string `mandatory:"false" json:"listingId"` + + // Listing resource version associated with these agreements. + ListingResourceVersion *string `mandatory:"false" json:"listingResourceVersion"` + + // Oracle TOU link + OracleTermsOfUseLink *string `mandatory:"false" json:"oracleTermsOfUseLink"` + + // EULA link + EulaLink *string `mandatory:"false" json:"eulaLink"` + + // Date and time the agreements were retrieved, in RFC3339 (https://tools.ietf.org/html/rfc3339) format. + // Example: `2018-03-20T12:32:53.532Z` + TimeRetrieved *common.SDKTime `mandatory:"false" json:"timeRetrieved"` + + // A generated signature for this agreement retrieval operation which should be used in the create subscription call. + Signature *string `mandatory:"false" json:"signature"` +} + +func (m AppCatalogListingResourceVersionAgreements) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_resource_version_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_resource_version_summary.go new file mode 100644 index 000000000..5e4f5d4c9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_resource_version_summary.go @@ -0,0 +1,39 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AppCatalogListingResourceVersionSummary Listing Resource Version summary +type AppCatalogListingResourceVersionSummary struct { + + // The OCID of the listing this resource version belongs to. + ListingId *string `mandatory:"false" json:"listingId"` + + // Date and time the listing resource version was published, in RFC3339 (https://tools.ietf.org/html/rfc3339) format. + // Example: `2018-03-20T12:32:53.532Z` + TimePublished *common.SDKTime `mandatory:"false" json:"timePublished"` + + // OCID of the listing resource. + ListingResourceId *string `mandatory:"false" json:"listingResourceId"` + + // Resource Version. + ListingResourceVersion *string `mandatory:"false" json:"listingResourceVersion"` +} + +func (m AppCatalogListingResourceVersionSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_summary.go new file mode 100644 index 000000000..59b9fbedf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_listing_summary.go @@ -0,0 +1,39 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AppCatalogListingSummary A summary of a listing. +type AppCatalogListingSummary struct { + + // the region free ocid of the listing resource. + ListingId *string `mandatory:"false" json:"listingId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The short summary for the listing. + Summary *string `mandatory:"false" json:"summary"` + + // The name of the publisher who published this listing. + PublisherName *string `mandatory:"false" json:"publisherName"` +} + +func (m AppCatalogListingSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_subscription.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_subscription.go new file mode 100644 index 000000000..7170bb289 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_subscription.go @@ -0,0 +1,52 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AppCatalogSubscription a subscription for a listing resource version. +type AppCatalogSubscription struct { + + // Name of the publisher who published this listing. + PublisherName *string `mandatory:"false" json:"publisherName"` + + // The ocid of the listing resource. + ListingId *string `mandatory:"false" json:"listingId"` + + // Listing resource version. + ListingResourceVersion *string `mandatory:"false" json:"listingResourceVersion"` + + // Listing resource id. + ListingResourceId *string `mandatory:"false" json:"listingResourceId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The short summary to the listing. + Summary *string `mandatory:"false" json:"summary"` + + // The compartmentID of the subscription. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // Date and time at which the subscription was created, in RFC3339 (https://tools.ietf.org/html/rfc3339) format. + // Example: `2018-03-20T12:32:53.532Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` +} + +func (m AppCatalogSubscription) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_subscription_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_subscription_summary.go new file mode 100644 index 000000000..0ea20c7d7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/app_catalog_subscription_summary.go @@ -0,0 +1,52 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AppCatalogSubscriptionSummary a subscription summary for a listing resource version. +type AppCatalogSubscriptionSummary struct { + + // Name of the publisher who published this listing. + PublisherName *string `mandatory:"false" json:"publisherName"` + + // The ocid of the listing resource. + ListingId *string `mandatory:"false" json:"listingId"` + + // Listing resource version. + ListingResourceVersion *string `mandatory:"false" json:"listingResourceVersion"` + + // Listing resource id. + ListingResourceId *string `mandatory:"false" json:"listingResourceId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The short summary to the listing. + Summary *string `mandatory:"false" json:"summary"` + + // The compartmentID of the subscription. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // Date and time at which the subscription was created, in RFC3339 (https://tools.ietf.org/html/rfc3339) format. + // Example: `2018-03-20T12:32:53.532Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` +} + +func (m AppCatalogSubscriptionSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_boot_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_boot_volume_details.go new file mode 100644 index 000000000..24b2da42f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_boot_volume_details.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AttachBootVolumeDetails The representation of AttachBootVolumeDetails +type AttachBootVolumeDetails struct { + + // The OCID of the boot volume. + BootVolumeId *string `mandatory:"true" json:"bootVolumeId"` + + // The OCID of the instance. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Refer the top-level definition of encryptionInTransitType. + // The default value is NONE. + EncryptionInTransitType EncryptionInTransitTypeEnum `mandatory:"false" json:"encryptionInTransitType,omitempty"` +} + +func (m AttachBootVolumeDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_boot_volume_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_boot_volume_request_response.go new file mode 100644 index 000000000..0fbf2dd81 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_boot_volume_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AttachBootVolumeRequest wrapper for the AttachBootVolume operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AttachBootVolume.go.html to see an example of how to use AttachBootVolumeRequest. +type AttachBootVolumeRequest struct { + + // Attach boot volume request + AttachBootVolumeDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AttachBootVolumeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AttachBootVolumeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AttachBootVolumeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AttachBootVolumeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AttachBootVolumeResponse wrapper for the AttachBootVolume operation +type AttachBootVolumeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The BootVolumeAttachment instance + BootVolumeAttachment `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response AttachBootVolumeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AttachBootVolumeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_emulated_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_emulated_volume_details.go new file mode 100644 index 000000000..f0d41157c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_emulated_volume_details.go @@ -0,0 +1,93 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AttachEmulatedVolumeDetails The representation of AttachEmulatedVolumeDetails +type AttachEmulatedVolumeDetails struct { + + // The OCID of the instance. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // The OCID of the volume. + VolumeId *string `mandatory:"true" json:"volumeId"` + + // The device name. To retrieve a list of devices for a given instance, see ListInstanceDevices. + Device *string `mandatory:"false" json:"device"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Whether the attachment was created in read-only mode. + IsReadOnly *bool `mandatory:"false" json:"isReadOnly"` + + // Whether the attachment should be created in shareable mode. If an attachment + // is created in shareable mode, then other instances can attach the same volume, provided + // that they also create their attachments in shareable mode. Only certain volume types can + // be attached in shareable mode. Defaults to false if not specified. + IsShareable *bool `mandatory:"false" json:"isShareable"` +} + +//GetDevice returns Device +func (m AttachEmulatedVolumeDetails) GetDevice() *string { + return m.Device +} + +//GetDisplayName returns DisplayName +func (m AttachEmulatedVolumeDetails) GetDisplayName() *string { + return m.DisplayName +} + +//GetInstanceId returns InstanceId +func (m AttachEmulatedVolumeDetails) GetInstanceId() *string { + return m.InstanceId +} + +//GetIsReadOnly returns IsReadOnly +func (m AttachEmulatedVolumeDetails) GetIsReadOnly() *bool { + return m.IsReadOnly +} + +//GetIsShareable returns IsShareable +func (m AttachEmulatedVolumeDetails) GetIsShareable() *bool { + return m.IsShareable +} + +//GetVolumeId returns VolumeId +func (m AttachEmulatedVolumeDetails) GetVolumeId() *string { + return m.VolumeId +} + +func (m AttachEmulatedVolumeDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m AttachEmulatedVolumeDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeAttachEmulatedVolumeDetails AttachEmulatedVolumeDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeAttachEmulatedVolumeDetails + }{ + "emulated", + (MarshalTypeAttachEmulatedVolumeDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_i_scsi_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_i_scsi_volume_details.go new file mode 100644 index 000000000..7c8fac2fe --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_i_scsi_volume_details.go @@ -0,0 +1,100 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AttachIScsiVolumeDetails The representation of AttachIScsiVolumeDetails +type AttachIScsiVolumeDetails struct { + + // The OCID of the instance. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // The OCID of the volume. + VolumeId *string `mandatory:"true" json:"volumeId"` + + // The device name. To retrieve a list of devices for a given instance, see ListInstanceDevices. + Device *string `mandatory:"false" json:"device"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Whether the attachment was created in read-only mode. + IsReadOnly *bool `mandatory:"false" json:"isReadOnly"` + + // Whether the attachment should be created in shareable mode. If an attachment + // is created in shareable mode, then other instances can attach the same volume, provided + // that they also create their attachments in shareable mode. Only certain volume types can + // be attached in shareable mode. Defaults to false if not specified. + IsShareable *bool `mandatory:"false" json:"isShareable"` + + // Whether to use CHAP authentication for the volume attachment. Defaults to false. + UseChap *bool `mandatory:"false" json:"useChap"` + + // Refer the top-level definition of encryptionInTransitType. + // The default value is NONE. + EncryptionInTransitType EncryptionInTransitTypeEnum `mandatory:"false" json:"encryptionInTransitType,omitempty"` +} + +//GetDevice returns Device +func (m AttachIScsiVolumeDetails) GetDevice() *string { + return m.Device +} + +//GetDisplayName returns DisplayName +func (m AttachIScsiVolumeDetails) GetDisplayName() *string { + return m.DisplayName +} + +//GetInstanceId returns InstanceId +func (m AttachIScsiVolumeDetails) GetInstanceId() *string { + return m.InstanceId +} + +//GetIsReadOnly returns IsReadOnly +func (m AttachIScsiVolumeDetails) GetIsReadOnly() *bool { + return m.IsReadOnly +} + +//GetIsShareable returns IsShareable +func (m AttachIScsiVolumeDetails) GetIsShareable() *bool { + return m.IsShareable +} + +//GetVolumeId returns VolumeId +func (m AttachIScsiVolumeDetails) GetVolumeId() *string { + return m.VolumeId +} + +func (m AttachIScsiVolumeDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m AttachIScsiVolumeDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeAttachIScsiVolumeDetails AttachIScsiVolumeDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeAttachIScsiVolumeDetails + }{ + "iscsi", + (MarshalTypeAttachIScsiVolumeDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_instance_pool_instance_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_instance_pool_instance_details.go new file mode 100644 index 000000000..9440d5fea --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_instance_pool_instance_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AttachInstancePoolInstanceDetails An instance that is to be attached to an instance pool. +type AttachInstancePoolInstanceDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance. + InstanceId *string `mandatory:"true" json:"instanceId"` +} + +func (m AttachInstancePoolInstanceDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_instance_pool_instance_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_instance_pool_instance_request_response.go new file mode 100644 index 000000000..5f882ad1e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_instance_pool_instance_request_response.go @@ -0,0 +1,94 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AttachInstancePoolInstanceRequest wrapper for the AttachInstancePoolInstance operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AttachInstancePoolInstance.go.html to see an example of how to use AttachInstancePoolInstanceRequest. +type AttachInstancePoolInstanceRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" contributesTo:"path" name:"instancePoolId"` + + // Attach an instance to a pool + AttachInstancePoolInstanceDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AttachInstancePoolInstanceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AttachInstancePoolInstanceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AttachInstancePoolInstanceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AttachInstancePoolInstanceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AttachInstancePoolInstanceResponse wrapper for the AttachInstancePoolInstance operation +type AttachInstancePoolInstanceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstancePoolInstance instance + InstancePoolInstance `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` + + // Location of the resource. + Location *string `presentIn:"header" name:"location"` +} + +func (response AttachInstancePoolInstanceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AttachInstancePoolInstanceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_load_balancer_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_load_balancer_details.go new file mode 100644 index 000000000..b2463178e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_load_balancer_details.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AttachLoadBalancerDetails Represents a load balancer that is to be attached to an instance pool. +type AttachLoadBalancerDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the load balancer to attach to the instance pool. + LoadBalancerId *string `mandatory:"true" json:"loadBalancerId"` + + // The name of the backend set on the load balancer to add instances to. + BackendSetName *string `mandatory:"true" json:"backendSetName"` + + // The port value to use when creating the backend set. + Port *int `mandatory:"true" json:"port"` + + // Indicates which VNIC on each instance in the pool should be used to associate with the load balancer. + // Possible values are "PrimaryVnic" or the displayName of one of the secondary VNICs on the instance configuration + // that is associated with the instance pool. + VnicSelection *string `mandatory:"true" json:"vnicSelection"` +} + +func (m AttachLoadBalancerDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_load_balancer_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_load_balancer_request_response.go new file mode 100644 index 000000000..eaaad30d1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_load_balancer_request_response.go @@ -0,0 +1,92 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AttachLoadBalancerRequest wrapper for the AttachLoadBalancer operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AttachLoadBalancer.go.html to see an example of how to use AttachLoadBalancerRequest. +type AttachLoadBalancerRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" contributesTo:"path" name:"instancePoolId"` + + // Load balancer being attached + AttachLoadBalancerDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AttachLoadBalancerRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AttachLoadBalancerRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AttachLoadBalancerRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AttachLoadBalancerRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AttachLoadBalancerResponse wrapper for the AttachLoadBalancer operation +type AttachLoadBalancerResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstancePool instance + InstancePool `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response AttachLoadBalancerResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AttachLoadBalancerResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_paravirtualized_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_paravirtualized_volume_details.go new file mode 100644 index 000000000..d3b792601 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_paravirtualized_volume_details.go @@ -0,0 +1,96 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AttachParavirtualizedVolumeDetails The representation of AttachParavirtualizedVolumeDetails +type AttachParavirtualizedVolumeDetails struct { + + // The OCID of the instance. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // The OCID of the volume. + VolumeId *string `mandatory:"true" json:"volumeId"` + + // The device name. To retrieve a list of devices for a given instance, see ListInstanceDevices. + Device *string `mandatory:"false" json:"device"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Whether the attachment was created in read-only mode. + IsReadOnly *bool `mandatory:"false" json:"isReadOnly"` + + // Whether the attachment should be created in shareable mode. If an attachment + // is created in shareable mode, then other instances can attach the same volume, provided + // that they also create their attachments in shareable mode. Only certain volume types can + // be attached in shareable mode. Defaults to false if not specified. + IsShareable *bool `mandatory:"false" json:"isShareable"` + + // Whether to enable in-transit encryption for the data volume's paravirtualized attachment. The default value is false. + IsPvEncryptionInTransitEnabled *bool `mandatory:"false" json:"isPvEncryptionInTransitEnabled"` +} + +//GetDevice returns Device +func (m AttachParavirtualizedVolumeDetails) GetDevice() *string { + return m.Device +} + +//GetDisplayName returns DisplayName +func (m AttachParavirtualizedVolumeDetails) GetDisplayName() *string { + return m.DisplayName +} + +//GetInstanceId returns InstanceId +func (m AttachParavirtualizedVolumeDetails) GetInstanceId() *string { + return m.InstanceId +} + +//GetIsReadOnly returns IsReadOnly +func (m AttachParavirtualizedVolumeDetails) GetIsReadOnly() *bool { + return m.IsReadOnly +} + +//GetIsShareable returns IsShareable +func (m AttachParavirtualizedVolumeDetails) GetIsShareable() *bool { + return m.IsShareable +} + +//GetVolumeId returns VolumeId +func (m AttachParavirtualizedVolumeDetails) GetVolumeId() *string { + return m.VolumeId +} + +func (m AttachParavirtualizedVolumeDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m AttachParavirtualizedVolumeDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeAttachParavirtualizedVolumeDetails AttachParavirtualizedVolumeDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeAttachParavirtualizedVolumeDetails + }{ + "paravirtualized", + (MarshalTypeAttachParavirtualizedVolumeDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_service_determined_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_service_determined_volume_details.go new file mode 100644 index 000000000..8b7c3bca8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_service_determined_volume_details.go @@ -0,0 +1,93 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AttachServiceDeterminedVolumeDetails The representation of AttachServiceDeterminedVolumeDetails +type AttachServiceDeterminedVolumeDetails struct { + + // The OCID of the instance. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // The OCID of the volume. + VolumeId *string `mandatory:"true" json:"volumeId"` + + // The device name. To retrieve a list of devices for a given instance, see ListInstanceDevices. + Device *string `mandatory:"false" json:"device"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Whether the attachment was created in read-only mode. + IsReadOnly *bool `mandatory:"false" json:"isReadOnly"` + + // Whether the attachment should be created in shareable mode. If an attachment + // is created in shareable mode, then other instances can attach the same volume, provided + // that they also create their attachments in shareable mode. Only certain volume types can + // be attached in shareable mode. Defaults to false if not specified. + IsShareable *bool `mandatory:"false" json:"isShareable"` +} + +//GetDevice returns Device +func (m AttachServiceDeterminedVolumeDetails) GetDevice() *string { + return m.Device +} + +//GetDisplayName returns DisplayName +func (m AttachServiceDeterminedVolumeDetails) GetDisplayName() *string { + return m.DisplayName +} + +//GetInstanceId returns InstanceId +func (m AttachServiceDeterminedVolumeDetails) GetInstanceId() *string { + return m.InstanceId +} + +//GetIsReadOnly returns IsReadOnly +func (m AttachServiceDeterminedVolumeDetails) GetIsReadOnly() *bool { + return m.IsReadOnly +} + +//GetIsShareable returns IsShareable +func (m AttachServiceDeterminedVolumeDetails) GetIsShareable() *bool { + return m.IsShareable +} + +//GetVolumeId returns VolumeId +func (m AttachServiceDeterminedVolumeDetails) GetVolumeId() *string { + return m.VolumeId +} + +func (m AttachServiceDeterminedVolumeDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m AttachServiceDeterminedVolumeDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeAttachServiceDeterminedVolumeDetails AttachServiceDeterminedVolumeDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeAttachServiceDeterminedVolumeDetails + }{ + "service_determined", + (MarshalTypeAttachServiceDeterminedVolumeDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_service_id_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_service_id_request_response.go new file mode 100644 index 000000000..b63d95051 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_service_id_request_response.go @@ -0,0 +1,82 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AttachServiceIdRequest wrapper for the AttachServiceId operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AttachServiceId.go.html to see an example of how to use AttachServiceIdRequest. +type AttachServiceIdRequest struct { + + // The service gateway's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + ServiceGatewayId *string `mandatory:"true" contributesTo:"path" name:"serviceGatewayId"` + + // ServiceId of Service to be attached to a service gateway. + AttachServiceDetails ServiceIdRequestDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AttachServiceIdRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AttachServiceIdRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AttachServiceIdRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AttachServiceIdRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AttachServiceIdResponse wrapper for the AttachServiceId operation +type AttachServiceIdResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ServiceGateway instance + ServiceGateway `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response AttachServiceIdResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AttachServiceIdResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_vnic_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_vnic_details.go new file mode 100644 index 000000000..50d6d8975 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_vnic_details.go @@ -0,0 +1,41 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AttachVnicDetails The representation of AttachVnicDetails +type AttachVnicDetails struct { + CreateVnicDetails *CreateVnicDetails `mandatory:"true" json:"createVnicDetails"` + + // The OCID of the instance. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Which physical network interface card (NIC) the VNIC will use. Defaults to 0. + // Certain bare metal instance shapes have two active physical NICs (0 and 1). If + // you add a secondary VNIC to one of these instances, you can specify which NIC + // the VNIC will use. For more information, see + // Virtual Network Interface Cards (VNICs) (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingVNICs.htm). + NicIndex *int `mandatory:"false" json:"nicIndex"` +} + +func (m AttachVnicDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_vnic_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_vnic_request_response.go new file mode 100644 index 000000000..503dc693b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_vnic_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AttachVnicRequest wrapper for the AttachVnic operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AttachVnic.go.html to see an example of how to use AttachVnicRequest. +type AttachVnicRequest struct { + + // Attach VNIC details. + AttachVnicDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AttachVnicRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AttachVnicRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AttachVnicRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AttachVnicRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AttachVnicResponse wrapper for the AttachVnic operation +type AttachVnicResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VnicAttachment instance + VnicAttachment `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response AttachVnicResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AttachVnicResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_volume_details.go new file mode 100644 index 000000000..74084d457 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_volume_details.go @@ -0,0 +1,142 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AttachVolumeDetails The representation of AttachVolumeDetails +type AttachVolumeDetails interface { + + // The OCID of the instance. + GetInstanceId() *string + + // The OCID of the volume. + GetVolumeId() *string + + // The device name. To retrieve a list of devices for a given instance, see ListInstanceDevices. + GetDevice() *string + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + GetDisplayName() *string + + // Whether the attachment was created in read-only mode. + GetIsReadOnly() *bool + + // Whether the attachment should be created in shareable mode. If an attachment + // is created in shareable mode, then other instances can attach the same volume, provided + // that they also create their attachments in shareable mode. Only certain volume types can + // be attached in shareable mode. Defaults to false if not specified. + GetIsShareable() *bool +} + +type attachvolumedetails struct { + JsonData []byte + InstanceId *string `mandatory:"true" json:"instanceId"` + VolumeId *string `mandatory:"true" json:"volumeId"` + Device *string `mandatory:"false" json:"device"` + DisplayName *string `mandatory:"false" json:"displayName"` + IsReadOnly *bool `mandatory:"false" json:"isReadOnly"` + IsShareable *bool `mandatory:"false" json:"isShareable"` + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *attachvolumedetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerattachvolumedetails attachvolumedetails + s := struct { + Model Unmarshalerattachvolumedetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.InstanceId = s.Model.InstanceId + m.VolumeId = s.Model.VolumeId + m.Device = s.Model.Device + m.DisplayName = s.Model.DisplayName + m.IsReadOnly = s.Model.IsReadOnly + m.IsShareable = s.Model.IsShareable + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *attachvolumedetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "service_determined": + mm := AttachServiceDeterminedVolumeDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "emulated": + mm := AttachEmulatedVolumeDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "iscsi": + mm := AttachIScsiVolumeDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "paravirtualized": + mm := AttachParavirtualizedVolumeDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetInstanceId returns InstanceId +func (m attachvolumedetails) GetInstanceId() *string { + return m.InstanceId +} + +//GetVolumeId returns VolumeId +func (m attachvolumedetails) GetVolumeId() *string { + return m.VolumeId +} + +//GetDevice returns Device +func (m attachvolumedetails) GetDevice() *string { + return m.Device +} + +//GetDisplayName returns DisplayName +func (m attachvolumedetails) GetDisplayName() *string { + return m.DisplayName +} + +//GetIsReadOnly returns IsReadOnly +func (m attachvolumedetails) GetIsReadOnly() *bool { + return m.IsReadOnly +} + +//GetIsShareable returns IsShareable +func (m attachvolumedetails) GetIsShareable() *bool { + return m.IsShareable +} + +func (m attachvolumedetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_volume_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_volume_request_response.go new file mode 100644 index 000000000..11d21fb1a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/attach_volume_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AttachVolumeRequest wrapper for the AttachVolume operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AttachVolume.go.html to see an example of how to use AttachVolumeRequest. +type AttachVolumeRequest struct { + + // Attach volume request + AttachVolumeDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AttachVolumeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AttachVolumeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AttachVolumeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AttachVolumeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AttachVolumeResponse wrapper for the AttachVolume operation +type AttachVolumeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeAttachment instance + VolumeAttachment `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response AttachVolumeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AttachVolumeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/bgp_session_info.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/bgp_session_info.go new file mode 100644 index 000000000..b8f2652f2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/bgp_session_info.go @@ -0,0 +1,129 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BgpSessionInfo Information for establishing a BGP session for the IPSec tunnel. +type BgpSessionInfo struct { + + // The IP address for the Oracle end of the inside tunnel interface. + // If the tunnel's `routing` attribute is set to `BGP` + // (see IPSecConnectionTunnel), this IP address + // is required and used for the tunnel's BGP session. + // If `routing` is instead set to `STATIC`, this IP address is optional. You can set this IP + // address so you can troubleshoot or monitor the tunnel. + // The value must be a /30 or /31. + // Example: `10.0.0.4/31` + OracleInterfaceIp *string `mandatory:"false" json:"oracleInterfaceIp"` + + // The IP address for the CPE end of the inside tunnel interface. + // If the tunnel's `routing` attribute is set to `BGP` + // (see IPSecConnectionTunnel), this IP address + // is required and used for the tunnel's BGP session. + // If `routing` is instead set to `STATIC`, this IP address is optional. You can set this IP + // address so you can troubleshoot or monitor the tunnel. + // The value must be a /30 or /31. + // Example: `10.0.0.5/31` + CustomerInterfaceIp *string `mandatory:"false" json:"customerInterfaceIp"` + + // The IPv6 address for the Oracle end of the inside tunnel interface. This IP address is optional. + // If the tunnel's `routing` attribute is set to `BGP` + // (see IPSecConnectionTunnel), this IP address + // is used for the tunnel's BGP session. + // If `routing` is instead set to `STATIC`, you can set this IP + // address to troubleshoot or monitor the tunnel. + // Only subnet masks from /64 up to /127 are allowed. + // Example: `2001:db8::1/64` + OracleInterfaceIpv6 *string `mandatory:"false" json:"oracleInterfaceIpv6"` + + // The IPv6 address for the CPE end of the inside tunnel interface. This IP address is optional. + // If the tunnel's `routing` attribute is set to `BGP` + // (see IPSecConnectionTunnel), this IP address + // is used for the tunnel's BGP session. + // If `routing` is instead set to `STATIC`, you can set this IP + // address to troubleshoot or monitor the tunnel. + // Only subnet masks from /64 up to /127 are allowed. + // Example: `2001:db8::1/64` + CustomerInterfaceIpv6 *string `mandatory:"false" json:"customerInterfaceIpv6"` + + // The Oracle BGP ASN. + OracleBgpAsn *string `mandatory:"false" json:"oracleBgpAsn"` + + // If the tunnel's `routing` attribute is set to `BGP` + // (see IPSecConnectionTunnel), this ASN + // is required and used for the tunnel's BGP session. This is the ASN of the network on the + // CPE end of the BGP session. Can be a 2-byte or 4-byte ASN. Uses "asplain" format. + // If the tunnel uses static routing, the `customerBgpAsn` must be null. + // Example: `12345` (2-byte) or `1587232876` (4-byte) + CustomerBgpAsn *string `mandatory:"false" json:"customerBgpAsn"` + + // The state of the BGP session. + BgpState BgpSessionInfoBgpStateEnum `mandatory:"false" json:"bgpState,omitempty"` + + // The state of the BGP IPv6 session. + BgpIpv6State BgpSessionInfoBgpIpv6StateEnum `mandatory:"false" json:"bgpIpv6State,omitempty"` +} + +func (m BgpSessionInfo) String() string { + return common.PointerString(m) +} + +// BgpSessionInfoBgpStateEnum Enum with underlying type: string +type BgpSessionInfoBgpStateEnum string + +// Set of constants representing the allowable values for BgpSessionInfoBgpStateEnum +const ( + BgpSessionInfoBgpStateUp BgpSessionInfoBgpStateEnum = "UP" + BgpSessionInfoBgpStateDown BgpSessionInfoBgpStateEnum = "DOWN" +) + +var mappingBgpSessionInfoBgpState = map[string]BgpSessionInfoBgpStateEnum{ + "UP": BgpSessionInfoBgpStateUp, + "DOWN": BgpSessionInfoBgpStateDown, +} + +// GetBgpSessionInfoBgpStateEnumValues Enumerates the set of values for BgpSessionInfoBgpStateEnum +func GetBgpSessionInfoBgpStateEnumValues() []BgpSessionInfoBgpStateEnum { + values := make([]BgpSessionInfoBgpStateEnum, 0) + for _, v := range mappingBgpSessionInfoBgpState { + values = append(values, v) + } + return values +} + +// BgpSessionInfoBgpIpv6StateEnum Enum with underlying type: string +type BgpSessionInfoBgpIpv6StateEnum string + +// Set of constants representing the allowable values for BgpSessionInfoBgpIpv6StateEnum +const ( + BgpSessionInfoBgpIpv6StateUp BgpSessionInfoBgpIpv6StateEnum = "UP" + BgpSessionInfoBgpIpv6StateDown BgpSessionInfoBgpIpv6StateEnum = "DOWN" +) + +var mappingBgpSessionInfoBgpIpv6State = map[string]BgpSessionInfoBgpIpv6StateEnum{ + "UP": BgpSessionInfoBgpIpv6StateUp, + "DOWN": BgpSessionInfoBgpIpv6StateDown, +} + +// GetBgpSessionInfoBgpIpv6StateEnumValues Enumerates the set of values for BgpSessionInfoBgpIpv6StateEnum +func GetBgpSessionInfoBgpIpv6StateEnumValues() []BgpSessionInfoBgpIpv6StateEnum { + values := make([]BgpSessionInfoBgpIpv6StateEnum, 0) + for _, v := range mappingBgpSessionInfoBgpIpv6State { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/block_volume_replica.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/block_volume_replica.go new file mode 100644 index 000000000..f93dafdd5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/block_volume_replica.go @@ -0,0 +1,109 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BlockVolumeReplica An asynchronous replica of a block volume that can then be used to create +// a new block volume or recover a block volume. For more information, see Overview +// of Cross-Region Volume Replication (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/volumereplication.htm) +// To use any of the API operations, you must be authorized in an IAM policy. +// If you're not authorized, talk to an administrator. If you're an administrator +// who needs to write policies to give users access, see Getting Started with +// Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you +// supply string values using the API. +type BlockVolumeReplica struct { + + // The availability domain of the block volume replica. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment that contains the block volume replica. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The block volume replica's Oracle ID (OCID). + Id *string `mandatory:"true" json:"id"` + + // The current state of a block volume replica. + LifecycleState BlockVolumeReplicaLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The size of the source block volume, in GBs. + SizeInGBs *int64 `mandatory:"true" json:"sizeInGBs"` + + // The date and time the block volume replica was created. Format defined + // by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The date and time the block volume replica was last synced from the source block volume. + // Format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeLastSynced *common.SDKTime `mandatory:"true" json:"timeLastSynced"` + + // The OCID of the source block volume. + BlockVolumeId *string `mandatory:"true" json:"blockVolumeId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The total size of the data transferred from the source block volume to the block volume replica, in GBs. + TotalDataTransferredInGBs *int64 `mandatory:"false" json:"totalDataTransferredInGBs"` +} + +func (m BlockVolumeReplica) String() string { + return common.PointerString(m) +} + +// BlockVolumeReplicaLifecycleStateEnum Enum with underlying type: string +type BlockVolumeReplicaLifecycleStateEnum string + +// Set of constants representing the allowable values for BlockVolumeReplicaLifecycleStateEnum +const ( + BlockVolumeReplicaLifecycleStateProvisioning BlockVolumeReplicaLifecycleStateEnum = "PROVISIONING" + BlockVolumeReplicaLifecycleStateAvailable BlockVolumeReplicaLifecycleStateEnum = "AVAILABLE" + BlockVolumeReplicaLifecycleStateActivating BlockVolumeReplicaLifecycleStateEnum = "ACTIVATING" + BlockVolumeReplicaLifecycleStateTerminating BlockVolumeReplicaLifecycleStateEnum = "TERMINATING" + BlockVolumeReplicaLifecycleStateTerminated BlockVolumeReplicaLifecycleStateEnum = "TERMINATED" + BlockVolumeReplicaLifecycleStateFaulty BlockVolumeReplicaLifecycleStateEnum = "FAULTY" +) + +var mappingBlockVolumeReplicaLifecycleState = map[string]BlockVolumeReplicaLifecycleStateEnum{ + "PROVISIONING": BlockVolumeReplicaLifecycleStateProvisioning, + "AVAILABLE": BlockVolumeReplicaLifecycleStateAvailable, + "ACTIVATING": BlockVolumeReplicaLifecycleStateActivating, + "TERMINATING": BlockVolumeReplicaLifecycleStateTerminating, + "TERMINATED": BlockVolumeReplicaLifecycleStateTerminated, + "FAULTY": BlockVolumeReplicaLifecycleStateFaulty, +} + +// GetBlockVolumeReplicaLifecycleStateEnumValues Enumerates the set of values for BlockVolumeReplicaLifecycleStateEnum +func GetBlockVolumeReplicaLifecycleStateEnumValues() []BlockVolumeReplicaLifecycleStateEnum { + values := make([]BlockVolumeReplicaLifecycleStateEnum, 0) + for _, v := range mappingBlockVolumeReplicaLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/block_volume_replica_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/block_volume_replica_details.go new file mode 100644 index 000000000..b4dd68f43 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/block_volume_replica_details.go @@ -0,0 +1,34 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BlockVolumeReplicaDetails Contains the details for the block volume replica +type BlockVolumeReplicaDetails struct { + + // The availability domain of the block volume replica. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` +} + +func (m BlockVolumeReplicaDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/block_volume_replica_info.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/block_volume_replica_info.go new file mode 100644 index 000000000..d3cd71a0d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/block_volume_replica_info.go @@ -0,0 +1,37 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BlockVolumeReplicaInfo Information about the block volume replica in the destination availability domain. +type BlockVolumeReplicaInfo struct { + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The block volume replica's Oracle ID (OCID). + BlockVolumeReplicaId *string `mandatory:"true" json:"blockVolumeReplicaId"` + + // The availability domain of the block volume replica. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` +} + +func (m BlockVolumeReplicaInfo) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/boolean_image_capability_schema_descriptor.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/boolean_image_capability_schema_descriptor.go new file mode 100644 index 000000000..9110c0299 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/boolean_image_capability_schema_descriptor.go @@ -0,0 +1,51 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BooleanImageCapabilitySchemaDescriptor Boolean type ImageCapabilitySchemaDescriptor +type BooleanImageCapabilitySchemaDescriptor struct { + + // the default value + DefaultValue *bool `mandatory:"false" json:"defaultValue"` + + Source ImageCapabilitySchemaDescriptorSourceEnum `mandatory:"true" json:"source"` +} + +//GetSource returns Source +func (m BooleanImageCapabilitySchemaDescriptor) GetSource() ImageCapabilitySchemaDescriptorSourceEnum { + return m.Source +} + +func (m BooleanImageCapabilitySchemaDescriptor) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m BooleanImageCapabilitySchemaDescriptor) MarshalJSON() (buff []byte, e error) { + type MarshalTypeBooleanImageCapabilitySchemaDescriptor BooleanImageCapabilitySchemaDescriptor + s := struct { + DiscriminatorParam string `json:"descriptorType"` + MarshalTypeBooleanImageCapabilitySchemaDescriptor + }{ + "boolean", + (MarshalTypeBooleanImageCapabilitySchemaDescriptor)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume.go new file mode 100644 index 000000000..00fd72a66 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume.go @@ -0,0 +1,222 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BootVolume A detachable boot volume device that contains the image used to boot a Compute instance. For more information, see +// Overview of Boot Volumes (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/bootvolumes.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you +// supply string values using the API. +type BootVolume struct { + + // The availability domain of the boot volume. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment that contains the boot volume. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The boot volume's Oracle ID (OCID). + Id *string `mandatory:"true" json:"id"` + + // The current state of a boot volume. + LifecycleState BootVolumeLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The size of the volume in MBs. The value must be a multiple of 1024. + // This field is deprecated. Please use sizeInGBs. + SizeInMBs *int64 `mandatory:"true" json:"sizeInMBs"` + + // The date and time the boot volume was created. Format defined + // by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // System tags for this resource. Each key is predefined and scoped to a namespace. + // Example: `{"foo-namespace": {"bar-key": "value"}}` + SystemTags map[string]map[string]interface{} `mandatory:"false" json:"systemTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The image OCID used to create the boot volume. + ImageId *string `mandatory:"false" json:"imageId"` + + // Specifies whether the boot volume's data has finished copying + // from the source boot volume or boot volume backup. + IsHydrated *bool `mandatory:"false" json:"isHydrated"` + + // The number of volume performance units (VPUs) that will be applied to this boot volume per GB, + // representing the Block Volume service's elastic performance options. + // See Block Volume Elastic Performance (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/blockvolumeelasticperformance.htm) for more information. + // Allowed values: + // * `10`: Represents Balanced option. + // * `20`: Represents Higher Performance option. + VpusPerGB *int64 `mandatory:"false" json:"vpusPerGB"` + + // The size of the boot volume in GBs. + SizeInGBs *int64 `mandatory:"false" json:"sizeInGBs"` + + SourceDetails BootVolumeSourceDetails `mandatory:"false" json:"sourceDetails"` + + // The OCID of the source volume group. + VolumeGroupId *string `mandatory:"false" json:"volumeGroupId"` + + // The OCID of the Key Management master encryption key assigned to the boot volume. + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` + + // Specifies whether the auto-tune performance is enabled for this boot volume. + IsAutoTuneEnabled *bool `mandatory:"false" json:"isAutoTuneEnabled"` + + // The number of Volume Performance Units per GB that this boot volume is effectively tuned to when it's idle. + AutoTunedVpusPerGB *int64 `mandatory:"false" json:"autoTunedVpusPerGB"` + + // The list of boot volume replicas of this boot volume + BootVolumeReplicas []BootVolumeReplicaInfo `mandatory:"false" json:"bootVolumeReplicas"` +} + +func (m BootVolume) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *BootVolume) UnmarshalJSON(data []byte) (e error) { + model := struct { + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + SystemTags map[string]map[string]interface{} `json:"systemTags"` + DisplayName *string `json:"displayName"` + FreeformTags map[string]string `json:"freeformTags"` + ImageId *string `json:"imageId"` + IsHydrated *bool `json:"isHydrated"` + VpusPerGB *int64 `json:"vpusPerGB"` + SizeInGBs *int64 `json:"sizeInGBs"` + SourceDetails bootvolumesourcedetails `json:"sourceDetails"` + VolumeGroupId *string `json:"volumeGroupId"` + KmsKeyId *string `json:"kmsKeyId"` + IsAutoTuneEnabled *bool `json:"isAutoTuneEnabled"` + AutoTunedVpusPerGB *int64 `json:"autoTunedVpusPerGB"` + BootVolumeReplicas []BootVolumeReplicaInfo `json:"bootVolumeReplicas"` + AvailabilityDomain *string `json:"availabilityDomain"` + CompartmentId *string `json:"compartmentId"` + Id *string `json:"id"` + LifecycleState BootVolumeLifecycleStateEnum `json:"lifecycleState"` + SizeInMBs *int64 `json:"sizeInMBs"` + TimeCreated *common.SDKTime `json:"timeCreated"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.DefinedTags = model.DefinedTags + + m.SystemTags = model.SystemTags + + m.DisplayName = model.DisplayName + + m.FreeformTags = model.FreeformTags + + m.ImageId = model.ImageId + + m.IsHydrated = model.IsHydrated + + m.VpusPerGB = model.VpusPerGB + + m.SizeInGBs = model.SizeInGBs + + nn, e = model.SourceDetails.UnmarshalPolymorphicJSON(model.SourceDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.SourceDetails = nn.(BootVolumeSourceDetails) + } else { + m.SourceDetails = nil + } + + m.VolumeGroupId = model.VolumeGroupId + + m.KmsKeyId = model.KmsKeyId + + m.IsAutoTuneEnabled = model.IsAutoTuneEnabled + + m.AutoTunedVpusPerGB = model.AutoTunedVpusPerGB + + m.BootVolumeReplicas = make([]BootVolumeReplicaInfo, len(model.BootVolumeReplicas)) + for i, n := range model.BootVolumeReplicas { + m.BootVolumeReplicas[i] = n + } + + m.AvailabilityDomain = model.AvailabilityDomain + + m.CompartmentId = model.CompartmentId + + m.Id = model.Id + + m.LifecycleState = model.LifecycleState + + m.SizeInMBs = model.SizeInMBs + + m.TimeCreated = model.TimeCreated + + return +} + +// BootVolumeLifecycleStateEnum Enum with underlying type: string +type BootVolumeLifecycleStateEnum string + +// Set of constants representing the allowable values for BootVolumeLifecycleStateEnum +const ( + BootVolumeLifecycleStateProvisioning BootVolumeLifecycleStateEnum = "PROVISIONING" + BootVolumeLifecycleStateRestoring BootVolumeLifecycleStateEnum = "RESTORING" + BootVolumeLifecycleStateAvailable BootVolumeLifecycleStateEnum = "AVAILABLE" + BootVolumeLifecycleStateTerminating BootVolumeLifecycleStateEnum = "TERMINATING" + BootVolumeLifecycleStateTerminated BootVolumeLifecycleStateEnum = "TERMINATED" + BootVolumeLifecycleStateFaulty BootVolumeLifecycleStateEnum = "FAULTY" +) + +var mappingBootVolumeLifecycleState = map[string]BootVolumeLifecycleStateEnum{ + "PROVISIONING": BootVolumeLifecycleStateProvisioning, + "RESTORING": BootVolumeLifecycleStateRestoring, + "AVAILABLE": BootVolumeLifecycleStateAvailable, + "TERMINATING": BootVolumeLifecycleStateTerminating, + "TERMINATED": BootVolumeLifecycleStateTerminated, + "FAULTY": BootVolumeLifecycleStateFaulty, +} + +// GetBootVolumeLifecycleStateEnumValues Enumerates the set of values for BootVolumeLifecycleStateEnum +func GetBootVolumeLifecycleStateEnumValues() []BootVolumeLifecycleStateEnum { + values := make([]BootVolumeLifecycleStateEnum, 0) + for _, v := range mappingBootVolumeLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_attachment.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_attachment.go new file mode 100644 index 000000000..e21160f83 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_attachment.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BootVolumeAttachment Represents an attachment between a boot volume and an instance. +// **Warning:** Oracle recommends that you avoid using any confidential information when you +// supply string values using the API. +type BootVolumeAttachment struct { + + // The availability domain of an instance. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the boot volume. + BootVolumeId *string `mandatory:"true" json:"bootVolumeId"` + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the boot volume attachment. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the instance the boot volume is attached to. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // The current state of the boot volume attachment. + LifecycleState BootVolumeAttachmentLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the boot volume was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Whether in-transit encryption for the boot volume's paravirtualized attachment is enabled or not. + IsPvEncryptionInTransitEnabled *bool `mandatory:"false" json:"isPvEncryptionInTransitEnabled"` + + // Refer the top-level definition of encryptionInTransitType. + // The default value is NONE. + EncryptionInTransitType EncryptionInTransitTypeEnum `mandatory:"false" json:"encryptionInTransitType,omitempty"` +} + +func (m BootVolumeAttachment) String() string { + return common.PointerString(m) +} + +// BootVolumeAttachmentLifecycleStateEnum Enum with underlying type: string +type BootVolumeAttachmentLifecycleStateEnum string + +// Set of constants representing the allowable values for BootVolumeAttachmentLifecycleStateEnum +const ( + BootVolumeAttachmentLifecycleStateAttaching BootVolumeAttachmentLifecycleStateEnum = "ATTACHING" + BootVolumeAttachmentLifecycleStateAttached BootVolumeAttachmentLifecycleStateEnum = "ATTACHED" + BootVolumeAttachmentLifecycleStateDetaching BootVolumeAttachmentLifecycleStateEnum = "DETACHING" + BootVolumeAttachmentLifecycleStateDetached BootVolumeAttachmentLifecycleStateEnum = "DETACHED" +) + +var mappingBootVolumeAttachmentLifecycleState = map[string]BootVolumeAttachmentLifecycleStateEnum{ + "ATTACHING": BootVolumeAttachmentLifecycleStateAttaching, + "ATTACHED": BootVolumeAttachmentLifecycleStateAttached, + "DETACHING": BootVolumeAttachmentLifecycleStateDetaching, + "DETACHED": BootVolumeAttachmentLifecycleStateDetached, +} + +// GetBootVolumeAttachmentLifecycleStateEnumValues Enumerates the set of values for BootVolumeAttachmentLifecycleStateEnum +func GetBootVolumeAttachmentLifecycleStateEnumValues() []BootVolumeAttachmentLifecycleStateEnum { + values := make([]BootVolumeAttachmentLifecycleStateEnum, 0) + for _, v := range mappingBootVolumeAttachmentLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_backup.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_backup.go new file mode 100644 index 000000000..d715c4450 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_backup.go @@ -0,0 +1,180 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BootVolumeBackup A point-in-time copy of a boot volume that can then be used to create +// a new boot volume or recover a boot volume. For more information, see Overview +// of Boot Volume Backups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/bootvolumebackups.htm) +// To use any of the API operations, you must be authorized in an IAM policy. +// If you're not authorized, talk to an administrator. If you're an administrator +// who needs to write policies to give users access, see Getting Started with +// Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you +// supply string values using the API. +type BootVolumeBackup struct { + + // The OCID of the compartment that contains the boot volume backup. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The OCID of the boot volume backup. + Id *string `mandatory:"true" json:"id"` + + // The current state of a boot volume backup. + LifecycleState BootVolumeBackupLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the boot volume backup was created. This is the time the actual point-in-time image + // of the volume data was taken. Format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID of the boot volume. + BootVolumeId *string `mandatory:"false" json:"bootVolumeId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // System tags for this resource. Each key is predefined and scoped to a namespace. + // Example: `{"foo-namespace": {"bar-key": "value"}}` + SystemTags map[string]map[string]interface{} `mandatory:"false" json:"systemTags"` + + // The date and time the volume backup will expire and be automatically deleted. + // Format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). This parameter will always be present for backups that + // were created automatically by a scheduled-backup policy. For manually created backups, + // it will be absent, signifying that there is no expiration time and the backup will + // last forever until manually deleted. + ExpirationTime *common.SDKTime `mandatory:"false" json:"expirationTime"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The image OCID used to create the boot volume the backup is taken from. + ImageId *string `mandatory:"false" json:"imageId"` + + // The OCID of the Key Management master encryption assigned to the boot volume backup. + // For more information about the Key Management service and encryption keys, see + // Overview of Key Management (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` + + // The size of the boot volume, in GBs. + SizeInGBs *int64 `mandatory:"false" json:"sizeInGBs"` + + // The OCID of the source boot volume backup. + SourceBootVolumeBackupId *string `mandatory:"false" json:"sourceBootVolumeBackupId"` + + // Specifies whether the backup was created manually, or via scheduled backup policy. + SourceType BootVolumeBackupSourceTypeEnum `mandatory:"false" json:"sourceType,omitempty"` + + // The date and time the request to create the boot volume backup was received. Format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeRequestReceived *common.SDKTime `mandatory:"false" json:"timeRequestReceived"` + + // The type of a volume backup. + Type BootVolumeBackupTypeEnum `mandatory:"false" json:"type,omitempty"` + + // The size used by the backup, in GBs. It is typically smaller than sizeInGBs, depending on the space + // consumed on the boot volume and whether the backup is full or incremental. + UniqueSizeInGBs *int64 `mandatory:"false" json:"uniqueSizeInGBs"` +} + +func (m BootVolumeBackup) String() string { + return common.PointerString(m) +} + +// BootVolumeBackupLifecycleStateEnum Enum with underlying type: string +type BootVolumeBackupLifecycleStateEnum string + +// Set of constants representing the allowable values for BootVolumeBackupLifecycleStateEnum +const ( + BootVolumeBackupLifecycleStateCreating BootVolumeBackupLifecycleStateEnum = "CREATING" + BootVolumeBackupLifecycleStateAvailable BootVolumeBackupLifecycleStateEnum = "AVAILABLE" + BootVolumeBackupLifecycleStateTerminating BootVolumeBackupLifecycleStateEnum = "TERMINATING" + BootVolumeBackupLifecycleStateTerminated BootVolumeBackupLifecycleStateEnum = "TERMINATED" + BootVolumeBackupLifecycleStateFaulty BootVolumeBackupLifecycleStateEnum = "FAULTY" + BootVolumeBackupLifecycleStateRequestReceived BootVolumeBackupLifecycleStateEnum = "REQUEST_RECEIVED" +) + +var mappingBootVolumeBackupLifecycleState = map[string]BootVolumeBackupLifecycleStateEnum{ + "CREATING": BootVolumeBackupLifecycleStateCreating, + "AVAILABLE": BootVolumeBackupLifecycleStateAvailable, + "TERMINATING": BootVolumeBackupLifecycleStateTerminating, + "TERMINATED": BootVolumeBackupLifecycleStateTerminated, + "FAULTY": BootVolumeBackupLifecycleStateFaulty, + "REQUEST_RECEIVED": BootVolumeBackupLifecycleStateRequestReceived, +} + +// GetBootVolumeBackupLifecycleStateEnumValues Enumerates the set of values for BootVolumeBackupLifecycleStateEnum +func GetBootVolumeBackupLifecycleStateEnumValues() []BootVolumeBackupLifecycleStateEnum { + values := make([]BootVolumeBackupLifecycleStateEnum, 0) + for _, v := range mappingBootVolumeBackupLifecycleState { + values = append(values, v) + } + return values +} + +// BootVolumeBackupSourceTypeEnum Enum with underlying type: string +type BootVolumeBackupSourceTypeEnum string + +// Set of constants representing the allowable values for BootVolumeBackupSourceTypeEnum +const ( + BootVolumeBackupSourceTypeManual BootVolumeBackupSourceTypeEnum = "MANUAL" + BootVolumeBackupSourceTypeScheduled BootVolumeBackupSourceTypeEnum = "SCHEDULED" +) + +var mappingBootVolumeBackupSourceType = map[string]BootVolumeBackupSourceTypeEnum{ + "MANUAL": BootVolumeBackupSourceTypeManual, + "SCHEDULED": BootVolumeBackupSourceTypeScheduled, +} + +// GetBootVolumeBackupSourceTypeEnumValues Enumerates the set of values for BootVolumeBackupSourceTypeEnum +func GetBootVolumeBackupSourceTypeEnumValues() []BootVolumeBackupSourceTypeEnum { + values := make([]BootVolumeBackupSourceTypeEnum, 0) + for _, v := range mappingBootVolumeBackupSourceType { + values = append(values, v) + } + return values +} + +// BootVolumeBackupTypeEnum Enum with underlying type: string +type BootVolumeBackupTypeEnum string + +// Set of constants representing the allowable values for BootVolumeBackupTypeEnum +const ( + BootVolumeBackupTypeFull BootVolumeBackupTypeEnum = "FULL" + BootVolumeBackupTypeIncremental BootVolumeBackupTypeEnum = "INCREMENTAL" +) + +var mappingBootVolumeBackupType = map[string]BootVolumeBackupTypeEnum{ + "FULL": BootVolumeBackupTypeFull, + "INCREMENTAL": BootVolumeBackupTypeIncremental, +} + +// GetBootVolumeBackupTypeEnumValues Enumerates the set of values for BootVolumeBackupTypeEnum +func GetBootVolumeBackupTypeEnumValues() []BootVolumeBackupTypeEnum { + values := make([]BootVolumeBackupTypeEnum, 0) + for _, v := range mappingBootVolumeBackupType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_kms_key.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_kms_key.go new file mode 100644 index 000000000..9bd302849 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_kms_key.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BootVolumeKmsKey The Key Management master encryption key associated with this volume. +type BootVolumeKmsKey struct { + + // The OCID of the Key Management key assigned to this volume. If the volume is not using Key Management, then the `kmsKeyId` will be a null string. + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` +} + +func (m BootVolumeKmsKey) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_replica.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_replica.go new file mode 100644 index 000000000..ccd95ff73 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_replica.go @@ -0,0 +1,112 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BootVolumeReplica An asynchronous replica of a boot volume that can then be used to create +// a new boot volume or recover a boot volume. For more information, see Overview +// of Cross-Region Volume Replication (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/volumereplication.htm) +// To use any of the API operations, you must be authorized in an IAM policy. +// If you're not authorized, talk to an administrator. If you're an administrator +// who needs to write policies to give users access, see Getting Started with +// Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you +// supply string values using the API. +type BootVolumeReplica struct { + + // The availability domain of the boot volume replica. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment that contains the boot volume replica. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The boot volume replica's Oracle ID (OCID). + Id *string `mandatory:"true" json:"id"` + + // The current state of a boot volume replica. + LifecycleState BootVolumeReplicaLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The size of the source boot volume, in GBs. + SizeInGBs *int64 `mandatory:"true" json:"sizeInGBs"` + + // The date and time the boot volume replica was created. Format defined + // by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The date and time the boot volume replica was last synced from the source boot volume. + // Format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeLastSynced *common.SDKTime `mandatory:"true" json:"timeLastSynced"` + + // The OCID of the source boot volume. + BootVolumeId *string `mandatory:"true" json:"bootVolumeId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The image OCID used to create the boot volume the replica is replicated from. + ImageId *string `mandatory:"false" json:"imageId"` + + // The total size of the data transferred from the source boot volume to the boot volume replica, in GBs. + TotalDataTransferredInGBs *int64 `mandatory:"false" json:"totalDataTransferredInGBs"` +} + +func (m BootVolumeReplica) String() string { + return common.PointerString(m) +} + +// BootVolumeReplicaLifecycleStateEnum Enum with underlying type: string +type BootVolumeReplicaLifecycleStateEnum string + +// Set of constants representing the allowable values for BootVolumeReplicaLifecycleStateEnum +const ( + BootVolumeReplicaLifecycleStateProvisioning BootVolumeReplicaLifecycleStateEnum = "PROVISIONING" + BootVolumeReplicaLifecycleStateAvailable BootVolumeReplicaLifecycleStateEnum = "AVAILABLE" + BootVolumeReplicaLifecycleStateActivating BootVolumeReplicaLifecycleStateEnum = "ACTIVATING" + BootVolumeReplicaLifecycleStateTerminating BootVolumeReplicaLifecycleStateEnum = "TERMINATING" + BootVolumeReplicaLifecycleStateTerminated BootVolumeReplicaLifecycleStateEnum = "TERMINATED" + BootVolumeReplicaLifecycleStateFaulty BootVolumeReplicaLifecycleStateEnum = "FAULTY" +) + +var mappingBootVolumeReplicaLifecycleState = map[string]BootVolumeReplicaLifecycleStateEnum{ + "PROVISIONING": BootVolumeReplicaLifecycleStateProvisioning, + "AVAILABLE": BootVolumeReplicaLifecycleStateAvailable, + "ACTIVATING": BootVolumeReplicaLifecycleStateActivating, + "TERMINATING": BootVolumeReplicaLifecycleStateTerminating, + "TERMINATED": BootVolumeReplicaLifecycleStateTerminated, + "FAULTY": BootVolumeReplicaLifecycleStateFaulty, +} + +// GetBootVolumeReplicaLifecycleStateEnumValues Enumerates the set of values for BootVolumeReplicaLifecycleStateEnum +func GetBootVolumeReplicaLifecycleStateEnumValues() []BootVolumeReplicaLifecycleStateEnum { + values := make([]BootVolumeReplicaLifecycleStateEnum, 0) + for _, v := range mappingBootVolumeReplicaLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_replica_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_replica_details.go new file mode 100644 index 000000000..cc8cf30bc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_replica_details.go @@ -0,0 +1,34 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BootVolumeReplicaDetails Contains the details for the boot volume replica +type BootVolumeReplicaDetails struct { + + // The availability domain of the boot volume replica. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` +} + +func (m BootVolumeReplicaDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_replica_info.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_replica_info.go new file mode 100644 index 000000000..975f6d6bf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_replica_info.go @@ -0,0 +1,37 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BootVolumeReplicaInfo Information about the boot volume replica in the destination availability domain. +type BootVolumeReplicaInfo struct { + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The boot volume replica's Oracle ID (OCID). + BootVolumeReplicaId *string `mandatory:"true" json:"bootVolumeReplicaId"` + + // The availability domain of the boot volume replica. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` +} + +func (m BootVolumeReplicaInfo) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_details.go new file mode 100644 index 000000000..f016e5a17 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_details.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BootVolumeSourceDetails The representation of BootVolumeSourceDetails +type BootVolumeSourceDetails interface { +} + +type bootvolumesourcedetails struct { + JsonData []byte + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *bootvolumesourcedetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerbootvolumesourcedetails bootvolumesourcedetails + s := struct { + Model Unmarshalerbootvolumesourcedetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *bootvolumesourcedetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "bootVolumeBackup": + mm := BootVolumeSourceFromBootVolumeBackupDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "bootVolume": + mm := BootVolumeSourceFromBootVolumeDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "bootVolumeReplica": + mm := BootVolumeSourceFromBootVolumeReplicaDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +func (m bootvolumesourcedetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_from_boot_volume_backup_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_from_boot_volume_backup_details.go new file mode 100644 index 000000000..6fe623af2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_from_boot_volume_backup_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BootVolumeSourceFromBootVolumeBackupDetails Specifies the boot volume backup. +type BootVolumeSourceFromBootVolumeBackupDetails struct { + + // The OCID of the boot volume backup. + Id *string `mandatory:"true" json:"id"` +} + +func (m BootVolumeSourceFromBootVolumeBackupDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m BootVolumeSourceFromBootVolumeBackupDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeBootVolumeSourceFromBootVolumeBackupDetails BootVolumeSourceFromBootVolumeBackupDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeBootVolumeSourceFromBootVolumeBackupDetails + }{ + "bootVolumeBackup", + (MarshalTypeBootVolumeSourceFromBootVolumeBackupDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_from_boot_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_from_boot_volume_details.go new file mode 100644 index 000000000..c3f50c8b6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_from_boot_volume_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BootVolumeSourceFromBootVolumeDetails Specifies the source boot volume. +type BootVolumeSourceFromBootVolumeDetails struct { + + // The OCID of the boot volume. + Id *string `mandatory:"true" json:"id"` +} + +func (m BootVolumeSourceFromBootVolumeDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m BootVolumeSourceFromBootVolumeDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeBootVolumeSourceFromBootVolumeDetails BootVolumeSourceFromBootVolumeDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeBootVolumeSourceFromBootVolumeDetails + }{ + "bootVolume", + (MarshalTypeBootVolumeSourceFromBootVolumeDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_from_boot_volume_replica_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_from_boot_volume_replica_details.go new file mode 100644 index 000000000..6adc21e47 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/boot_volume_source_from_boot_volume_replica_details.go @@ -0,0 +1,46 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BootVolumeSourceFromBootVolumeReplicaDetails Specifies the source boot volume replica which the boot volume will be created from. +// The boot volume replica shoulbe be in the same availability domain as the boot volume. +// Only one volume can be created from a replica at the same time. +type BootVolumeSourceFromBootVolumeReplicaDetails struct { + + // The OCID of the boot volume replica. + Id *string `mandatory:"true" json:"id"` +} + +func (m BootVolumeSourceFromBootVolumeReplicaDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m BootVolumeSourceFromBootVolumeReplicaDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeBootVolumeSourceFromBootVolumeReplicaDetails BootVolumeSourceFromBootVolumeReplicaDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeBootVolumeSourceFromBootVolumeReplicaDetails + }{ + "bootVolumeReplica", + (MarshalTypeBootVolumeSourceFromBootVolumeReplicaDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_add_virtual_circuit_public_prefixes_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_add_virtual_circuit_public_prefixes_details.go new file mode 100644 index 000000000..0b6d59701 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_add_virtual_circuit_public_prefixes_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BulkAddVirtualCircuitPublicPrefixesDetails The representation of BulkAddVirtualCircuitPublicPrefixesDetails +type BulkAddVirtualCircuitPublicPrefixesDetails struct { + + // The public IP prefixes (CIDRs) to add to the public virtual circuit. + PublicPrefixes []CreateVirtualCircuitPublicPrefixDetails `mandatory:"true" json:"publicPrefixes"` +} + +func (m BulkAddVirtualCircuitPublicPrefixesDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_add_virtual_circuit_public_prefixes_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_add_virtual_circuit_public_prefixes_request_response.go new file mode 100644 index 000000000..d7680747c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_add_virtual_circuit_public_prefixes_request_response.go @@ -0,0 +1,70 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// BulkAddVirtualCircuitPublicPrefixesRequest wrapper for the BulkAddVirtualCircuitPublicPrefixes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/BulkAddVirtualCircuitPublicPrefixes.go.html to see an example of how to use BulkAddVirtualCircuitPublicPrefixesRequest. +type BulkAddVirtualCircuitPublicPrefixesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the virtual circuit. + VirtualCircuitId *string `mandatory:"true" contributesTo:"path" name:"virtualCircuitId"` + + // Request with publix prefixes to be added to the virtual circuit + BulkAddVirtualCircuitPublicPrefixesDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request BulkAddVirtualCircuitPublicPrefixesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request BulkAddVirtualCircuitPublicPrefixesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request BulkAddVirtualCircuitPublicPrefixesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request BulkAddVirtualCircuitPublicPrefixesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// BulkAddVirtualCircuitPublicPrefixesResponse wrapper for the BulkAddVirtualCircuitPublicPrefixes operation +type BulkAddVirtualCircuitPublicPrefixesResponse struct { + + // The underlying http response + RawResponse *http.Response +} + +func (response BulkAddVirtualCircuitPublicPrefixesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response BulkAddVirtualCircuitPublicPrefixesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_delete_virtual_circuit_public_prefixes_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_delete_virtual_circuit_public_prefixes_details.go new file mode 100644 index 000000000..6f877a242 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_delete_virtual_circuit_public_prefixes_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BulkDeleteVirtualCircuitPublicPrefixesDetails The representation of BulkDeleteVirtualCircuitPublicPrefixesDetails +type BulkDeleteVirtualCircuitPublicPrefixesDetails struct { + + // The public IP prefixes (CIDRs) to remove from the public virtual circuit. + PublicPrefixes []DeleteVirtualCircuitPublicPrefixDetails `mandatory:"true" json:"publicPrefixes"` +} + +func (m BulkDeleteVirtualCircuitPublicPrefixesDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_delete_virtual_circuit_public_prefixes_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_delete_virtual_circuit_public_prefixes_request_response.go new file mode 100644 index 000000000..4b49933b2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/bulk_delete_virtual_circuit_public_prefixes_request_response.go @@ -0,0 +1,70 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// BulkDeleteVirtualCircuitPublicPrefixesRequest wrapper for the BulkDeleteVirtualCircuitPublicPrefixes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/BulkDeleteVirtualCircuitPublicPrefixes.go.html to see an example of how to use BulkDeleteVirtualCircuitPublicPrefixesRequest. +type BulkDeleteVirtualCircuitPublicPrefixesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the virtual circuit. + VirtualCircuitId *string `mandatory:"true" contributesTo:"path" name:"virtualCircuitId"` + + // Request with public prefixes to be deleted from the virtual circuit. + BulkDeleteVirtualCircuitPublicPrefixesDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request BulkDeleteVirtualCircuitPublicPrefixesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request BulkDeleteVirtualCircuitPublicPrefixesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request BulkDeleteVirtualCircuitPublicPrefixesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request BulkDeleteVirtualCircuitPublicPrefixesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// BulkDeleteVirtualCircuitPublicPrefixesResponse wrapper for the BulkDeleteVirtualCircuitPublicPrefixes operation +type BulkDeleteVirtualCircuitPublicPrefixesResponse struct { + + // The underlying http response + RawResponse *http.Response +} + +func (response BulkDeleteVirtualCircuitPublicPrefixesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response BulkDeleteVirtualCircuitPublicPrefixesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_allocated_range_collection.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_allocated_range_collection.go new file mode 100644 index 000000000..86610be8f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_allocated_range_collection.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ByoipAllocatedRangeCollection Results of a `ListByoipAllocatedRanges` operation. +type ByoipAllocatedRangeCollection struct { + + // A list of subranges of a BYOIP CIDR block allocated to an IP pool. + Items []ByoipAllocatedRangeSummary `mandatory:"true" json:"items"` +} + +func (m ByoipAllocatedRangeCollection) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_allocated_range_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_allocated_range_summary.go new file mode 100644 index 000000000..572b0ce2a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_allocated_range_summary.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ByoipAllocatedRangeSummary A summary of CIDR block subranges that are currently allocated to an IP pool. +type ByoipAllocatedRangeSummary struct { + + // The BYOIP CIDR block range or subrange allocated to an IP pool. This could be all or part of a BYOIP CIDR block. + CidrBlock *string `mandatory:"false" json:"cidrBlock"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the IP pool containing the CIDR block. + PublicIpPoolId *string `mandatory:"false" json:"publicIpPoolId"` +} + +func (m ByoipAllocatedRangeSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_range.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_range.go new file mode 100644 index 000000000..6366ce659 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_range.go @@ -0,0 +1,141 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ByoipRange Oracle offers the ability to Bring Your Own IP (BYOIP), importing public IP addresses that you currently own to Oracle Cloud Infrastructure. A `ByoipRange` resource is a record of the imported address block (a BYOIP CIDR block) and also some associated metadata. +// The process used to Bring Your Own IP (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/BYOIP.htm) is explained in the documentation. +type ByoipRange struct { + + // The public IPv4 CIDR block being imported from on-premises to the Oracle cloud. + CidrBlock *string `mandatory:"true" json:"cidrBlock"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the BYOIP CIDR block. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the `ByoipRange` resource. + Id *string `mandatory:"true" json:"id"` + + // The `ByoipRange` resource's current state. + LifecycleState ByoipRangeLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the `ByoipRange` resource was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The validation token is an internally-generated ASCII string used in the validation process. See Importing a CIDR block (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/BYOIP.htm#import_cidr) for details. + ValidationToken *string `mandatory:"true" json:"validationToken"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The `ByoipRange` resource's current status. + LifecycleDetails ByoipRangeLifecycleDetailsEnum `mandatory:"false" json:"lifecycleDetails,omitempty"` + + // The date and time the `ByoipRange` resource was validated, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeValidated *common.SDKTime `mandatory:"false" json:"timeValidated"` + + // The date and time the `ByoipRange` resource was advertised to the internet by BGP, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeAdvertised *common.SDKTime `mandatory:"false" json:"timeAdvertised"` + + // The date and time the `ByoipRange` resource was withdrawn from advertisement by BGP to the internet, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeWithdrawn *common.SDKTime `mandatory:"false" json:"timeWithdrawn"` +} + +func (m ByoipRange) String() string { + return common.PointerString(m) +} + +// ByoipRangeLifecycleDetailsEnum Enum with underlying type: string +type ByoipRangeLifecycleDetailsEnum string + +// Set of constants representing the allowable values for ByoipRangeLifecycleDetailsEnum +const ( + ByoipRangeLifecycleDetailsCreating ByoipRangeLifecycleDetailsEnum = "CREATING" + ByoipRangeLifecycleDetailsValidating ByoipRangeLifecycleDetailsEnum = "VALIDATING" + ByoipRangeLifecycleDetailsProvisioned ByoipRangeLifecycleDetailsEnum = "PROVISIONED" + ByoipRangeLifecycleDetailsActive ByoipRangeLifecycleDetailsEnum = "ACTIVE" + ByoipRangeLifecycleDetailsFailed ByoipRangeLifecycleDetailsEnum = "FAILED" + ByoipRangeLifecycleDetailsDeleting ByoipRangeLifecycleDetailsEnum = "DELETING" + ByoipRangeLifecycleDetailsDeleted ByoipRangeLifecycleDetailsEnum = "DELETED" + ByoipRangeLifecycleDetailsAdvertising ByoipRangeLifecycleDetailsEnum = "ADVERTISING" + ByoipRangeLifecycleDetailsWithdrawing ByoipRangeLifecycleDetailsEnum = "WITHDRAWING" +) + +var mappingByoipRangeLifecycleDetails = map[string]ByoipRangeLifecycleDetailsEnum{ + "CREATING": ByoipRangeLifecycleDetailsCreating, + "VALIDATING": ByoipRangeLifecycleDetailsValidating, + "PROVISIONED": ByoipRangeLifecycleDetailsProvisioned, + "ACTIVE": ByoipRangeLifecycleDetailsActive, + "FAILED": ByoipRangeLifecycleDetailsFailed, + "DELETING": ByoipRangeLifecycleDetailsDeleting, + "DELETED": ByoipRangeLifecycleDetailsDeleted, + "ADVERTISING": ByoipRangeLifecycleDetailsAdvertising, + "WITHDRAWING": ByoipRangeLifecycleDetailsWithdrawing, +} + +// GetByoipRangeLifecycleDetailsEnumValues Enumerates the set of values for ByoipRangeLifecycleDetailsEnum +func GetByoipRangeLifecycleDetailsEnumValues() []ByoipRangeLifecycleDetailsEnum { + values := make([]ByoipRangeLifecycleDetailsEnum, 0) + for _, v := range mappingByoipRangeLifecycleDetails { + values = append(values, v) + } + return values +} + +// ByoipRangeLifecycleStateEnum Enum with underlying type: string +type ByoipRangeLifecycleStateEnum string + +// Set of constants representing the allowable values for ByoipRangeLifecycleStateEnum +const ( + ByoipRangeLifecycleStateInactive ByoipRangeLifecycleStateEnum = "INACTIVE" + ByoipRangeLifecycleStateUpdating ByoipRangeLifecycleStateEnum = "UPDATING" + ByoipRangeLifecycleStateActive ByoipRangeLifecycleStateEnum = "ACTIVE" + ByoipRangeLifecycleStateDeleting ByoipRangeLifecycleStateEnum = "DELETING" + ByoipRangeLifecycleStateDeleted ByoipRangeLifecycleStateEnum = "DELETED" +) + +var mappingByoipRangeLifecycleState = map[string]ByoipRangeLifecycleStateEnum{ + "INACTIVE": ByoipRangeLifecycleStateInactive, + "UPDATING": ByoipRangeLifecycleStateUpdating, + "ACTIVE": ByoipRangeLifecycleStateActive, + "DELETING": ByoipRangeLifecycleStateDeleting, + "DELETED": ByoipRangeLifecycleStateDeleted, +} + +// GetByoipRangeLifecycleStateEnumValues Enumerates the set of values for ByoipRangeLifecycleStateEnum +func GetByoipRangeLifecycleStateEnumValues() []ByoipRangeLifecycleStateEnum { + values := make([]ByoipRangeLifecycleStateEnum, 0) + for _, v := range mappingByoipRangeLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_range_collection.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_range_collection.go new file mode 100644 index 000000000..b2af1ce3a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_range_collection.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ByoipRangeCollection The results returned by a `ListByoipRange` operation. +type ByoipRangeCollection struct { + + // A list of `ByoipRange` resource summaries. + Items []ByoipRangeSummary `mandatory:"true" json:"items"` +} + +func (m ByoipRangeCollection) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_range_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_range_summary.go new file mode 100644 index 000000000..91fccde80 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/byoip_range_summary.go @@ -0,0 +1,59 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ByoipRangeSummary Information about a `ByoipRange` resource. +type ByoipRangeSummary struct { + + // The public IPv4 address range you are importing to the Oracle cloud. + CidrBlock *string `mandatory:"false" json:"cidrBlock"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the `ByoipRange` resource. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the `ByoipRange` resource. + Id *string `mandatory:"false" json:"id"` + + // The `ByoipRange` resource's current state. + LifecycleState ByoipRangeLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The Byoip Range's current lifeCycle substate. + LifecycleDetails ByoipRangeLifecycleDetailsEnum `mandatory:"false" json:"lifecycleDetails,omitempty"` + + // The date and time the `ByoipRange` resource was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` +} + +func (m ByoipRangeSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/capacity_reservation_instance_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/capacity_reservation_instance_summary.go new file mode 100644 index 000000000..77085d826 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/capacity_reservation_instance_summary.go @@ -0,0 +1,45 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CapacityReservationInstanceSummary Condensed instance data when listing instances in a compute capacity reservation. +type CapacityReservationInstanceSummary struct { + + // The OCID of the instance. + Id *string `mandatory:"true" json:"id"` + + // The availability domain the instance is running in. + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment that contains the instance. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The shape of the instance. The shape determines the number of CPUs, amount of memory, + // and other resources allocated to the instance. + // You can enumerate all available shapes by calling ListComputeCapacityReservationInstanceShapes. + Shape *string `mandatory:"true" json:"shape"` + + // The fault domain the instance is running in. + FaultDomain *string `mandatory:"false" json:"faultDomain"` + + ShapeConfig *InstanceReservationShapeConfigDetails `mandatory:"false" json:"shapeConfig"` +} + +func (m CapacityReservationInstanceSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/capture_console_history_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/capture_console_history_details.go new file mode 100644 index 000000000..f28c37df6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/capture_console_history_details.go @@ -0,0 +1,43 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CaptureConsoleHistoryDetails The representation of CaptureConsoleHistoryDetails +type CaptureConsoleHistoryDetails struct { + + // The OCID of the instance to get the console history from. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CaptureConsoleHistoryDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/capture_console_history_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/capture_console_history_request_response.go new file mode 100644 index 000000000..66ac27eb6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/capture_console_history_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CaptureConsoleHistoryRequest wrapper for the CaptureConsoleHistory operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CaptureConsoleHistory.go.html to see an example of how to use CaptureConsoleHistoryRequest. +type CaptureConsoleHistoryRequest struct { + + // Console history details + CaptureConsoleHistoryDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CaptureConsoleHistoryRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CaptureConsoleHistoryRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CaptureConsoleHistoryRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CaptureConsoleHistoryRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CaptureConsoleHistoryResponse wrapper for the CaptureConsoleHistory operation +type CaptureConsoleHistoryResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ConsoleHistory instance + ConsoleHistory `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CaptureConsoleHistoryResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CaptureConsoleHistoryResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_backup_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_backup_compartment_details.go new file mode 100644 index 000000000..5ba61f922 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_backup_compartment_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeBootVolumeBackupCompartmentDetails Contains the details for the compartment to move the boot volume backup to. +type ChangeBootVolumeBackupCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the boot volume backup to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeBootVolumeBackupCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_backup_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_backup_compartment_request_response.go new file mode 100644 index 000000000..fa201ea21 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_backup_compartment_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeBootVolumeBackupCompartmentRequest wrapper for the ChangeBootVolumeBackupCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeBootVolumeBackupCompartment.go.html to see an example of how to use ChangeBootVolumeBackupCompartmentRequest. +type ChangeBootVolumeBackupCompartmentRequest struct { + + // The OCID of the boot volume backup. + BootVolumeBackupId *string `mandatory:"true" contributesTo:"path" name:"bootVolumeBackupId"` + + // Request to change the compartment of given boot volume backup. + ChangeBootVolumeBackupCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeBootVolumeBackupCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeBootVolumeBackupCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeBootVolumeBackupCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeBootVolumeBackupCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeBootVolumeBackupCompartmentResponse wrapper for the ChangeBootVolumeBackupCompartment operation +type ChangeBootVolumeBackupCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeBootVolumeBackupCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeBootVolumeBackupCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_compartment_details.go new file mode 100644 index 000000000..42833a50e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_compartment_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeBootVolumeCompartmentDetails Contains the details for the compartment to move the boot volume to. +type ChangeBootVolumeCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the boot volume to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeBootVolumeCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_compartment_request_response.go new file mode 100644 index 000000000..d0ec2501a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_boot_volume_compartment_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeBootVolumeCompartmentRequest wrapper for the ChangeBootVolumeCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeBootVolumeCompartment.go.html to see an example of how to use ChangeBootVolumeCompartmentRequest. +type ChangeBootVolumeCompartmentRequest struct { + + // The OCID of the boot volume. + BootVolumeId *string `mandatory:"true" contributesTo:"path" name:"bootVolumeId"` + + // Request to change the compartment of given boot volume. + ChangeBootVolumeCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeBootVolumeCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeBootVolumeCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeBootVolumeCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeBootVolumeCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeBootVolumeCompartmentResponse wrapper for the ChangeBootVolumeCompartment operation +type ChangeBootVolumeCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeBootVolumeCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeBootVolumeCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_byoip_range_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_byoip_range_compartment_details.go new file mode 100644 index 000000000..6213122f8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_byoip_range_compartment_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeByoipRangeCompartmentDetails The configuration details for the move operation. +type ChangeByoipRangeCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the destination compartment for the BYOIP CIDR block move. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeByoipRangeCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_byoip_range_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_byoip_range_compartment_request_response.go new file mode 100644 index 000000000..981f84d71 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_byoip_range_compartment_request_response.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeByoipRangeCompartmentRequest wrapper for the ChangeByoipRangeCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeByoipRangeCompartment.go.html to see an example of how to use ChangeByoipRangeCompartmentRequest. +type ChangeByoipRangeCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the `ByoipRange` resource containing the BYOIP CIDR block. + ByoipRangeId *string `mandatory:"true" contributesTo:"path" name:"byoipRangeId"` + + // Request to change the compartment of a BYOIP CIDR block. + ChangeByoipRangeCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeByoipRangeCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeByoipRangeCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeByoipRangeCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeByoipRangeCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeByoipRangeCompartmentResponse wrapper for the ChangeByoipRangeCompartment operation +type ChangeByoipRangeCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeByoipRangeCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeByoipRangeCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cluster_network_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cluster_network_compartment_details.go new file mode 100644 index 000000000..e3d703e5c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cluster_network_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeClusterNetworkCompartmentDetails The configuration details for the move operation. +type ChangeClusterNetworkCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment + // into which the resource should be moved. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeClusterNetworkCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cluster_network_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cluster_network_compartment_request_response.go new file mode 100644 index 000000000..ce3aa95f1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cluster_network_compartment_request_response.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeClusterNetworkCompartmentRequest wrapper for the ChangeClusterNetworkCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeClusterNetworkCompartment.go.html to see an example of how to use ChangeClusterNetworkCompartmentRequest. +type ChangeClusterNetworkCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the cluster network. + ClusterNetworkId *string `mandatory:"true" contributesTo:"path" name:"clusterNetworkId"` + + // Request to change the compartment of given cluster network. + ChangeClusterNetworkCompartmentDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeClusterNetworkCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeClusterNetworkCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeClusterNetworkCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeClusterNetworkCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeClusterNetworkCompartmentResponse wrapper for the ChangeClusterNetworkCompartment operation +type ChangeClusterNetworkCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeClusterNetworkCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeClusterNetworkCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_capacity_reservation_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_capacity_reservation_compartment_details.go new file mode 100644 index 000000000..a42ed41ce --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_capacity_reservation_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeComputeCapacityReservationCompartmentDetails Specifies the compartment to move the compute capacity reservation to. +type ChangeComputeCapacityReservationCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment + // to move the compute capacity reservation to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeComputeCapacityReservationCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_capacity_reservation_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_capacity_reservation_compartment_request_response.go new file mode 100644 index 000000000..775f089b2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_capacity_reservation_compartment_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeComputeCapacityReservationCompartmentRequest wrapper for the ChangeComputeCapacityReservationCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeComputeCapacityReservationCompartment.go.html to see an example of how to use ChangeComputeCapacityReservationCompartmentRequest. +type ChangeComputeCapacityReservationCompartmentRequest struct { + + // The OCID of the compute capacity reservation. + CapacityReservationId *string `mandatory:"true" contributesTo:"path" name:"capacityReservationId"` + + // The configuration details for the move operation. + ChangeComputeCapacityReservationCompartmentDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeComputeCapacityReservationCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeComputeCapacityReservationCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeComputeCapacityReservationCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeComputeCapacityReservationCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeComputeCapacityReservationCompartmentResponse wrapper for the ChangeComputeCapacityReservationCompartment operation +type ChangeComputeCapacityReservationCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response ChangeComputeCapacityReservationCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeComputeCapacityReservationCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_image_capability_schema_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_image_capability_schema_compartment_details.go new file mode 100644 index 000000000..d7c238d50 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_image_capability_schema_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeComputeImageCapabilitySchemaCompartmentDetails The configuration details for the move operation. +type ChangeComputeImageCapabilitySchemaCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to + // move the instance configuration to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeComputeImageCapabilitySchemaCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_image_capability_schema_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_image_capability_schema_compartment_request_response.go new file mode 100644 index 000000000..0fb882e51 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_compute_image_capability_schema_compartment_request_response.go @@ -0,0 +1,86 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeComputeImageCapabilitySchemaCompartmentRequest wrapper for the ChangeComputeImageCapabilitySchemaCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeComputeImageCapabilitySchemaCompartment.go.html to see an example of how to use ChangeComputeImageCapabilitySchemaCompartmentRequest. +type ChangeComputeImageCapabilitySchemaCompartmentRequest struct { + + // The id of the compute image capability schema or the image ocid + ComputeImageCapabilitySchemaId *string `mandatory:"true" contributesTo:"path" name:"computeImageCapabilitySchemaId"` + + // Compute Image Capability Schema change compartment details + ChangeComputeImageCapabilitySchemaCompartmentDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeComputeImageCapabilitySchemaCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeComputeImageCapabilitySchemaCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeComputeImageCapabilitySchemaCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeComputeImageCapabilitySchemaCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeComputeImageCapabilitySchemaCompartmentResponse wrapper for the ChangeComputeImageCapabilitySchemaCompartment operation +type ChangeComputeImageCapabilitySchemaCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeComputeImageCapabilitySchemaCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeComputeImageCapabilitySchemaCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cpe_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cpe_compartment_details.go new file mode 100644 index 000000000..089dca28d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cpe_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeCpeCompartmentDetails The configuration details for the move operation. +type ChangeCpeCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // CPE object to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeCpeCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cpe_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cpe_compartment_request_response.go new file mode 100644 index 000000000..35915e01d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cpe_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeCpeCompartmentRequest wrapper for the ChangeCpeCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeCpeCompartment.go.html to see an example of how to use ChangeCpeCompartmentRequest. +type ChangeCpeCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the CPE. + CpeId *string `mandatory:"true" contributesTo:"path" name:"cpeId"` + + // Request to change the compartment of a CPE. + ChangeCpeCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeCpeCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeCpeCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeCpeCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeCpeCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeCpeCompartmentResponse wrapper for the ChangeCpeCompartment operation +type ChangeCpeCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeCpeCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeCpeCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_compartment_details.go new file mode 100644 index 000000000..e998aafa1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeCrossConnectCompartmentDetails The configuration details for the move operation. +type ChangeCrossConnectCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // cross-connect to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeCrossConnectCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_compartment_request_response.go new file mode 100644 index 000000000..dc9e65309 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeCrossConnectCompartmentRequest wrapper for the ChangeCrossConnectCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeCrossConnectCompartment.go.html to see an example of how to use ChangeCrossConnectCompartmentRequest. +type ChangeCrossConnectCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the cross-connect. + CrossConnectId *string `mandatory:"true" contributesTo:"path" name:"crossConnectId"` + + // Request to change the compartment of a Cross Connect. + ChangeCrossConnectCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeCrossConnectCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeCrossConnectCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeCrossConnectCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeCrossConnectCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeCrossConnectCompartmentResponse wrapper for the ChangeCrossConnectCompartment operation +type ChangeCrossConnectCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeCrossConnectCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeCrossConnectCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_group_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_group_compartment_details.go new file mode 100644 index 000000000..a6e6a8647 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_group_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeCrossConnectGroupCompartmentDetails The configuration details for the move operation. +type ChangeCrossConnectGroupCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // cross-connect group to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeCrossConnectGroupCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_group_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_group_compartment_request_response.go new file mode 100644 index 000000000..7de4bbd18 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_cross_connect_group_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeCrossConnectGroupCompartmentRequest wrapper for the ChangeCrossConnectGroupCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeCrossConnectGroupCompartment.go.html to see an example of how to use ChangeCrossConnectGroupCompartmentRequest. +type ChangeCrossConnectGroupCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the cross-connect group. + CrossConnectGroupId *string `mandatory:"true" contributesTo:"path" name:"crossConnectGroupId"` + + // Request to change the compartment of a Cross Connect Group. + ChangeCrossConnectGroupCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeCrossConnectGroupCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeCrossConnectGroupCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeCrossConnectGroupCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeCrossConnectGroupCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeCrossConnectGroupCompartmentResponse wrapper for the ChangeCrossConnectGroupCompartment operation +type ChangeCrossConnectGroupCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeCrossConnectGroupCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeCrossConnectGroupCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_dedicated_vm_host_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_dedicated_vm_host_compartment_details.go new file mode 100644 index 000000000..3d285abe4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_dedicated_vm_host_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeDedicatedVmHostCompartmentDetails Specifies the compartment to move the dedicated virtual machine host to. +type ChangeDedicatedVmHostCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment + // to move the dedicated virtual machine host to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeDedicatedVmHostCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_dedicated_vm_host_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_dedicated_vm_host_compartment_request_response.go new file mode 100644 index 000000000..3adb6ed7f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_dedicated_vm_host_compartment_request_response.go @@ -0,0 +1,93 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeDedicatedVmHostCompartmentRequest wrapper for the ChangeDedicatedVmHostCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeDedicatedVmHostCompartment.go.html to see an example of how to use ChangeDedicatedVmHostCompartmentRequest. +type ChangeDedicatedVmHostCompartmentRequest struct { + + // The OCID of the dedicated VM host. + DedicatedVmHostId *string `mandatory:"true" contributesTo:"path" name:"dedicatedVmHostId"` + + // The request to move the dedicated virtual machine host to a different compartment. + ChangeDedicatedVmHostCompartmentDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeDedicatedVmHostCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeDedicatedVmHostCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeDedicatedVmHostCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeDedicatedVmHostCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeDedicatedVmHostCompartmentResponse wrapper for the ChangeDedicatedVmHostCompartment operation +type ChangeDedicatedVmHostCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response ChangeDedicatedVmHostCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeDedicatedVmHostCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_dhcp_options_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_dhcp_options_compartment_details.go new file mode 100644 index 000000000..dc70afaf5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_dhcp_options_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeDhcpOptionsCompartmentDetails The configuration details for the move operation. +type ChangeDhcpOptionsCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // set of DHCP options to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeDhcpOptionsCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_dhcp_options_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_dhcp_options_compartment_request_response.go new file mode 100644 index 000000000..2ee0f8230 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_dhcp_options_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeDhcpOptionsCompartmentRequest wrapper for the ChangeDhcpOptionsCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeDhcpOptionsCompartment.go.html to see an example of how to use ChangeDhcpOptionsCompartmentRequest. +type ChangeDhcpOptionsCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) for the set of DHCP options. + DhcpId *string `mandatory:"true" contributesTo:"path" name:"dhcpId"` + + // Request to change the compartment of a set of DHCP Options. + ChangeDhcpOptionsCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeDhcpOptionsCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeDhcpOptionsCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeDhcpOptionsCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeDhcpOptionsCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeDhcpOptionsCompartmentResponse wrapper for the ChangeDhcpOptionsCompartment operation +type ChangeDhcpOptionsCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeDhcpOptionsCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeDhcpOptionsCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_drg_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_drg_compartment_details.go new file mode 100644 index 000000000..eb67d6fcd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_drg_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeDrgCompartmentDetails The configuration details for the move operation. +type ChangeDrgCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // DRG to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeDrgCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_drg_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_drg_compartment_request_response.go new file mode 100644 index 000000000..98700f7c6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_drg_compartment_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeDrgCompartmentRequest wrapper for the ChangeDrgCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeDrgCompartment.go.html to see an example of how to use ChangeDrgCompartmentRequest. +type ChangeDrgCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"true" contributesTo:"path" name:"drgId"` + + // Request to change the compartment of a DRG. + ChangeDrgCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeDrgCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeDrgCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeDrgCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeDrgCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeDrgCompartmentResponse wrapper for the ChangeDrgCompartment operation +type ChangeDrgCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response ChangeDrgCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeDrgCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_i_p_sec_connection_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_i_p_sec_connection_compartment_request_response.go new file mode 100644 index 000000000..59310a3fb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_i_p_sec_connection_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeIPSecConnectionCompartmentRequest wrapper for the ChangeIPSecConnectionCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeIPSecConnectionCompartment.go.html to see an example of how to use ChangeIPSecConnectionCompartmentRequest. +type ChangeIPSecConnectionCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // Request to change the compartment of a IPSec connection. + ChangeIpSecConnectionCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeIPSecConnectionCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeIPSecConnectionCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeIPSecConnectionCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeIPSecConnectionCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeIPSecConnectionCompartmentResponse wrapper for the ChangeIPSecConnectionCompartment operation +type ChangeIPSecConnectionCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeIPSecConnectionCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeIPSecConnectionCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_image_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_image_compartment_details.go new file mode 100644 index 000000000..453568396 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_image_compartment_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeImageCompartmentDetails The configuration details for the move operation. +type ChangeImageCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the image to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeImageCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_image_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_image_compartment_request_response.go new file mode 100644 index 000000000..2efafee81 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_image_compartment_request_response.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeImageCompartmentRequest wrapper for the ChangeImageCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeImageCompartment.go.html to see an example of how to use ChangeImageCompartmentRequest. +type ChangeImageCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the image. + ImageId *string `mandatory:"true" contributesTo:"path" name:"imageId"` + + // Request to change the compartment of a given image. + ChangeImageCompartmentDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeImageCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeImageCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeImageCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeImageCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeImageCompartmentResponse wrapper for the ChangeImageCompartment operation +type ChangeImageCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeImageCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeImageCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_compartment_details.go new file mode 100644 index 000000000..daee77458 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_compartment_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeInstanceCompartmentDetails The configuration details for the move operation. +type ChangeInstanceCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the instance to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeInstanceCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_compartment_request_response.go new file mode 100644 index 000000000..e99c77220 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_compartment_request_response.go @@ -0,0 +1,93 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeInstanceCompartmentRequest wrapper for the ChangeInstanceCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeInstanceCompartment.go.html to see an example of how to use ChangeInstanceCompartmentRequest. +type ChangeInstanceCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance. + InstanceId *string `mandatory:"true" contributesTo:"path" name:"instanceId"` + + // Request to change the compartment of a given instance. + ChangeInstanceCompartmentDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeInstanceCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeInstanceCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeInstanceCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeInstanceCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeInstanceCompartmentResponse wrapper for the ChangeInstanceCompartment operation +type ChangeInstanceCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response ChangeInstanceCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeInstanceCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_configuration_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_configuration_compartment_details.go new file mode 100644 index 000000000..333bd3490 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_configuration_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeInstanceConfigurationCompartmentDetails The configuration details for the move operation. +type ChangeInstanceConfigurationCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to + // move the instance configuration to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeInstanceConfigurationCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_configuration_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_configuration_compartment_request_response.go new file mode 100644 index 000000000..d89efa277 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_configuration_compartment_request_response.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeInstanceConfigurationCompartmentRequest wrapper for the ChangeInstanceConfigurationCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeInstanceConfigurationCompartment.go.html to see an example of how to use ChangeInstanceConfigurationCompartmentRequest. +type ChangeInstanceConfigurationCompartmentRequest struct { + + // The OCID of the instance configuration. + InstanceConfigurationId *string `mandatory:"true" contributesTo:"path" name:"instanceConfigurationId"` + + // Request to change the compartment of given instance configuration. + ChangeInstanceConfigurationCompartmentDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeInstanceConfigurationCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeInstanceConfigurationCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeInstanceConfigurationCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeInstanceConfigurationCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeInstanceConfigurationCompartmentResponse wrapper for the ChangeInstanceConfigurationCompartment operation +type ChangeInstanceConfigurationCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeInstanceConfigurationCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeInstanceConfigurationCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_pool_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_pool_compartment_details.go new file mode 100644 index 000000000..5fc15c1a5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_pool_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeInstancePoolCompartmentDetails The configuration details for the move operation. +type ChangeInstancePoolCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to + // move the instance pool to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeInstancePoolCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_pool_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_pool_compartment_request_response.go new file mode 100644 index 000000000..e7d494bcb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_instance_pool_compartment_request_response.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeInstancePoolCompartmentRequest wrapper for the ChangeInstancePoolCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeInstancePoolCompartment.go.html to see an example of how to use ChangeInstancePoolCompartmentRequest. +type ChangeInstancePoolCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" contributesTo:"path" name:"instancePoolId"` + + // Request to change the compartment of given instance pool. + ChangeInstancePoolCompartmentDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeInstancePoolCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeInstancePoolCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeInstancePoolCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeInstancePoolCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeInstancePoolCompartmentResponse wrapper for the ChangeInstancePoolCompartment operation +type ChangeInstancePoolCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeInstancePoolCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeInstancePoolCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_internet_gateway_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_internet_gateway_compartment_details.go new file mode 100644 index 000000000..4d9c4c8ab --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_internet_gateway_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeInternetGatewayCompartmentDetails The configuration details for the move operation. +type ChangeInternetGatewayCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // internet gateway to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeInternetGatewayCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_internet_gateway_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_internet_gateway_compartment_request_response.go new file mode 100644 index 000000000..5aeba043e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_internet_gateway_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeInternetGatewayCompartmentRequest wrapper for the ChangeInternetGatewayCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeInternetGatewayCompartment.go.html to see an example of how to use ChangeInternetGatewayCompartmentRequest. +type ChangeInternetGatewayCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the internet gateway. + IgId *string `mandatory:"true" contributesTo:"path" name:"igId"` + + // Request to change the compartment of an internet gateway. + ChangeInternetGatewayCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeInternetGatewayCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeInternetGatewayCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeInternetGatewayCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeInternetGatewayCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeInternetGatewayCompartmentResponse wrapper for the ChangeInternetGatewayCompartment operation +type ChangeInternetGatewayCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeInternetGatewayCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeInternetGatewayCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_ip_sec_connection_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_ip_sec_connection_compartment_details.go new file mode 100644 index 000000000..576240b07 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_ip_sec_connection_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeIpSecConnectionCompartmentDetails The configuration details for the move operation. +type ChangeIpSecConnectionCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // IPSec connection to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeIpSecConnectionCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_local_peering_gateway_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_local_peering_gateway_compartment_details.go new file mode 100644 index 000000000..587dbd8e1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_local_peering_gateway_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeLocalPeeringGatewayCompartmentDetails The configuration details for the move operation. +type ChangeLocalPeeringGatewayCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // local peering gateway to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeLocalPeeringGatewayCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_local_peering_gateway_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_local_peering_gateway_compartment_request_response.go new file mode 100644 index 000000000..26a58af6d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_local_peering_gateway_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeLocalPeeringGatewayCompartmentRequest wrapper for the ChangeLocalPeeringGatewayCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeLocalPeeringGatewayCompartment.go.html to see an example of how to use ChangeLocalPeeringGatewayCompartmentRequest. +type ChangeLocalPeeringGatewayCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the local peering gateway. + LocalPeeringGatewayId *string `mandatory:"true" contributesTo:"path" name:"localPeeringGatewayId"` + + // Request to change the compartment of a given local peering gateway. + ChangeLocalPeeringGatewayCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeLocalPeeringGatewayCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeLocalPeeringGatewayCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeLocalPeeringGatewayCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeLocalPeeringGatewayCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeLocalPeeringGatewayCompartmentResponse wrapper for the ChangeLocalPeeringGatewayCompartment operation +type ChangeLocalPeeringGatewayCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeLocalPeeringGatewayCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeLocalPeeringGatewayCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_nat_gateway_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_nat_gateway_compartment_details.go new file mode 100644 index 000000000..56102a78d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_nat_gateway_compartment_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeNatGatewayCompartmentDetails The configuration details for the move operation. +type ChangeNatGatewayCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the NAT gateway to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeNatGatewayCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_nat_gateway_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_nat_gateway_compartment_request_response.go new file mode 100644 index 000000000..b369e56e7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_nat_gateway_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeNatGatewayCompartmentRequest wrapper for the ChangeNatGatewayCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeNatGatewayCompartment.go.html to see an example of how to use ChangeNatGatewayCompartmentRequest. +type ChangeNatGatewayCompartmentRequest struct { + + // The NAT gateway's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + NatGatewayId *string `mandatory:"true" contributesTo:"path" name:"natGatewayId"` + + // Request to change the compartment of a given NAT Gateway. + ChangeNatGatewayCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeNatGatewayCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeNatGatewayCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeNatGatewayCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeNatGatewayCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeNatGatewayCompartmentResponse wrapper for the ChangeNatGatewayCompartment operation +type ChangeNatGatewayCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeNatGatewayCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeNatGatewayCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_network_security_group_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_network_security_group_compartment_details.go new file mode 100644 index 000000000..7ba199f08 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_network_security_group_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeNetworkSecurityGroupCompartmentDetails The representation of ChangeNetworkSecurityGroupCompartmentDetails +type ChangeNetworkSecurityGroupCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the network + // security group to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeNetworkSecurityGroupCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_network_security_group_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_network_security_group_compartment_request_response.go new file mode 100644 index 000000000..fd69bcc04 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_network_security_group_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeNetworkSecurityGroupCompartmentRequest wrapper for the ChangeNetworkSecurityGroupCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeNetworkSecurityGroupCompartment.go.html to see an example of how to use ChangeNetworkSecurityGroupCompartmentRequest. +type ChangeNetworkSecurityGroupCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network security group. + NetworkSecurityGroupId *string `mandatory:"true" contributesTo:"path" name:"networkSecurityGroupId"` + + // Request to change the compartment of a network security group. + ChangeNetworkSecurityGroupCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeNetworkSecurityGroupCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeNetworkSecurityGroupCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeNetworkSecurityGroupCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeNetworkSecurityGroupCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeNetworkSecurityGroupCompartmentResponse wrapper for the ChangeNetworkSecurityGroupCompartment operation +type ChangeNetworkSecurityGroupCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeNetworkSecurityGroupCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeNetworkSecurityGroupCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_compartment_details.go new file mode 100644 index 000000000..90ee11c0f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangePublicIpCompartmentDetails The configuration details for the move operation. +type ChangePublicIpCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // public IP to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangePublicIpCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_compartment_request_response.go new file mode 100644 index 000000000..ea4bebe56 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangePublicIpCompartmentRequest wrapper for the ChangePublicIpCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangePublicIpCompartment.go.html to see an example of how to use ChangePublicIpCompartmentRequest. +type ChangePublicIpCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the public IP. + PublicIpId *string `mandatory:"true" contributesTo:"path" name:"publicIpId"` + + // Request to change the compartment of a Public IP. + ChangePublicIpCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangePublicIpCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangePublicIpCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangePublicIpCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangePublicIpCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangePublicIpCompartmentResponse wrapper for the ChangePublicIpCompartment operation +type ChangePublicIpCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangePublicIpCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangePublicIpCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_pool_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_pool_compartment_details.go new file mode 100644 index 000000000..cb8d285cb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_pool_compartment_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangePublicIpPoolCompartmentDetails The configuration details for the move operation. +type ChangePublicIpPoolCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the destination compartment for the public IP pool move. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangePublicIpPoolCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_pool_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_pool_compartment_request_response.go new file mode 100644 index 000000000..a8af54600 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_public_ip_pool_compartment_request_response.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangePublicIpPoolCompartmentRequest wrapper for the ChangePublicIpPoolCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangePublicIpPoolCompartment.go.html to see an example of how to use ChangePublicIpPoolCompartmentRequest. +type ChangePublicIpPoolCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the public IP pool. + PublicIpPoolId *string `mandatory:"true" contributesTo:"path" name:"publicIpPoolId"` + + // Request to change the compartment of a public IP pool. + ChangePublicIpPoolCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangePublicIpPoolCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangePublicIpPoolCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangePublicIpPoolCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangePublicIpPoolCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangePublicIpPoolCompartmentResponse wrapper for the ChangePublicIpPoolCompartment operation +type ChangePublicIpPoolCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangePublicIpPoolCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangePublicIpPoolCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_remote_peering_connection_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_remote_peering_connection_compartment_details.go new file mode 100644 index 000000000..04a7def8f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_remote_peering_connection_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeRemotePeeringConnectionCompartmentDetails The configuration details for the move operation. +type ChangeRemotePeeringConnectionCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // remote peering connection to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeRemotePeeringConnectionCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_remote_peering_connection_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_remote_peering_connection_compartment_request_response.go new file mode 100644 index 000000000..dc16eb8a5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_remote_peering_connection_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeRemotePeeringConnectionCompartmentRequest wrapper for the ChangeRemotePeeringConnectionCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeRemotePeeringConnectionCompartment.go.html to see an example of how to use ChangeRemotePeeringConnectionCompartmentRequest. +type ChangeRemotePeeringConnectionCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the remote peering connection (RPC). + RemotePeeringConnectionId *string `mandatory:"true" contributesTo:"path" name:"remotePeeringConnectionId"` + + // Request to change the compartment of a remote peering connection. + ChangeRemotePeeringConnectionCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeRemotePeeringConnectionCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeRemotePeeringConnectionCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeRemotePeeringConnectionCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeRemotePeeringConnectionCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeRemotePeeringConnectionCompartmentResponse wrapper for the ChangeRemotePeeringConnectionCompartment operation +type ChangeRemotePeeringConnectionCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeRemotePeeringConnectionCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeRemotePeeringConnectionCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_route_table_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_route_table_compartment_details.go new file mode 100644 index 000000000..49d1b8730 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_route_table_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeRouteTableCompartmentDetails The configuration details for the move operation. +type ChangeRouteTableCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // route table to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeRouteTableCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_route_table_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_route_table_compartment_request_response.go new file mode 100644 index 000000000..e41cd5b00 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_route_table_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeRouteTableCompartmentRequest wrapper for the ChangeRouteTableCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeRouteTableCompartment.go.html to see an example of how to use ChangeRouteTableCompartmentRequest. +type ChangeRouteTableCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the route table. + RtId *string `mandatory:"true" contributesTo:"path" name:"rtId"` + + // Request to change the compartment of a given route table. + ChangeRouteTableCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeRouteTableCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeRouteTableCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeRouteTableCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeRouteTableCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeRouteTableCompartmentResponse wrapper for the ChangeRouteTableCompartment operation +type ChangeRouteTableCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeRouteTableCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeRouteTableCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_security_list_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_security_list_compartment_details.go new file mode 100644 index 000000000..1a3b8a8f4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_security_list_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeSecurityListCompartmentDetails The configuration details for the move operation. +type ChangeSecurityListCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // security list to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeSecurityListCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_security_list_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_security_list_compartment_request_response.go new file mode 100644 index 000000000..16941c9b9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_security_list_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeSecurityListCompartmentRequest wrapper for the ChangeSecurityListCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeSecurityListCompartment.go.html to see an example of how to use ChangeSecurityListCompartmentRequest. +type ChangeSecurityListCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the security list. + SecurityListId *string `mandatory:"true" contributesTo:"path" name:"securityListId"` + + // Request to change the compartment of a given security list. + ChangeSecurityListCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeSecurityListCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeSecurityListCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeSecurityListCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeSecurityListCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeSecurityListCompartmentResponse wrapper for the ChangeSecurityListCompartment operation +type ChangeSecurityListCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeSecurityListCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeSecurityListCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_service_gateway_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_service_gateway_compartment_details.go new file mode 100644 index 000000000..d78a10a61 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_service_gateway_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeServiceGatewayCompartmentDetails The configuration details for the move operation. +type ChangeServiceGatewayCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // service gateway to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeServiceGatewayCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_service_gateway_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_service_gateway_compartment_request_response.go new file mode 100644 index 000000000..3762395b9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_service_gateway_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeServiceGatewayCompartmentRequest wrapper for the ChangeServiceGatewayCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeServiceGatewayCompartment.go.html to see an example of how to use ChangeServiceGatewayCompartmentRequest. +type ChangeServiceGatewayCompartmentRequest struct { + + // The service gateway's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + ServiceGatewayId *string `mandatory:"true" contributesTo:"path" name:"serviceGatewayId"` + + // Request to change the compartment of a given Service Gateway. + ChangeServiceGatewayCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeServiceGatewayCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeServiceGatewayCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeServiceGatewayCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeServiceGatewayCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeServiceGatewayCompartmentResponse wrapper for the ChangeServiceGatewayCompartment operation +type ChangeServiceGatewayCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeServiceGatewayCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeServiceGatewayCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_subnet_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_subnet_compartment_details.go new file mode 100644 index 000000000..21e899d88 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_subnet_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeSubnetCompartmentDetails The configuration details for the move operation. +type ChangeSubnetCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // subnet to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeSubnetCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_subnet_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_subnet_compartment_request_response.go new file mode 100644 index 000000000..8928ec07e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_subnet_compartment_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeSubnetCompartmentRequest wrapper for the ChangeSubnetCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeSubnetCompartment.go.html to see an example of how to use ChangeSubnetCompartmentRequest. +type ChangeSubnetCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the subnet. + SubnetId *string `mandatory:"true" contributesTo:"path" name:"subnetId"` + + // Request to change the compartment of a given subnet. + ChangeSubnetCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeSubnetCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeSubnetCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeSubnetCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeSubnetCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeSubnetCompartmentResponse wrapper for the ChangeSubnetCompartment operation +type ChangeSubnetCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response ChangeSubnetCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeSubnetCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_vcn_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_vcn_compartment_details.go new file mode 100644 index 000000000..fdd5dc890 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_vcn_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeVcnCompartmentDetails The configuration details for the move operation. +type ChangeVcnCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // VCN to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeVcnCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_vcn_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_vcn_compartment_request_response.go new file mode 100644 index 000000000..86d5e7fb8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_vcn_compartment_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeVcnCompartmentRequest wrapper for the ChangeVcnCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeVcnCompartment.go.html to see an example of how to use ChangeVcnCompartmentRequest. +type ChangeVcnCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"true" contributesTo:"path" name:"vcnId"` + + // Request to change the compartment of a given VCN. + ChangeVcnCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeVcnCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeVcnCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeVcnCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeVcnCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeVcnCompartmentResponse wrapper for the ChangeVcnCompartment operation +type ChangeVcnCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response ChangeVcnCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeVcnCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_virtual_circuit_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_virtual_circuit_compartment_details.go new file mode 100644 index 000000000..f7653fd0c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_virtual_circuit_compartment_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeVirtualCircuitCompartmentDetails The configuration details for the move operation. +type ChangeVirtualCircuitCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the + // virtual circuit to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeVirtualCircuitCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_virtual_circuit_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_virtual_circuit_compartment_request_response.go new file mode 100644 index 000000000..c3a495f60 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_virtual_circuit_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeVirtualCircuitCompartmentRequest wrapper for the ChangeVirtualCircuitCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeVirtualCircuitCompartment.go.html to see an example of how to use ChangeVirtualCircuitCompartmentRequest. +type ChangeVirtualCircuitCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the virtual circuit. + VirtualCircuitId *string `mandatory:"true" contributesTo:"path" name:"virtualCircuitId"` + + // Request to change the compartment of a virtual circuit. + ChangeVirtualCircuitCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeVirtualCircuitCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeVirtualCircuitCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeVirtualCircuitCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeVirtualCircuitCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeVirtualCircuitCompartmentResponse wrapper for the ChangeVirtualCircuitCompartment operation +type ChangeVirtualCircuitCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeVirtualCircuitCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeVirtualCircuitCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_vlan_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_vlan_compartment_details.go new file mode 100644 index 000000000..27ba5b2fd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_vlan_compartment_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeVlanCompartmentDetails The configuration details for the move operation. +type ChangeVlanCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the VLAN to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeVlanCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_vlan_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_vlan_compartment_request_response.go new file mode 100644 index 000000000..1d474a5f8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_vlan_compartment_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeVlanCompartmentRequest wrapper for the ChangeVlanCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeVlanCompartment.go.html to see an example of how to use ChangeVlanCompartmentRequest. +type ChangeVlanCompartmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VLAN. + VlanId *string `mandatory:"true" contributesTo:"path" name:"vlanId"` + + // Request to change the compartment of a given VLAN. + ChangeVlanCompartmentDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeVlanCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeVlanCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeVlanCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeVlanCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeVlanCompartmentResponse wrapper for the ChangeVlanCompartment operation +type ChangeVlanCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response ChangeVlanCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeVlanCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_backup_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_backup_compartment_details.go new file mode 100644 index 000000000..5237390c3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_backup_compartment_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeVolumeBackupCompartmentDetails Contains the details for the compartment to move the volume backup to. +type ChangeVolumeBackupCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the volume backup to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeVolumeBackupCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_backup_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_backup_compartment_request_response.go new file mode 100644 index 000000000..ad7bfc147 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_backup_compartment_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeVolumeBackupCompartmentRequest wrapper for the ChangeVolumeBackupCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeVolumeBackupCompartment.go.html to see an example of how to use ChangeVolumeBackupCompartmentRequest. +type ChangeVolumeBackupCompartmentRequest struct { + + // The OCID of the volume backup. + VolumeBackupId *string `mandatory:"true" contributesTo:"path" name:"volumeBackupId"` + + // Request to change the compartment of given volume backup. + ChangeVolumeBackupCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeVolumeBackupCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeVolumeBackupCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeVolumeBackupCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeVolumeBackupCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeVolumeBackupCompartmentResponse wrapper for the ChangeVolumeBackupCompartment operation +type ChangeVolumeBackupCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeVolumeBackupCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeVolumeBackupCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_compartment_details.go new file mode 100644 index 000000000..72fa3484d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_compartment_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeVolumeCompartmentDetails Contains the details for the compartment to move the volume to. +type ChangeVolumeCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the volume to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeVolumeCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_compartment_request_response.go new file mode 100644 index 000000000..b24678b93 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_compartment_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeVolumeCompartmentRequest wrapper for the ChangeVolumeCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeVolumeCompartment.go.html to see an example of how to use ChangeVolumeCompartmentRequest. +type ChangeVolumeCompartmentRequest struct { + + // The OCID of the volume. + VolumeId *string `mandatory:"true" contributesTo:"path" name:"volumeId"` + + // Request to change the compartment of given volume. + ChangeVolumeCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeVolumeCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeVolumeCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeVolumeCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeVolumeCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeVolumeCompartmentResponse wrapper for the ChangeVolumeCompartment operation +type ChangeVolumeCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeVolumeCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeVolumeCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_backup_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_backup_compartment_details.go new file mode 100644 index 000000000..6eaacc341 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_backup_compartment_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeVolumeGroupBackupCompartmentDetails Contains the details for the compartment to move the volume group backup to. +type ChangeVolumeGroupBackupCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the volume group backup to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeVolumeGroupBackupCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_backup_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_backup_compartment_request_response.go new file mode 100644 index 000000000..7559971de --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_backup_compartment_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeVolumeGroupBackupCompartmentRequest wrapper for the ChangeVolumeGroupBackupCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeVolumeGroupBackupCompartment.go.html to see an example of how to use ChangeVolumeGroupBackupCompartmentRequest. +type ChangeVolumeGroupBackupCompartmentRequest struct { + + // The Oracle Cloud ID (OCID) that uniquely identifies the volume group backup. + VolumeGroupBackupId *string `mandatory:"true" contributesTo:"path" name:"volumeGroupBackupId"` + + // Request to change the compartment of given volume group backup. + ChangeVolumeGroupBackupCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeVolumeGroupBackupCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeVolumeGroupBackupCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeVolumeGroupBackupCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeVolumeGroupBackupCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeVolumeGroupBackupCompartmentResponse wrapper for the ChangeVolumeGroupBackupCompartment operation +type ChangeVolumeGroupBackupCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeVolumeGroupBackupCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeVolumeGroupBackupCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_compartment_details.go new file mode 100644 index 000000000..ed9cff386 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_compartment_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeVolumeGroupCompartmentDetails Contains the details for the compartment to move the volume group to. +type ChangeVolumeGroupCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to move the volume group to. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeVolumeGroupCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_compartment_request_response.go new file mode 100644 index 000000000..e854cc553 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/change_volume_group_compartment_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeVolumeGroupCompartmentRequest wrapper for the ChangeVolumeGroupCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeVolumeGroupCompartment.go.html to see an example of how to use ChangeVolumeGroupCompartmentRequest. +type ChangeVolumeGroupCompartmentRequest struct { + + // The Oracle Cloud ID (OCID) that uniquely identifies the volume group. + VolumeGroupId *string `mandatory:"true" contributesTo:"path" name:"volumeGroupId"` + + // Request to change the compartment of given volume group. + ChangeVolumeGroupCompartmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeVolumeGroupCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeVolumeGroupCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeVolumeGroupCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeVolumeGroupCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeVolumeGroupCompartmentResponse wrapper for the ChangeVolumeGroupCompartment operation +type ChangeVolumeGroupCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeVolumeGroupCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeVolumeGroupCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cluster_network.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cluster_network.go new file mode 100644 index 000000000..886d2df09 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cluster_network.go @@ -0,0 +1,100 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ClusterNetwork A cluster network is a group of high performance computing (HPC) bare metal instances that are connected +// with an ultra low latency network. For more information about cluster networks, see +// Managing Cluster Networks (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/managingclusternetworks.htm). +type ClusterNetwork struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the cluster network. + Id *string `mandatory:"true" json:"id"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the cluster network. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The current state of the cluster network. + LifecycleState ClusterNetworkLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the resource was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The date and time the resource was updated, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeUpdated *common.SDKTime `mandatory:"true" json:"timeUpdated"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The instance pools in the cluster network. + // Each cluster network can have one instance pool. + InstancePools []InstancePool `mandatory:"false" json:"instancePools"` + + PlacementConfiguration *ClusterNetworkPlacementConfigurationDetails `mandatory:"false" json:"placementConfiguration"` +} + +func (m ClusterNetwork) String() string { + return common.PointerString(m) +} + +// ClusterNetworkLifecycleStateEnum Enum with underlying type: string +type ClusterNetworkLifecycleStateEnum string + +// Set of constants representing the allowable values for ClusterNetworkLifecycleStateEnum +const ( + ClusterNetworkLifecycleStateProvisioning ClusterNetworkLifecycleStateEnum = "PROVISIONING" + ClusterNetworkLifecycleStateScaling ClusterNetworkLifecycleStateEnum = "SCALING" + ClusterNetworkLifecycleStateStarting ClusterNetworkLifecycleStateEnum = "STARTING" + ClusterNetworkLifecycleStateStopping ClusterNetworkLifecycleStateEnum = "STOPPING" + ClusterNetworkLifecycleStateTerminating ClusterNetworkLifecycleStateEnum = "TERMINATING" + ClusterNetworkLifecycleStateStopped ClusterNetworkLifecycleStateEnum = "STOPPED" + ClusterNetworkLifecycleStateTerminated ClusterNetworkLifecycleStateEnum = "TERMINATED" + ClusterNetworkLifecycleStateRunning ClusterNetworkLifecycleStateEnum = "RUNNING" +) + +var mappingClusterNetworkLifecycleState = map[string]ClusterNetworkLifecycleStateEnum{ + "PROVISIONING": ClusterNetworkLifecycleStateProvisioning, + "SCALING": ClusterNetworkLifecycleStateScaling, + "STARTING": ClusterNetworkLifecycleStateStarting, + "STOPPING": ClusterNetworkLifecycleStateStopping, + "TERMINATING": ClusterNetworkLifecycleStateTerminating, + "STOPPED": ClusterNetworkLifecycleStateStopped, + "TERMINATED": ClusterNetworkLifecycleStateTerminated, + "RUNNING": ClusterNetworkLifecycleStateRunning, +} + +// GetClusterNetworkLifecycleStateEnumValues Enumerates the set of values for ClusterNetworkLifecycleStateEnum +func GetClusterNetworkLifecycleStateEnumValues() []ClusterNetworkLifecycleStateEnum { + values := make([]ClusterNetworkLifecycleStateEnum, 0) + for _, v := range mappingClusterNetworkLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cluster_network_placement_configuration_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cluster_network_placement_configuration_details.go new file mode 100644 index 000000000..bb99f84fa --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cluster_network_placement_configuration_details.go @@ -0,0 +1,37 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ClusterNetworkPlacementConfigurationDetails The location for where the instance pools in a cluster network will place instances. +type ClusterNetworkPlacementConfigurationDetails struct { + + // The availability domain to place instances. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the primary subnet to place + // instances. + PrimarySubnetId *string `mandatory:"true" json:"primarySubnetId"` + + // The set of secondary VNIC data for instances in the pool. + SecondaryVnicSubnets []InstancePoolPlacementSecondaryVnicSubnet `mandatory:"false" json:"secondaryVnicSubnets"` +} + +func (m ClusterNetworkPlacementConfigurationDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cluster_network_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cluster_network_summary.go new file mode 100644 index 000000000..030ef0f28 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cluster_network_summary.go @@ -0,0 +1,96 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ClusterNetworkSummary Summary information for a cluster network. +type ClusterNetworkSummary struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the cluster network. + Id *string `mandatory:"true" json:"id"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the + // cluster netowrk. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The current state of the cluster network. + LifecycleState ClusterNetworkSummaryLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the resource was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The date and time the resource was updated, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeUpdated *common.SDKTime `mandatory:"true" json:"timeUpdated"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The instance pools in the cluster network. + InstancePools []InstancePoolSummary `mandatory:"false" json:"instancePools"` +} + +func (m ClusterNetworkSummary) String() string { + return common.PointerString(m) +} + +// ClusterNetworkSummaryLifecycleStateEnum Enum with underlying type: string +type ClusterNetworkSummaryLifecycleStateEnum string + +// Set of constants representing the allowable values for ClusterNetworkSummaryLifecycleStateEnum +const ( + ClusterNetworkSummaryLifecycleStateProvisioning ClusterNetworkSummaryLifecycleStateEnum = "PROVISIONING" + ClusterNetworkSummaryLifecycleStateScaling ClusterNetworkSummaryLifecycleStateEnum = "SCALING" + ClusterNetworkSummaryLifecycleStateStarting ClusterNetworkSummaryLifecycleStateEnum = "STARTING" + ClusterNetworkSummaryLifecycleStateStopping ClusterNetworkSummaryLifecycleStateEnum = "STOPPING" + ClusterNetworkSummaryLifecycleStateTerminating ClusterNetworkSummaryLifecycleStateEnum = "TERMINATING" + ClusterNetworkSummaryLifecycleStateStopped ClusterNetworkSummaryLifecycleStateEnum = "STOPPED" + ClusterNetworkSummaryLifecycleStateTerminated ClusterNetworkSummaryLifecycleStateEnum = "TERMINATED" + ClusterNetworkSummaryLifecycleStateRunning ClusterNetworkSummaryLifecycleStateEnum = "RUNNING" +) + +var mappingClusterNetworkSummaryLifecycleState = map[string]ClusterNetworkSummaryLifecycleStateEnum{ + "PROVISIONING": ClusterNetworkSummaryLifecycleStateProvisioning, + "SCALING": ClusterNetworkSummaryLifecycleStateScaling, + "STARTING": ClusterNetworkSummaryLifecycleStateStarting, + "STOPPING": ClusterNetworkSummaryLifecycleStateStopping, + "TERMINATING": ClusterNetworkSummaryLifecycleStateTerminating, + "STOPPED": ClusterNetworkSummaryLifecycleStateStopped, + "TERMINATED": ClusterNetworkSummaryLifecycleStateTerminated, + "RUNNING": ClusterNetworkSummaryLifecycleStateRunning, +} + +// GetClusterNetworkSummaryLifecycleStateEnumValues Enumerates the set of values for ClusterNetworkSummaryLifecycleStateEnum +func GetClusterNetworkSummaryLifecycleStateEnumValues() []ClusterNetworkSummaryLifecycleStateEnum { + values := make([]ClusterNetworkSummaryLifecycleStateEnum, 0) + for _, v := range mappingClusterNetworkSummaryLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_capacity_reservation.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_capacity_reservation.go new file mode 100644 index 000000000..b042bc91c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_capacity_reservation.go @@ -0,0 +1,114 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ComputeCapacityReservation A template that defines the settings to use when creating compute capacity reservations. +type ComputeCapacityReservation struct { + + // The availability domain of the compute capacity reservation. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment + // containing the compute capacity reservation. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compute capacity reservation. + Id *string `mandatory:"true" json:"id"` + + // The current state of the compute capacity reservation. + LifecycleState ComputeCapacityReservationLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the compute capacity reservation was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Whether this capacity reservation is the default. + // For more information, see Capacity Reservations (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/reserve-capacity.htm#default). + IsDefaultReservation *bool `mandatory:"false" json:"isDefaultReservation"` + + // The capacity configurations for the capacity reservation. + // To use the reservation for the desired shape, specify the shape, count, and + // optionally the fault domain where you want this configuration. + InstanceReservationConfigs []InstanceReservationConfig `mandatory:"false" json:"instanceReservationConfigs"` + + // The number of instances for which capacity will be held with this + // compute capacity reservation. This number is the sum of the values of the `reservedCount` fields + // for all of the instance capacity configurations under this reservation. + // The purpose of this field is to calculate the percentage usage of the reservation. + ReservedInstanceCount *int64 `mandatory:"false" json:"reservedInstanceCount"` + + // The date and time the compute capacity reservation was updated, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeUpdated *common.SDKTime `mandatory:"false" json:"timeUpdated"` + + // The total number of instances currently consuming space in + // this compute capacity reservation. This number is the sum of the values of the `usedCount` fields + // for all of the instance capacity configurations under this reservation. + // The purpose of this field is to calculate the percentage usage of the reservation. + UsedInstanceCount *int64 `mandatory:"false" json:"usedInstanceCount"` +} + +func (m ComputeCapacityReservation) String() string { + return common.PointerString(m) +} + +// ComputeCapacityReservationLifecycleStateEnum Enum with underlying type: string +type ComputeCapacityReservationLifecycleStateEnum string + +// Set of constants representing the allowable values for ComputeCapacityReservationLifecycleStateEnum +const ( + ComputeCapacityReservationLifecycleStateActive ComputeCapacityReservationLifecycleStateEnum = "ACTIVE" + ComputeCapacityReservationLifecycleStateCreating ComputeCapacityReservationLifecycleStateEnum = "CREATING" + ComputeCapacityReservationLifecycleStateUpdating ComputeCapacityReservationLifecycleStateEnum = "UPDATING" + ComputeCapacityReservationLifecycleStateMoving ComputeCapacityReservationLifecycleStateEnum = "MOVING" + ComputeCapacityReservationLifecycleStateDeleted ComputeCapacityReservationLifecycleStateEnum = "DELETED" + ComputeCapacityReservationLifecycleStateDeleting ComputeCapacityReservationLifecycleStateEnum = "DELETING" +) + +var mappingComputeCapacityReservationLifecycleState = map[string]ComputeCapacityReservationLifecycleStateEnum{ + "ACTIVE": ComputeCapacityReservationLifecycleStateActive, + "CREATING": ComputeCapacityReservationLifecycleStateCreating, + "UPDATING": ComputeCapacityReservationLifecycleStateUpdating, + "MOVING": ComputeCapacityReservationLifecycleStateMoving, + "DELETED": ComputeCapacityReservationLifecycleStateDeleted, + "DELETING": ComputeCapacityReservationLifecycleStateDeleting, +} + +// GetComputeCapacityReservationLifecycleStateEnumValues Enumerates the set of values for ComputeCapacityReservationLifecycleStateEnum +func GetComputeCapacityReservationLifecycleStateEnumValues() []ComputeCapacityReservationLifecycleStateEnum { + values := make([]ComputeCapacityReservationLifecycleStateEnum, 0) + for _, v := range mappingComputeCapacityReservationLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_capacity_reservation_instance_shape_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_capacity_reservation_instance_shape_summary.go new file mode 100644 index 000000000..ebab7d8de --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_capacity_reservation_instance_shape_summary.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ComputeCapacityReservationInstanceShapeSummary An available shape used to launch instances in a compute capacity reservation. +type ComputeCapacityReservationInstanceShapeSummary struct { + + // The shape's availability domain. + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The name of the available shape used to launch instances in a compute capacity reservation. + InstanceShape *string `mandatory:"true" json:"instanceShape"` +} + +func (m ComputeCapacityReservationInstanceShapeSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_capacity_reservation_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_capacity_reservation_summary.go new file mode 100644 index 000000000..580a4d298 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_capacity_reservation_summary.go @@ -0,0 +1,72 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ComputeCapacityReservationSummary Summary information for a compute capacity reservation. +type ComputeCapacityReservationSummary struct { + + // The OCID of the instance reservation configuration. + Id *string `mandatory:"true" json:"id"` + + // The availability domain of the capacity reservation. + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The date and time the capacity reservation was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID of the compartment. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The current state of the capacity reservation. + LifecycleState ComputeCapacityReservationLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The number of instances for which capacity will be held in this + // compute capacity reservation. This number is the sum of the values of the `reservedCount` fields + // for all of the instance capacity configurations under this reservation. + // The purpose of this field is to calculate the percentage usage of the reservation. + ReservedInstanceCount *int64 `mandatory:"false" json:"reservedInstanceCount"` + + // The total number of instances currently consuming space in + // this compute capacity reservation. This number is the sum of the values of the `usedCount` fields + // for all of the instance capacity configurations under this reservation. + // The purpose of this field is to calculate the percentage usage of the reservation. + UsedInstanceCount *int64 `mandatory:"false" json:"usedInstanceCount"` + + // Whether this capacity reservation is the default. + // For more information, see Capacity Reservations (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/reserve-capacity.htm#default). + IsDefaultReservation *bool `mandatory:"false" json:"isDefaultReservation"` +} + +func (m ComputeCapacityReservationSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema.go new file mode 100644 index 000000000..57383937d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema.go @@ -0,0 +1,54 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ComputeGlobalImageCapabilitySchema Compute Global Image Capability Schema is a container for a set of compute global image capability schema versions +type ComputeGlobalImageCapabilitySchema struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compute global image capability schema + Id *string `mandatory:"true" json:"id"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The date and time the compute global image capability schema was created, in the format defined by + // RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID of the compartment that contains the resource. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The name of the global capabilities version resource that is considered the current version. + CurrentVersionName *string `mandatory:"false" json:"currentVersionName"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m ComputeGlobalImageCapabilitySchema) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema_summary.go new file mode 100644 index 000000000..a0e182456 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema_summary.go @@ -0,0 +1,54 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ComputeGlobalImageCapabilitySchemaSummary Summary information for a compute global image capability schema +type ComputeGlobalImageCapabilitySchemaSummary struct { + + // The compute global image capability schema OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + Id *string `mandatory:"true" json:"id"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The date and time the compute global image capability schema was created, in the format defined by + // RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID of the compartment containing the compute global image capability schema + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The name of the global capabilities version resource that is considered the current version. + CurrentVersionName *string `mandatory:"false" json:"currentVersionName"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m ComputeGlobalImageCapabilitySchemaSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema_version.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema_version.go new file mode 100644 index 000000000..a87a77294 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema_version.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ComputeGlobalImageCapabilitySchemaVersion Compute Global Image Capability Schema Version is a set of all possible capabilities for a collection of images. +type ComputeGlobalImageCapabilitySchemaVersion struct { + + // The name of the compute global image capability schema version + Name *string `mandatory:"true" json:"name"` + + // The ocid of the compute global image capability schema + ComputeGlobalImageCapabilitySchemaId *string `mandatory:"true" json:"computeGlobalImageCapabilitySchemaId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The map of each capability name to its ImageCapabilityDescriptor. + SchemaData map[string]ImageCapabilitySchemaDescriptor `mandatory:"true" json:"schemaData"` + + // The date and time the compute global image capability schema version was created, in the format defined by + // RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` +} + +func (m ComputeGlobalImageCapabilitySchemaVersion) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *ComputeGlobalImageCapabilitySchemaVersion) UnmarshalJSON(data []byte) (e error) { + model := struct { + Name *string `json:"name"` + ComputeGlobalImageCapabilitySchemaId *string `json:"computeGlobalImageCapabilitySchemaId"` + DisplayName *string `json:"displayName"` + SchemaData map[string]imagecapabilityschemadescriptor `json:"schemaData"` + TimeCreated *common.SDKTime `json:"timeCreated"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.Name = model.Name + + m.ComputeGlobalImageCapabilitySchemaId = model.ComputeGlobalImageCapabilitySchemaId + + m.DisplayName = model.DisplayName + + m.SchemaData = make(map[string]ImageCapabilitySchemaDescriptor) + for k, v := range model.SchemaData { + nn, e = v.UnmarshalPolymorphicJSON(v.JsonData) + if e != nil { + return e + } + if nn != nil { + m.SchemaData[k] = nn.(ImageCapabilitySchemaDescriptor) + } else { + m.SchemaData[k] = nil + } + } + + m.TimeCreated = model.TimeCreated + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema_version_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema_version_summary.go new file mode 100644 index 000000000..12638c85f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_global_image_capability_schema_version_summary.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ComputeGlobalImageCapabilitySchemaVersionSummary Summary information for a compute global image capability schema +type ComputeGlobalImageCapabilitySchemaVersionSummary struct { + + // The compute global image capability schema version name + Name *string `mandatory:"true" json:"name"` + + // The OCID of the compute global image capability schema + ComputeGlobalImageCapabilitySchemaId *string `mandatory:"true" json:"computeGlobalImageCapabilitySchemaId"` + + // The date and time the compute global image capability schema version was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` +} + +func (m ComputeGlobalImageCapabilitySchemaVersionSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_image_capability_schema.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_image_capability_schema.go new file mode 100644 index 000000000..28b0d265f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_image_capability_schema.go @@ -0,0 +1,119 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ComputeImageCapabilitySchema Compute Image Capability Schema is a set of capabilities that filter the compute global capability schema +// version for an image. +type ComputeImageCapabilitySchema struct { + + // The id of the compute global image capability schema version + Id *string `mandatory:"true" json:"id"` + + // The ocid of the compute global image capability schema + ComputeGlobalImageCapabilitySchemaId *string `mandatory:"true" json:"computeGlobalImageCapabilitySchemaId"` + + // The name of the compute global image capability schema version + ComputeGlobalImageCapabilitySchemaVersionName *string `mandatory:"true" json:"computeGlobalImageCapabilitySchemaVersionName"` + + // The OCID of the image associated with this compute image capability schema + ImageId *string `mandatory:"true" json:"imageId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The map of each capability name to its ImageCapabilityDescriptor. + SchemaData map[string]ImageCapabilitySchemaDescriptor `mandatory:"true" json:"schemaData"` + + // The date and time the compute image capability schema was created, in the format defined by + // RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID of the compartment that contains the resource. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m ComputeImageCapabilitySchema) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *ComputeImageCapabilitySchema) UnmarshalJSON(data []byte) (e error) { + model := struct { + CompartmentId *string `json:"compartmentId"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + FreeformTags map[string]string `json:"freeformTags"` + Id *string `json:"id"` + ComputeGlobalImageCapabilitySchemaId *string `json:"computeGlobalImageCapabilitySchemaId"` + ComputeGlobalImageCapabilitySchemaVersionName *string `json:"computeGlobalImageCapabilitySchemaVersionName"` + ImageId *string `json:"imageId"` + DisplayName *string `json:"displayName"` + SchemaData map[string]imagecapabilityschemadescriptor `json:"schemaData"` + TimeCreated *common.SDKTime `json:"timeCreated"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.CompartmentId = model.CompartmentId + + m.DefinedTags = model.DefinedTags + + m.FreeformTags = model.FreeformTags + + m.Id = model.Id + + m.ComputeGlobalImageCapabilitySchemaId = model.ComputeGlobalImageCapabilitySchemaId + + m.ComputeGlobalImageCapabilitySchemaVersionName = model.ComputeGlobalImageCapabilitySchemaVersionName + + m.ImageId = model.ImageId + + m.DisplayName = model.DisplayName + + m.SchemaData = make(map[string]ImageCapabilitySchemaDescriptor) + for k, v := range model.SchemaData { + nn, e = v.UnmarshalPolymorphicJSON(v.JsonData) + if e != nil { + return e + } + if nn != nil { + m.SchemaData[k] = nn.(ImageCapabilitySchemaDescriptor) + } else { + m.SchemaData[k] = nil + } + } + + m.TimeCreated = model.TimeCreated + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_image_capability_schema_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_image_capability_schema_summary.go new file mode 100644 index 000000000..c533467ba --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_image_capability_schema_summary.go @@ -0,0 +1,111 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ComputeImageCapabilitySchemaSummary Summary information for a compute image capability schema +type ComputeImageCapabilitySchemaSummary struct { + + // The compute image capability schema OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + Id *string `mandatory:"true" json:"id"` + + // The name of the compute global image capability schema version + ComputeGlobalImageCapabilitySchemaVersionName *string `mandatory:"true" json:"computeGlobalImageCapabilitySchemaVersionName"` + + // The OCID of the image associated with this compute image capability schema + ImageId *string `mandatory:"true" json:"imageId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The date and time the compute image capability schema was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID of the compartment containing the compute global image capability schema + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // A mapping of each capability name to its ImageCapabilityDescriptor. + SchemaData map[string]ImageCapabilitySchemaDescriptor `mandatory:"false" json:"schemaData"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m ComputeImageCapabilitySchemaSummary) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *ComputeImageCapabilitySchemaSummary) UnmarshalJSON(data []byte) (e error) { + model := struct { + CompartmentId *string `json:"compartmentId"` + SchemaData map[string]imagecapabilityschemadescriptor `json:"schemaData"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + FreeformTags map[string]string `json:"freeformTags"` + Id *string `json:"id"` + ComputeGlobalImageCapabilitySchemaVersionName *string `json:"computeGlobalImageCapabilitySchemaVersionName"` + ImageId *string `json:"imageId"` + DisplayName *string `json:"displayName"` + TimeCreated *common.SDKTime `json:"timeCreated"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.CompartmentId = model.CompartmentId + + m.SchemaData = make(map[string]ImageCapabilitySchemaDescriptor) + for k, v := range model.SchemaData { + nn, e = v.UnmarshalPolymorphicJSON(v.JsonData) + if e != nil { + return e + } + if nn != nil { + m.SchemaData[k] = nn.(ImageCapabilitySchemaDescriptor) + } else { + m.SchemaData[k] = nil + } + } + + m.DefinedTags = model.DefinedTags + + m.FreeformTags = model.FreeformTags + + m.Id = model.Id + + m.ComputeGlobalImageCapabilitySchemaVersionName = model.ComputeGlobalImageCapabilitySchemaVersionName + + m.ImageId = model.ImageId + + m.DisplayName = model.DisplayName + + m.TimeCreated = model.TimeCreated + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_instance_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_instance_details.go new file mode 100644 index 000000000..c82d005cf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/compute_instance_details.go @@ -0,0 +1,46 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ComputeInstanceDetails Compute Instance Configuration instance details. +type ComputeInstanceDetails struct { + BlockVolumes []InstanceConfigurationBlockVolumeDetails `mandatory:"false" json:"blockVolumes"` + + LaunchDetails *InstanceConfigurationLaunchInstanceDetails `mandatory:"false" json:"launchDetails"` + + SecondaryVnics []InstanceConfigurationAttachVnicDetails `mandatory:"false" json:"secondaryVnics"` +} + +func (m ComputeInstanceDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m ComputeInstanceDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeComputeInstanceDetails ComputeInstanceDetails + s := struct { + DiscriminatorParam string `json:"instanceType"` + MarshalTypeComputeInstanceDetails + }{ + "compute", + (MarshalTypeComputeInstanceDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/connect_local_peering_gateways_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/connect_local_peering_gateways_details.go new file mode 100644 index 000000000..66789f11d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/connect_local_peering_gateways_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ConnectLocalPeeringGatewaysDetails Information about the other local peering gateway (LPG). +type ConnectLocalPeeringGatewaysDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the LPG you want to peer with. + PeerId *string `mandatory:"true" json:"peerId"` +} + +func (m ConnectLocalPeeringGatewaysDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/connect_local_peering_gateways_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/connect_local_peering_gateways_request_response.go new file mode 100644 index 000000000..b87876fdc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/connect_local_peering_gateways_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ConnectLocalPeeringGatewaysRequest wrapper for the ConnectLocalPeeringGateways operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ConnectLocalPeeringGateways.go.html to see an example of how to use ConnectLocalPeeringGatewaysRequest. +type ConnectLocalPeeringGatewaysRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the local peering gateway. + LocalPeeringGatewayId *string `mandatory:"true" contributesTo:"path" name:"localPeeringGatewayId"` + + // Details regarding the local peering gateway to connect. + ConnectLocalPeeringGatewaysDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ConnectLocalPeeringGatewaysRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ConnectLocalPeeringGatewaysRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ConnectLocalPeeringGatewaysRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ConnectLocalPeeringGatewaysRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ConnectLocalPeeringGatewaysResponse wrapper for the ConnectLocalPeeringGateways operation +type ConnectLocalPeeringGatewaysResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ConnectLocalPeeringGatewaysResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ConnectLocalPeeringGatewaysResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/connect_remote_peering_connections_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/connect_remote_peering_connections_details.go new file mode 100644 index 000000000..a19641a4c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/connect_remote_peering_connections_details.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ConnectRemotePeeringConnectionsDetails Information about the other remote peering connection (RPC). +type ConnectRemotePeeringConnectionsDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the RPC you want to peer with. + PeerId *string `mandatory:"true" json:"peerId"` + + // The name of the region that contains the RPC you want to peer with. + // Example: `us-ashburn-1` + PeerRegionName *string `mandatory:"true" json:"peerRegionName"` +} + +func (m ConnectRemotePeeringConnectionsDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/connect_remote_peering_connections_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/connect_remote_peering_connections_request_response.go new file mode 100644 index 000000000..0deeaa851 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/connect_remote_peering_connections_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ConnectRemotePeeringConnectionsRequest wrapper for the ConnectRemotePeeringConnections operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ConnectRemotePeeringConnections.go.html to see an example of how to use ConnectRemotePeeringConnectionsRequest. +type ConnectRemotePeeringConnectionsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the remote peering connection (RPC). + RemotePeeringConnectionId *string `mandatory:"true" contributesTo:"path" name:"remotePeeringConnectionId"` + + // Details to connect peering connection with peering connection from remote region + ConnectRemotePeeringConnectionsDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ConnectRemotePeeringConnectionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ConnectRemotePeeringConnectionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ConnectRemotePeeringConnectionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ConnectRemotePeeringConnectionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ConnectRemotePeeringConnectionsResponse wrapper for the ConnectRemotePeeringConnections operation +type ConnectRemotePeeringConnectionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ConnectRemotePeeringConnectionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ConnectRemotePeeringConnectionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/console_history.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/console_history.go new file mode 100644 index 000000000..e8102952e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/console_history.go @@ -0,0 +1,91 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ConsoleHistory An instance's serial console data. It includes configuration messages that occur when the +// instance boots, such as kernel and BIOS messages, and is useful for checking the status of +// the instance or diagnosing problems. The console data is minimally formatted ASCII text. +// **Warning:** Oracle recommends that you avoid using any confidential information when you +// supply string values using the API. +type ConsoleHistory struct { + + // The availability domain of an instance. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the console history metadata object. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the instance this console history was fetched from. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // The current state of the console history. + LifecycleState ConsoleHistoryLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the history was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m ConsoleHistory) String() string { + return common.PointerString(m) +} + +// ConsoleHistoryLifecycleStateEnum Enum with underlying type: string +type ConsoleHistoryLifecycleStateEnum string + +// Set of constants representing the allowable values for ConsoleHistoryLifecycleStateEnum +const ( + ConsoleHistoryLifecycleStateRequested ConsoleHistoryLifecycleStateEnum = "REQUESTED" + ConsoleHistoryLifecycleStateGettingHistory ConsoleHistoryLifecycleStateEnum = "GETTING-HISTORY" + ConsoleHistoryLifecycleStateSucceeded ConsoleHistoryLifecycleStateEnum = "SUCCEEDED" + ConsoleHistoryLifecycleStateFailed ConsoleHistoryLifecycleStateEnum = "FAILED" +) + +var mappingConsoleHistoryLifecycleState = map[string]ConsoleHistoryLifecycleStateEnum{ + "REQUESTED": ConsoleHistoryLifecycleStateRequested, + "GETTING-HISTORY": ConsoleHistoryLifecycleStateGettingHistory, + "SUCCEEDED": ConsoleHistoryLifecycleStateSucceeded, + "FAILED": ConsoleHistoryLifecycleStateFailed, +} + +// GetConsoleHistoryLifecycleStateEnumValues Enumerates the set of values for ConsoleHistoryLifecycleStateEnum +func GetConsoleHistoryLifecycleStateEnumValues() []ConsoleHistoryLifecycleStateEnum { + values := make([]ConsoleHistoryLifecycleStateEnum, 0) + for _, v := range mappingConsoleHistoryLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_boot_volume_backup_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_boot_volume_backup_details.go new file mode 100644 index 000000000..2ade15c5f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_boot_volume_backup_details.go @@ -0,0 +1,43 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CopyBootVolumeBackupDetails The representation of CopyBootVolumeBackupDetails +type CopyBootVolumeBackupDetails struct { + + // The name of the destination region. + // Example: `us-ashburn-1` + DestinationRegion *string `mandatory:"true" json:"destinationRegion"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The OCID of the Key Management key in the destination region which will be the master encryption key + // for the copied boot volume backup. If you do not specify this attribute the boot volume backup + // will be encrypted with the Oracle-provided encryption key when it is copied to the destination region. + // + // For more information about the Key Management service and encryption keys, see + // Overview of Key Management (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` +} + +func (m CopyBootVolumeBackupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_boot_volume_backup_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_boot_volume_backup_request_response.go new file mode 100644 index 000000000..1e0e6b993 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_boot_volume_backup_request_response.go @@ -0,0 +1,97 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CopyBootVolumeBackupRequest wrapper for the CopyBootVolumeBackup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CopyBootVolumeBackup.go.html to see an example of how to use CopyBootVolumeBackupRequest. +type CopyBootVolumeBackupRequest struct { + + // The OCID of the boot volume backup. + BootVolumeBackupId *string `mandatory:"true" contributesTo:"path" name:"bootVolumeBackupId"` + + // Request to create a cross-region copy of given boot volume backup. + CopyBootVolumeBackupDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CopyBootVolumeBackupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CopyBootVolumeBackupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CopyBootVolumeBackupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CopyBootVolumeBackupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CopyBootVolumeBackupResponse wrapper for the CopyBootVolumeBackup operation +type CopyBootVolumeBackupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The BootVolumeBackup instance + BootVolumeBackup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` + + // Location of the resource. + Location *string `presentIn:"header" name:"location"` + + // Location of the resource. + ContentLocation *string `presentIn:"header" name:"content-location"` +} + +func (response CopyBootVolumeBackupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CopyBootVolumeBackupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_backup_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_backup_details.go new file mode 100644 index 000000000..7a784c944 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_backup_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CopyVolumeBackupDetails The representation of CopyVolumeBackupDetails +type CopyVolumeBackupDetails struct { + + // The name of the destination region. + // Example: `us-ashburn-1` + DestinationRegion *string `mandatory:"true" json:"destinationRegion"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The OCID of the Key Management key in the destination region which will be the master encryption key + // for the copied volume backup. + // If you do not specify this attribute the volume backup will be encrypted with the Oracle-provided encryption + // key when it is copied to the destination region. + // + // For more information about the Key Management service and encryption keys, see + // Overview of Key Management (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` +} + +func (m CopyVolumeBackupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_backup_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_backup_request_response.go new file mode 100644 index 000000000..cddf0bb72 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_backup_request_response.go @@ -0,0 +1,97 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CopyVolumeBackupRequest wrapper for the CopyVolumeBackup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CopyVolumeBackup.go.html to see an example of how to use CopyVolumeBackupRequest. +type CopyVolumeBackupRequest struct { + + // The OCID of the volume backup. + VolumeBackupId *string `mandatory:"true" contributesTo:"path" name:"volumeBackupId"` + + // Request to create a cross-region copy of given backup. + CopyVolumeBackupDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CopyVolumeBackupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CopyVolumeBackupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CopyVolumeBackupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CopyVolumeBackupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CopyVolumeBackupResponse wrapper for the CopyVolumeBackup operation +type CopyVolumeBackupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeBackup instance + VolumeBackup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` + + // Location of the resource. + Location *string `presentIn:"header" name:"location"` + + // Location of the resource. + ContentLocation *string `presentIn:"header" name:"content-location"` +} + +func (response CopyVolumeBackupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CopyVolumeBackupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_group_backup_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_group_backup_details.go new file mode 100644 index 000000000..90c239ff3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_group_backup_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CopyVolumeGroupBackupDetails The representation of CopyVolumeGroupBackupDetails +type CopyVolumeGroupBackupDetails struct { + + // The name of the destination region. + // Example: `us-ashburn-1` + DestinationRegion *string `mandatory:"true" json:"destinationRegion"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The OCID of the Key Management key in the destination region which will be the master encryption key + // for the copied volume group backup. + // If you do not specify this attribute the volume group backup will be encrypted with the Oracle-provided encryption + // key when it is copied to the destination region. + // + // For more information about the Key Management service and encryption keys, see + // Overview of Key Management (https://docs.cloud.oracle.com/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/Content/KeyManagement/Tasks/usingkeys.htm). + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` +} + +func (m CopyVolumeGroupBackupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_group_backup_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_group_backup_request_response.go new file mode 100644 index 000000000..487f4465e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/copy_volume_group_backup_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CopyVolumeGroupBackupRequest wrapper for the CopyVolumeGroupBackup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CopyVolumeGroupBackup.go.html to see an example of how to use CopyVolumeGroupBackupRequest. +type CopyVolumeGroupBackupRequest struct { + + // The Oracle Cloud ID (OCID) that uniquely identifies the volume group backup. + VolumeGroupBackupId *string `mandatory:"true" contributesTo:"path" name:"volumeGroupBackupId"` + + // Request to create a cross-region copy of given volume group backup. + CopyVolumeGroupBackupDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CopyVolumeGroupBackupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CopyVolumeGroupBackupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CopyVolumeGroupBackupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CopyVolumeGroupBackupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CopyVolumeGroupBackupResponse wrapper for the CopyVolumeGroupBackup operation +type CopyVolumeGroupBackupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeGroupBackup instance + VolumeGroupBackup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CopyVolumeGroupBackupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CopyVolumeGroupBackupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/core_blockstorage_client.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/core_blockstorage_client.go new file mode 100644 index 000000000..938110c1b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/core_blockstorage_client.go @@ -0,0 +1,3393 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "context" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" + "github.com/oracle/oci-go-sdk/v54/common/auth" + "net/http" +) + +//BlockstorageClient a client for Blockstorage +type BlockstorageClient struct { + common.BaseClient + config *common.ConfigurationProvider +} + +// NewBlockstorageClientWithConfigurationProvider Creates a new default Blockstorage client with the given configuration provider. +// the configuration provider will be used for the default signer as well as reading the region +func NewBlockstorageClientWithConfigurationProvider(configProvider common.ConfigurationProvider) (client BlockstorageClient, err error) { + provider, err := auth.GetGenericConfigurationProvider(configProvider) + if err != nil { + return client, err + } + baseClient, e := common.NewClientWithConfig(provider) + if e != nil { + return client, e + } + return newBlockstorageClientFromBaseClient(baseClient, provider) +} + +// NewBlockstorageClientWithOboToken Creates a new default Blockstorage client with the given configuration provider. +// The obotoken will be added to default headers and signed; the configuration provider will be used for the signer +// as well as reading the region +func NewBlockstorageClientWithOboToken(configProvider common.ConfigurationProvider, oboToken string) (client BlockstorageClient, err error) { + baseClient, err := common.NewClientWithOboToken(configProvider, oboToken) + if err != nil { + return client, err + } + + return newBlockstorageClientFromBaseClient(baseClient, configProvider) +} + +func newBlockstorageClientFromBaseClient(baseClient common.BaseClient, configProvider common.ConfigurationProvider) (client BlockstorageClient, err error) { + // Blockstorage service default circuit breaker is enabled + baseClient.Configuration.CircuitBreaker = common.NewCircuitBreaker(common.DefaultCircuitBreakerSetting()) + common.ConfigCircuitBreakerFromEnvVar(&baseClient) + common.ConfigCircuitBreakerFromGlobalVar(&baseClient) + + client = BlockstorageClient{BaseClient: baseClient} + client.BasePath = "20160918" + err = client.setConfigurationProvider(configProvider) + return +} + +// SetRegion overrides the region of this client. +func (client *BlockstorageClient) SetRegion(region string) { + client.Host = common.StringToRegion(region).EndpointForTemplate("iaas", "https://iaas.{region}.{secondLevelDomain}") +} + +// SetConfigurationProvider sets the configuration provider including the region, returns an error if is not valid +func (client *BlockstorageClient) setConfigurationProvider(configProvider common.ConfigurationProvider) error { + if ok, err := common.IsConfigurationProviderValid(configProvider); !ok { + return err + } + + // Error has been checked already + region, _ := configProvider.Region() + client.SetRegion(region) + client.config = &configProvider + return nil +} + +// ConfigurationProvider the ConfigurationProvider used in this client, or null if none set +func (client *BlockstorageClient) ConfigurationProvider() *common.ConfigurationProvider { + return client.config +} + +// ChangeBootVolumeBackupCompartment Moves a boot volume backup into a different compartment within the same tenancy. +// For information about moving resources between compartments, +// see Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeBootVolumeBackupCompartment.go.html to see an example of how to use ChangeBootVolumeBackupCompartment API. +func (client BlockstorageClient) ChangeBootVolumeBackupCompartment(ctx context.Context, request ChangeBootVolumeBackupCompartmentRequest) (response ChangeBootVolumeBackupCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.changeBootVolumeBackupCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeBootVolumeBackupCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeBootVolumeBackupCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeBootVolumeBackupCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeBootVolumeBackupCompartmentResponse") + } + return +} + +// changeBootVolumeBackupCompartment implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) changeBootVolumeBackupCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/bootVolumeBackups/{bootVolumeBackupId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeBootVolumeBackupCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeBootVolumeCompartment Moves a boot volume into a different compartment within the same tenancy. +// For information about moving resources between compartments, +// see Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeBootVolumeCompartment.go.html to see an example of how to use ChangeBootVolumeCompartment API. +func (client BlockstorageClient) ChangeBootVolumeCompartment(ctx context.Context, request ChangeBootVolumeCompartmentRequest) (response ChangeBootVolumeCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.changeBootVolumeCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeBootVolumeCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeBootVolumeCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeBootVolumeCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeBootVolumeCompartmentResponse") + } + return +} + +// changeBootVolumeCompartment implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) changeBootVolumeCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/bootVolumes/{bootVolumeId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeBootVolumeCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeVolumeBackupCompartment Moves a volume backup into a different compartment within the same tenancy. +// For information about moving resources between compartments, +// see Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeVolumeBackupCompartment.go.html to see an example of how to use ChangeVolumeBackupCompartment API. +func (client BlockstorageClient) ChangeVolumeBackupCompartment(ctx context.Context, request ChangeVolumeBackupCompartmentRequest) (response ChangeVolumeBackupCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.changeVolumeBackupCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeVolumeBackupCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeVolumeBackupCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeVolumeBackupCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeVolumeBackupCompartmentResponse") + } + return +} + +// changeVolumeBackupCompartment implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) changeVolumeBackupCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/volumeBackups/{volumeBackupId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeVolumeBackupCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeVolumeCompartment Moves a volume into a different compartment within the same tenancy. +// For information about moving resources between compartments, +// see Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeVolumeCompartment.go.html to see an example of how to use ChangeVolumeCompartment API. +func (client BlockstorageClient) ChangeVolumeCompartment(ctx context.Context, request ChangeVolumeCompartmentRequest) (response ChangeVolumeCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.changeVolumeCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeVolumeCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeVolumeCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeVolumeCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeVolumeCompartmentResponse") + } + return +} + +// changeVolumeCompartment implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) changeVolumeCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/volumes/{volumeId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeVolumeCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeVolumeGroupBackupCompartment Moves a volume group backup into a different compartment within the same tenancy. +// For information about moving resources between compartments, +// see Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeVolumeGroupBackupCompartment.go.html to see an example of how to use ChangeVolumeGroupBackupCompartment API. +func (client BlockstorageClient) ChangeVolumeGroupBackupCompartment(ctx context.Context, request ChangeVolumeGroupBackupCompartmentRequest) (response ChangeVolumeGroupBackupCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.changeVolumeGroupBackupCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeVolumeGroupBackupCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeVolumeGroupBackupCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeVolumeGroupBackupCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeVolumeGroupBackupCompartmentResponse") + } + return +} + +// changeVolumeGroupBackupCompartment implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) changeVolumeGroupBackupCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/volumeGroupBackups/{volumeGroupBackupId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeVolumeGroupBackupCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeVolumeGroupCompartment Moves a volume group into a different compartment within the same tenancy. +// For information about moving resources between compartments, +// see Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeVolumeGroupCompartment.go.html to see an example of how to use ChangeVolumeGroupCompartment API. +func (client BlockstorageClient) ChangeVolumeGroupCompartment(ctx context.Context, request ChangeVolumeGroupCompartmentRequest) (response ChangeVolumeGroupCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.changeVolumeGroupCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeVolumeGroupCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeVolumeGroupCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeVolumeGroupCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeVolumeGroupCompartmentResponse") + } + return +} + +// changeVolumeGroupCompartment implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) changeVolumeGroupCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/volumeGroups/{volumeGroupId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeVolumeGroupCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CopyBootVolumeBackup Creates a boot volume backup copy in specified region. For general information about volume backups, +// see Overview of Boot Volume Backups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/bootvolumebackups.htm) +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CopyBootVolumeBackup.go.html to see an example of how to use CopyBootVolumeBackup API. +func (client BlockstorageClient) CopyBootVolumeBackup(ctx context.Context, request CopyBootVolumeBackupRequest) (response CopyBootVolumeBackupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.copyBootVolumeBackup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CopyBootVolumeBackupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CopyBootVolumeBackupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CopyBootVolumeBackupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CopyBootVolumeBackupResponse") + } + return +} + +// copyBootVolumeBackup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) copyBootVolumeBackup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/bootVolumeBackups/{bootVolumeBackupId}/actions/copy", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CopyBootVolumeBackupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CopyVolumeBackup Creates a volume backup copy in specified region. For general information about volume backups, +// see Overview of Block Volume Service Backups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/blockvolumebackups.htm) +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CopyVolumeBackup.go.html to see an example of how to use CopyVolumeBackup API. +func (client BlockstorageClient) CopyVolumeBackup(ctx context.Context, request CopyVolumeBackupRequest) (response CopyVolumeBackupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.copyVolumeBackup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CopyVolumeBackupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CopyVolumeBackupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CopyVolumeBackupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CopyVolumeBackupResponse") + } + return +} + +// copyVolumeBackup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) copyVolumeBackup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/volumeBackups/{volumeBackupId}/actions/copy", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CopyVolumeBackupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CopyVolumeGroupBackup Creates a volume group backup copy in specified region. For general information about volume group backups, +// see Overview of Block Volume Service Backups (https://docs.cloud.oracle.com/Content/Block/Concepts/blockvolumebackups.htm) +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CopyVolumeGroupBackup.go.html to see an example of how to use CopyVolumeGroupBackup API. +func (client BlockstorageClient) CopyVolumeGroupBackup(ctx context.Context, request CopyVolumeGroupBackupRequest) (response CopyVolumeGroupBackupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.copyVolumeGroupBackup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CopyVolumeGroupBackupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CopyVolumeGroupBackupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CopyVolumeGroupBackupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CopyVolumeGroupBackupResponse") + } + return +} + +// copyVolumeGroupBackup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) copyVolumeGroupBackup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/volumeGroupBackups/{volumeGroupBackupId}/actions/copy", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CopyVolumeGroupBackupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateBootVolume Creates a new boot volume in the specified compartment from an existing boot volume or a boot volume backup. +// For general information about boot volumes, see Boot Volumes (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/bootvolumes.htm). +// You may optionally specify a *display name* for the volume, which is simply a friendly name or +// description. It does not have to be unique, and you can change it. Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateBootVolume.go.html to see an example of how to use CreateBootVolume API. +func (client BlockstorageClient) CreateBootVolume(ctx context.Context, request CreateBootVolumeRequest) (response CreateBootVolumeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createBootVolume, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateBootVolumeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateBootVolumeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateBootVolumeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateBootVolumeResponse") + } + return +} + +// createBootVolume implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) createBootVolume(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/bootVolumes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateBootVolumeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateBootVolumeBackup Creates a new boot volume backup of the specified boot volume. For general information about boot volume backups, +// see Overview of Boot Volume Backups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/bootvolumebackups.htm) +// When the request is received, the backup object is in a REQUEST_RECEIVED state. +// When the data is imaged, it goes into a CREATING state. +// After the backup is fully uploaded to the cloud, it goes into an AVAILABLE state. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateBootVolumeBackup.go.html to see an example of how to use CreateBootVolumeBackup API. +func (client BlockstorageClient) CreateBootVolumeBackup(ctx context.Context, request CreateBootVolumeBackupRequest) (response CreateBootVolumeBackupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createBootVolumeBackup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateBootVolumeBackupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateBootVolumeBackupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateBootVolumeBackupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateBootVolumeBackupResponse") + } + return +} + +// createBootVolumeBackup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) createBootVolumeBackup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/bootVolumeBackups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateBootVolumeBackupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateVolume Creates a new volume in the specified compartment. Volumes can be created in sizes ranging from +// 50 GB (51200 MB) to 32 TB (33554432 MB), in 1 GB (1024 MB) increments. By default, volumes are 1 TB (1048576 MB). +// For general information about block volumes, see +// Overview of Block Volume Service (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm). +// A volume and instance can be in separate compartments but must be in the same availability domain. +// For information about access control and compartments, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). For information about +// availability domains, see Regions and Availability Domains (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/regions.htm). +// To get a list of availability domains, use the `ListAvailabilityDomains` operation +// in the Identity and Access Management Service API. +// You may optionally specify a *display name* for the volume, which is simply a friendly name or +// description. It does not have to be unique, and you can change it. Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVolume.go.html to see an example of how to use CreateVolume API. +func (client BlockstorageClient) CreateVolume(ctx context.Context, request CreateVolumeRequest) (response CreateVolumeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createVolume, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateVolumeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateVolumeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateVolumeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateVolumeResponse") + } + return +} + +// createVolume implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) createVolume(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/volumes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateVolumeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateVolumeBackup Creates a new backup of the specified volume. For general information about volume backups, +// see Overview of Block Volume Service Backups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/blockvolumebackups.htm) +// When the request is received, the backup object is in a REQUEST_RECEIVED state. +// When the data is imaged, it goes into a CREATING state. +// After the backup is fully uploaded to the cloud, it goes into an AVAILABLE state. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVolumeBackup.go.html to see an example of how to use CreateVolumeBackup API. +func (client BlockstorageClient) CreateVolumeBackup(ctx context.Context, request CreateVolumeBackupRequest) (response CreateVolumeBackupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createVolumeBackup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateVolumeBackupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateVolumeBackupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateVolumeBackupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateVolumeBackupResponse") + } + return +} + +// createVolumeBackup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) createVolumeBackup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/volumeBackups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateVolumeBackupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateVolumeBackupPolicy Creates a new user defined backup policy. +// For more information about Oracle defined backup policies and user defined backup policies, +// see Policy-Based Backups (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVolumeBackupPolicy.go.html to see an example of how to use CreateVolumeBackupPolicy API. +func (client BlockstorageClient) CreateVolumeBackupPolicy(ctx context.Context, request CreateVolumeBackupPolicyRequest) (response CreateVolumeBackupPolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createVolumeBackupPolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateVolumeBackupPolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateVolumeBackupPolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateVolumeBackupPolicyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateVolumeBackupPolicyResponse") + } + return +} + +// createVolumeBackupPolicy implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) createVolumeBackupPolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/volumeBackupPolicies", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateVolumeBackupPolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateVolumeBackupPolicyAssignment Assigns a volume backup policy to the specified volume. Note that a given volume can +// only have one backup policy assigned to it. If this operation is used for a volume that already +// has a different backup policy assigned, the prior backup policy will be silently unassigned. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVolumeBackupPolicyAssignment.go.html to see an example of how to use CreateVolumeBackupPolicyAssignment API. +func (client BlockstorageClient) CreateVolumeBackupPolicyAssignment(ctx context.Context, request CreateVolumeBackupPolicyAssignmentRequest) (response CreateVolumeBackupPolicyAssignmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.createVolumeBackupPolicyAssignment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateVolumeBackupPolicyAssignmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateVolumeBackupPolicyAssignmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateVolumeBackupPolicyAssignmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateVolumeBackupPolicyAssignmentResponse") + } + return +} + +// createVolumeBackupPolicyAssignment implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) createVolumeBackupPolicyAssignment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/volumeBackupPolicyAssignments", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateVolumeBackupPolicyAssignmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateVolumeGroup Creates a new volume group in the specified compartment. +// A volume group is a collection of volumes and may be created from a list of volumes, cloning an existing +// volume group, or by restoring a volume group backup. +// You may optionally specify a *display name* for the volume group, which is simply a friendly name or +// description. It does not have to be unique, and you can change it. Avoid entering confidential information. +// For more information, see Volume Groups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/volumegroups.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVolumeGroup.go.html to see an example of how to use CreateVolumeGroup API. +func (client BlockstorageClient) CreateVolumeGroup(ctx context.Context, request CreateVolumeGroupRequest) (response CreateVolumeGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createVolumeGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateVolumeGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateVolumeGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateVolumeGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateVolumeGroupResponse") + } + return +} + +// createVolumeGroup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) createVolumeGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/volumeGroups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateVolumeGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateVolumeGroupBackup Creates a new backup volume group of the specified volume group. +// For more information, see Volume Groups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/volumegroups.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVolumeGroupBackup.go.html to see an example of how to use CreateVolumeGroupBackup API. +func (client BlockstorageClient) CreateVolumeGroupBackup(ctx context.Context, request CreateVolumeGroupBackupRequest) (response CreateVolumeGroupBackupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createVolumeGroupBackup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateVolumeGroupBackupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateVolumeGroupBackupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateVolumeGroupBackupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateVolumeGroupBackupResponse") + } + return +} + +// createVolumeGroupBackup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) createVolumeGroupBackup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/volumeGroupBackups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateVolumeGroupBackupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteBootVolume Deletes the specified boot volume. The volume cannot have an active connection to an instance. +// To disconnect the boot volume from a connected instance, see +// Disconnecting From a Boot Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/deletingbootvolume.htm). +// **Warning:** All data on the boot volume will be permanently lost when the boot volume is deleted. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteBootVolume.go.html to see an example of how to use DeleteBootVolume API. +func (client BlockstorageClient) DeleteBootVolume(ctx context.Context, request DeleteBootVolumeRequest) (response DeleteBootVolumeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteBootVolume, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteBootVolumeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteBootVolumeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteBootVolumeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteBootVolumeResponse") + } + return +} + +// deleteBootVolume implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) deleteBootVolume(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/bootVolumes/{bootVolumeId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteBootVolumeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteBootVolumeBackup Deletes a boot volume backup. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteBootVolumeBackup.go.html to see an example of how to use DeleteBootVolumeBackup API. +func (client BlockstorageClient) DeleteBootVolumeBackup(ctx context.Context, request DeleteBootVolumeBackupRequest) (response DeleteBootVolumeBackupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteBootVolumeBackup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteBootVolumeBackupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteBootVolumeBackupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteBootVolumeBackupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteBootVolumeBackupResponse") + } + return +} + +// deleteBootVolumeBackup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) deleteBootVolumeBackup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/bootVolumeBackups/{bootVolumeBackupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteBootVolumeBackupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteBootVolumeKmsKey Removes the specified boot volume's assigned Key Management encryption key. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteBootVolumeKmsKey.go.html to see an example of how to use DeleteBootVolumeKmsKey API. +func (client BlockstorageClient) DeleteBootVolumeKmsKey(ctx context.Context, request DeleteBootVolumeKmsKeyRequest) (response DeleteBootVolumeKmsKeyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteBootVolumeKmsKey, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteBootVolumeKmsKeyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteBootVolumeKmsKeyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteBootVolumeKmsKeyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteBootVolumeKmsKeyResponse") + } + return +} + +// deleteBootVolumeKmsKey implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) deleteBootVolumeKmsKey(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/bootVolumes/{bootVolumeId}/kmsKey", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteBootVolumeKmsKeyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteVolume Deletes the specified volume. The volume cannot have an active connection to an instance. +// To disconnect the volume from a connected instance, see +// Disconnecting From a Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/disconnectingfromavolume.htm). +// **Warning:** All data on the volume will be permanently lost when the volume is deleted. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVolume.go.html to see an example of how to use DeleteVolume API. +func (client BlockstorageClient) DeleteVolume(ctx context.Context, request DeleteVolumeRequest) (response DeleteVolumeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteVolume, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteVolumeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteVolumeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteVolumeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteVolumeResponse") + } + return +} + +// deleteVolume implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) deleteVolume(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/volumes/{volumeId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteVolumeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteVolumeBackup Deletes a volume backup. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVolumeBackup.go.html to see an example of how to use DeleteVolumeBackup API. +func (client BlockstorageClient) DeleteVolumeBackup(ctx context.Context, request DeleteVolumeBackupRequest) (response DeleteVolumeBackupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteVolumeBackup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteVolumeBackupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteVolumeBackupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteVolumeBackupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteVolumeBackupResponse") + } + return +} + +// deleteVolumeBackup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) deleteVolumeBackup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/volumeBackups/{volumeBackupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteVolumeBackupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteVolumeBackupPolicy Deletes a user defined backup policy. +// For more information about user defined backup policies, +// see Policy-Based Backups (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm#UserDefinedBackupPolicies). +// Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVolumeBackupPolicy.go.html to see an example of how to use DeleteVolumeBackupPolicy API. +func (client BlockstorageClient) DeleteVolumeBackupPolicy(ctx context.Context, request DeleteVolumeBackupPolicyRequest) (response DeleteVolumeBackupPolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteVolumeBackupPolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteVolumeBackupPolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteVolumeBackupPolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteVolumeBackupPolicyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteVolumeBackupPolicyResponse") + } + return +} + +// deleteVolumeBackupPolicy implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) deleteVolumeBackupPolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/volumeBackupPolicies/{policyId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteVolumeBackupPolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteVolumeBackupPolicyAssignment Deletes a volume backup policy assignment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVolumeBackupPolicyAssignment.go.html to see an example of how to use DeleteVolumeBackupPolicyAssignment API. +func (client BlockstorageClient) DeleteVolumeBackupPolicyAssignment(ctx context.Context, request DeleteVolumeBackupPolicyAssignmentRequest) (response DeleteVolumeBackupPolicyAssignmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteVolumeBackupPolicyAssignment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteVolumeBackupPolicyAssignmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteVolumeBackupPolicyAssignmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteVolumeBackupPolicyAssignmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteVolumeBackupPolicyAssignmentResponse") + } + return +} + +// deleteVolumeBackupPolicyAssignment implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) deleteVolumeBackupPolicyAssignment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/volumeBackupPolicyAssignments/{policyAssignmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteVolumeBackupPolicyAssignmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteVolumeGroup Deletes the specified volume group. Individual volumes are not deleted, only the volume group is deleted. +// For more information, see Volume Groups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/volumegroups.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVolumeGroup.go.html to see an example of how to use DeleteVolumeGroup API. +func (client BlockstorageClient) DeleteVolumeGroup(ctx context.Context, request DeleteVolumeGroupRequest) (response DeleteVolumeGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteVolumeGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteVolumeGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteVolumeGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteVolumeGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteVolumeGroupResponse") + } + return +} + +// deleteVolumeGroup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) deleteVolumeGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/volumeGroups/{volumeGroupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteVolumeGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteVolumeGroupBackup Deletes a volume group backup. This operation deletes all the backups in +// the volume group. For more information, see Volume Groups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/volumegroups.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVolumeGroupBackup.go.html to see an example of how to use DeleteVolumeGroupBackup API. +func (client BlockstorageClient) DeleteVolumeGroupBackup(ctx context.Context, request DeleteVolumeGroupBackupRequest) (response DeleteVolumeGroupBackupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteVolumeGroupBackup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteVolumeGroupBackupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteVolumeGroupBackupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteVolumeGroupBackupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteVolumeGroupBackupResponse") + } + return +} + +// deleteVolumeGroupBackup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) deleteVolumeGroupBackup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/volumeGroupBackups/{volumeGroupBackupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteVolumeGroupBackupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteVolumeKmsKey Removes the specified volume's assigned Key Management encryption key. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVolumeKmsKey.go.html to see an example of how to use DeleteVolumeKmsKey API. +func (client BlockstorageClient) DeleteVolumeKmsKey(ctx context.Context, request DeleteVolumeKmsKeyRequest) (response DeleteVolumeKmsKeyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteVolumeKmsKey, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteVolumeKmsKeyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteVolumeKmsKeyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteVolumeKmsKeyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteVolumeKmsKeyResponse") + } + return +} + +// deleteVolumeKmsKey implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) deleteVolumeKmsKey(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/volumes/{volumeId}/kmsKey", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteVolumeKmsKeyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetBlockVolumeReplica Gets information for the specified block volume replica. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetBlockVolumeReplica.go.html to see an example of how to use GetBlockVolumeReplica API. +func (client BlockstorageClient) GetBlockVolumeReplica(ctx context.Context, request GetBlockVolumeReplicaRequest) (response GetBlockVolumeReplicaResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getBlockVolumeReplica, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetBlockVolumeReplicaResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetBlockVolumeReplicaResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetBlockVolumeReplicaResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetBlockVolumeReplicaResponse") + } + return +} + +// getBlockVolumeReplica implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) getBlockVolumeReplica(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/blockVolumeReplicas/{blockVolumeReplicaId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetBlockVolumeReplicaResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetBootVolume Gets information for the specified boot volume. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetBootVolume.go.html to see an example of how to use GetBootVolume API. +func (client BlockstorageClient) GetBootVolume(ctx context.Context, request GetBootVolumeRequest) (response GetBootVolumeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getBootVolume, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetBootVolumeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetBootVolumeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetBootVolumeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetBootVolumeResponse") + } + return +} + +// getBootVolume implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) getBootVolume(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/bootVolumes/{bootVolumeId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetBootVolumeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetBootVolumeBackup Gets information for the specified boot volume backup. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetBootVolumeBackup.go.html to see an example of how to use GetBootVolumeBackup API. +func (client BlockstorageClient) GetBootVolumeBackup(ctx context.Context, request GetBootVolumeBackupRequest) (response GetBootVolumeBackupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getBootVolumeBackup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetBootVolumeBackupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetBootVolumeBackupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetBootVolumeBackupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetBootVolumeBackupResponse") + } + return +} + +// getBootVolumeBackup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) getBootVolumeBackup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/bootVolumeBackups/{bootVolumeBackupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetBootVolumeBackupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetBootVolumeKmsKey Gets the Key Management encryption key assigned to the specified boot volume. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetBootVolumeKmsKey.go.html to see an example of how to use GetBootVolumeKmsKey API. +func (client BlockstorageClient) GetBootVolumeKmsKey(ctx context.Context, request GetBootVolumeKmsKeyRequest) (response GetBootVolumeKmsKeyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getBootVolumeKmsKey, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetBootVolumeKmsKeyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetBootVolumeKmsKeyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetBootVolumeKmsKeyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetBootVolumeKmsKeyResponse") + } + return +} + +// getBootVolumeKmsKey implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) getBootVolumeKmsKey(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/bootVolumes/{bootVolumeId}/kmsKey", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetBootVolumeKmsKeyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetBootVolumeReplica Gets information for the specified boot volume replica. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetBootVolumeReplica.go.html to see an example of how to use GetBootVolumeReplica API. +func (client BlockstorageClient) GetBootVolumeReplica(ctx context.Context, request GetBootVolumeReplicaRequest) (response GetBootVolumeReplicaResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getBootVolumeReplica, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetBootVolumeReplicaResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetBootVolumeReplicaResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetBootVolumeReplicaResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetBootVolumeReplicaResponse") + } + return +} + +// getBootVolumeReplica implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) getBootVolumeReplica(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/bootVolumeReplicas/{bootVolumeReplicaId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetBootVolumeReplicaResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVolume Gets information for the specified volume. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolume.go.html to see an example of how to use GetVolume API. +func (client BlockstorageClient) GetVolume(ctx context.Context, request GetVolumeRequest) (response GetVolumeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVolume, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVolumeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVolumeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVolumeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVolumeResponse") + } + return +} + +// getVolume implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) getVolume(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/volumes/{volumeId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVolumeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVolumeBackup Gets information for the specified volume backup. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeBackup.go.html to see an example of how to use GetVolumeBackup API. +func (client BlockstorageClient) GetVolumeBackup(ctx context.Context, request GetVolumeBackupRequest) (response GetVolumeBackupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVolumeBackup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVolumeBackupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVolumeBackupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVolumeBackupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVolumeBackupResponse") + } + return +} + +// getVolumeBackup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) getVolumeBackup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/volumeBackups/{volumeBackupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVolumeBackupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVolumeBackupPolicy Gets information for the specified volume backup policy. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeBackupPolicy.go.html to see an example of how to use GetVolumeBackupPolicy API. +func (client BlockstorageClient) GetVolumeBackupPolicy(ctx context.Context, request GetVolumeBackupPolicyRequest) (response GetVolumeBackupPolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVolumeBackupPolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVolumeBackupPolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVolumeBackupPolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVolumeBackupPolicyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVolumeBackupPolicyResponse") + } + return +} + +// getVolumeBackupPolicy implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) getVolumeBackupPolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/volumeBackupPolicies/{policyId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVolumeBackupPolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVolumeBackupPolicyAssetAssignment Gets the volume backup policy assignment for the specified volume. The +// `assetId` query parameter is required, and the returned list will contain at most +// one item, since volume can only have one volume backup policy assigned at a time. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeBackupPolicyAssetAssignment.go.html to see an example of how to use GetVolumeBackupPolicyAssetAssignment API. +func (client BlockstorageClient) GetVolumeBackupPolicyAssetAssignment(ctx context.Context, request GetVolumeBackupPolicyAssetAssignmentRequest) (response GetVolumeBackupPolicyAssetAssignmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVolumeBackupPolicyAssetAssignment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVolumeBackupPolicyAssetAssignmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVolumeBackupPolicyAssetAssignmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVolumeBackupPolicyAssetAssignmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVolumeBackupPolicyAssetAssignmentResponse") + } + return +} + +// getVolumeBackupPolicyAssetAssignment implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) getVolumeBackupPolicyAssetAssignment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/volumeBackupPolicyAssignments", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVolumeBackupPolicyAssetAssignmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVolumeBackupPolicyAssignment Gets information for the specified volume backup policy assignment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeBackupPolicyAssignment.go.html to see an example of how to use GetVolumeBackupPolicyAssignment API. +func (client BlockstorageClient) GetVolumeBackupPolicyAssignment(ctx context.Context, request GetVolumeBackupPolicyAssignmentRequest) (response GetVolumeBackupPolicyAssignmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVolumeBackupPolicyAssignment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVolumeBackupPolicyAssignmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVolumeBackupPolicyAssignmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVolumeBackupPolicyAssignmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVolumeBackupPolicyAssignmentResponse") + } + return +} + +// getVolumeBackupPolicyAssignment implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) getVolumeBackupPolicyAssignment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/volumeBackupPolicyAssignments/{policyAssignmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVolumeBackupPolicyAssignmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVolumeGroup Gets information for the specified volume group. For more information, see Volume Groups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/volumegroups.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeGroup.go.html to see an example of how to use GetVolumeGroup API. +func (client BlockstorageClient) GetVolumeGroup(ctx context.Context, request GetVolumeGroupRequest) (response GetVolumeGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVolumeGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVolumeGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVolumeGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVolumeGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVolumeGroupResponse") + } + return +} + +// getVolumeGroup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) getVolumeGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/volumeGroups/{volumeGroupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVolumeGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVolumeGroupBackup Gets information for the specified volume group backup. For more information, see Volume Groups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/volumegroups.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeGroupBackup.go.html to see an example of how to use GetVolumeGroupBackup API. +func (client BlockstorageClient) GetVolumeGroupBackup(ctx context.Context, request GetVolumeGroupBackupRequest) (response GetVolumeGroupBackupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVolumeGroupBackup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVolumeGroupBackupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVolumeGroupBackupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVolumeGroupBackupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVolumeGroupBackupResponse") + } + return +} + +// getVolumeGroupBackup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) getVolumeGroupBackup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/volumeGroupBackups/{volumeGroupBackupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVolumeGroupBackupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVolumeKmsKey Gets the Key Management encryption key assigned to the specified volume. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeKmsKey.go.html to see an example of how to use GetVolumeKmsKey API. +func (client BlockstorageClient) GetVolumeKmsKey(ctx context.Context, request GetVolumeKmsKeyRequest) (response GetVolumeKmsKeyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVolumeKmsKey, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVolumeKmsKeyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVolumeKmsKeyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVolumeKmsKeyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVolumeKmsKeyResponse") + } + return +} + +// getVolumeKmsKey implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) getVolumeKmsKey(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/volumes/{volumeId}/kmsKey", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVolumeKmsKeyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListBlockVolumeReplicas Lists the block volume replicas in the specified compartment and availability domain. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListBlockVolumeReplicas.go.html to see an example of how to use ListBlockVolumeReplicas API. +func (client BlockstorageClient) ListBlockVolumeReplicas(ctx context.Context, request ListBlockVolumeReplicasRequest) (response ListBlockVolumeReplicasResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listBlockVolumeReplicas, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListBlockVolumeReplicasResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListBlockVolumeReplicasResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListBlockVolumeReplicasResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListBlockVolumeReplicasResponse") + } + return +} + +// listBlockVolumeReplicas implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) listBlockVolumeReplicas(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/blockVolumeReplicas", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListBlockVolumeReplicasResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListBootVolumeBackups Lists the boot volume backups in the specified compartment. You can filter the results by boot volume. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListBootVolumeBackups.go.html to see an example of how to use ListBootVolumeBackups API. +func (client BlockstorageClient) ListBootVolumeBackups(ctx context.Context, request ListBootVolumeBackupsRequest) (response ListBootVolumeBackupsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listBootVolumeBackups, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListBootVolumeBackupsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListBootVolumeBackupsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListBootVolumeBackupsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListBootVolumeBackupsResponse") + } + return +} + +// listBootVolumeBackups implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) listBootVolumeBackups(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/bootVolumeBackups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListBootVolumeBackupsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListBootVolumeReplicas Lists the boot volume replicas in the specified compartment and availability domain. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListBootVolumeReplicas.go.html to see an example of how to use ListBootVolumeReplicas API. +func (client BlockstorageClient) ListBootVolumeReplicas(ctx context.Context, request ListBootVolumeReplicasRequest) (response ListBootVolumeReplicasResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listBootVolumeReplicas, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListBootVolumeReplicasResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListBootVolumeReplicasResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListBootVolumeReplicasResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListBootVolumeReplicasResponse") + } + return +} + +// listBootVolumeReplicas implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) listBootVolumeReplicas(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/bootVolumeReplicas", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListBootVolumeReplicasResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListBootVolumes Lists the boot volumes in the specified compartment and availability domain. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListBootVolumes.go.html to see an example of how to use ListBootVolumes API. +func (client BlockstorageClient) ListBootVolumes(ctx context.Context, request ListBootVolumesRequest) (response ListBootVolumesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listBootVolumes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListBootVolumesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListBootVolumesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListBootVolumesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListBootVolumesResponse") + } + return +} + +// listBootVolumes implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) listBootVolumes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/bootVolumes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListBootVolumesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListVolumeBackupPolicies Lists all the volume backup policies available in the specified compartment. +// For more information about Oracle defined backup policies and user defined backup policies, +// see Policy-Based Backups (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVolumeBackupPolicies.go.html to see an example of how to use ListVolumeBackupPolicies API. +func (client BlockstorageClient) ListVolumeBackupPolicies(ctx context.Context, request ListVolumeBackupPoliciesRequest) (response ListVolumeBackupPoliciesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listVolumeBackupPolicies, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListVolumeBackupPoliciesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListVolumeBackupPoliciesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListVolumeBackupPoliciesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListVolumeBackupPoliciesResponse") + } + return +} + +// listVolumeBackupPolicies implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) listVolumeBackupPolicies(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/volumeBackupPolicies", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListVolumeBackupPoliciesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListVolumeBackups Lists the volume backups in the specified compartment. You can filter the results by volume. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVolumeBackups.go.html to see an example of how to use ListVolumeBackups API. +func (client BlockstorageClient) ListVolumeBackups(ctx context.Context, request ListVolumeBackupsRequest) (response ListVolumeBackupsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listVolumeBackups, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListVolumeBackupsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListVolumeBackupsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListVolumeBackupsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListVolumeBackupsResponse") + } + return +} + +// listVolumeBackups implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) listVolumeBackups(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/volumeBackups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListVolumeBackupsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListVolumeGroupBackups Lists the volume group backups in the specified compartment. You can filter the results by volume group. +// For more information, see Volume Groups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/volumegroups.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVolumeGroupBackups.go.html to see an example of how to use ListVolumeGroupBackups API. +func (client BlockstorageClient) ListVolumeGroupBackups(ctx context.Context, request ListVolumeGroupBackupsRequest) (response ListVolumeGroupBackupsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listVolumeGroupBackups, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListVolumeGroupBackupsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListVolumeGroupBackupsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListVolumeGroupBackupsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListVolumeGroupBackupsResponse") + } + return +} + +// listVolumeGroupBackups implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) listVolumeGroupBackups(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/volumeGroupBackups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListVolumeGroupBackupsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListVolumeGroups Lists the volume groups in the specified compartment and availability domain. +// For more information, see Volume Groups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/volumegroups.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVolumeGroups.go.html to see an example of how to use ListVolumeGroups API. +func (client BlockstorageClient) ListVolumeGroups(ctx context.Context, request ListVolumeGroupsRequest) (response ListVolumeGroupsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listVolumeGroups, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListVolumeGroupsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListVolumeGroupsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListVolumeGroupsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListVolumeGroupsResponse") + } + return +} + +// listVolumeGroups implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) listVolumeGroups(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/volumeGroups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListVolumeGroupsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListVolumes Lists the volumes in the specified compartment and availability domain. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVolumes.go.html to see an example of how to use ListVolumes API. +func (client BlockstorageClient) ListVolumes(ctx context.Context, request ListVolumesRequest) (response ListVolumesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listVolumes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListVolumesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListVolumesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListVolumesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListVolumesResponse") + } + return +} + +// listVolumes implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) listVolumes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/volumes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListVolumesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateBootVolume Updates the specified boot volume's display name, defined tags, and free-form tags. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateBootVolume.go.html to see an example of how to use UpdateBootVolume API. +func (client BlockstorageClient) UpdateBootVolume(ctx context.Context, request UpdateBootVolumeRequest) (response UpdateBootVolumeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateBootVolume, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateBootVolumeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateBootVolumeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateBootVolumeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateBootVolumeResponse") + } + return +} + +// updateBootVolume implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) updateBootVolume(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/bootVolumes/{bootVolumeId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateBootVolumeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateBootVolumeBackup Updates the display name for the specified boot volume backup. +// Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateBootVolumeBackup.go.html to see an example of how to use UpdateBootVolumeBackup API. +func (client BlockstorageClient) UpdateBootVolumeBackup(ctx context.Context, request UpdateBootVolumeBackupRequest) (response UpdateBootVolumeBackupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateBootVolumeBackup, policy) + if err != nil { + if ociResponse != nil { + response = UpdateBootVolumeBackupResponse{RawResponse: ociResponse.HTTPResponse()} + } + return + } + if convertedResponse, ok := ociResponse.(UpdateBootVolumeBackupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateBootVolumeBackupResponse") + } + return +} + +// updateBootVolumeBackup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) updateBootVolumeBackup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/bootVolumeBackups/{bootVolumeBackupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateBootVolumeBackupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateBootVolumeKmsKey Updates the specified volume with a new Key Management master encryption key. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateBootVolumeKmsKey.go.html to see an example of how to use UpdateBootVolumeKmsKey API. +func (client BlockstorageClient) UpdateBootVolumeKmsKey(ctx context.Context, request UpdateBootVolumeKmsKeyRequest) (response UpdateBootVolumeKmsKeyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateBootVolumeKmsKey, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateBootVolumeKmsKeyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateBootVolumeKmsKeyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateBootVolumeKmsKeyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateBootVolumeKmsKeyResponse") + } + return +} + +// updateBootVolumeKmsKey implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) updateBootVolumeKmsKey(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/bootVolumes/{bootVolumeId}/kmsKey", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateBootVolumeKmsKeyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateVolume Updates the specified volume's display name. +// Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVolume.go.html to see an example of how to use UpdateVolume API. +func (client BlockstorageClient) UpdateVolume(ctx context.Context, request UpdateVolumeRequest) (response UpdateVolumeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateVolume, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateVolumeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateVolumeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateVolumeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateVolumeResponse") + } + return +} + +// updateVolume implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) updateVolume(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/volumes/{volumeId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateVolumeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateVolumeBackup Updates the display name for the specified volume backup. +// Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVolumeBackup.go.html to see an example of how to use UpdateVolumeBackup API. +func (client BlockstorageClient) UpdateVolumeBackup(ctx context.Context, request UpdateVolumeBackupRequest) (response UpdateVolumeBackupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateVolumeBackup, policy) + if err != nil { + if ociResponse != nil { + response = UpdateVolumeBackupResponse{RawResponse: ociResponse.HTTPResponse()} + } + return + } + if convertedResponse, ok := ociResponse.(UpdateVolumeBackupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateVolumeBackupResponse") + } + return +} + +// updateVolumeBackup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) updateVolumeBackup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/volumeBackups/{volumeBackupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateVolumeBackupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateVolumeBackupPolicy Updates a user defined backup policy. +// For more information about user defined backup policies, +// see Policy-Based Backups (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm#UserDefinedBackupPolicies). +// Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVolumeBackupPolicy.go.html to see an example of how to use UpdateVolumeBackupPolicy API. +func (client BlockstorageClient) UpdateVolumeBackupPolicy(ctx context.Context, request UpdateVolumeBackupPolicyRequest) (response UpdateVolumeBackupPolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.updateVolumeBackupPolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateVolumeBackupPolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateVolumeBackupPolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateVolumeBackupPolicyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateVolumeBackupPolicyResponse") + } + return +} + +// updateVolumeBackupPolicy implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) updateVolumeBackupPolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/volumeBackupPolicies/{policyId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateVolumeBackupPolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateVolumeGroup Updates the set of volumes in a volume group along with the display name. Use this operation +// to add or remove volumes in a volume group. Specify the full list of volume IDs to include in the +// volume group. If the volume ID is not specified in the call, it will be removed from the volume group. +// Avoid entering confidential information. +// For more information, see Volume Groups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/volumegroups.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVolumeGroup.go.html to see an example of how to use UpdateVolumeGroup API. +func (client BlockstorageClient) UpdateVolumeGroup(ctx context.Context, request UpdateVolumeGroupRequest) (response UpdateVolumeGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateVolumeGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateVolumeGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateVolumeGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateVolumeGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateVolumeGroupResponse") + } + return +} + +// updateVolumeGroup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) updateVolumeGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/volumeGroups/{volumeGroupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateVolumeGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateVolumeGroupBackup Updates the display name for the specified volume group backup. For more information, see Volume Groups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/volumegroups.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVolumeGroupBackup.go.html to see an example of how to use UpdateVolumeGroupBackup API. +func (client BlockstorageClient) UpdateVolumeGroupBackup(ctx context.Context, request UpdateVolumeGroupBackupRequest) (response UpdateVolumeGroupBackupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateVolumeGroupBackup, policy) + if err != nil { + if ociResponse != nil { + response = UpdateVolumeGroupBackupResponse{RawResponse: ociResponse.HTTPResponse()} + } + return + } + if convertedResponse, ok := ociResponse.(UpdateVolumeGroupBackupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateVolumeGroupBackupResponse") + } + return +} + +// updateVolumeGroupBackup implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) updateVolumeGroupBackup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/volumeGroupBackups/{volumeGroupBackupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateVolumeGroupBackupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateVolumeKmsKey Updates the specified volume with a new Key Management master encryption key. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVolumeKmsKey.go.html to see an example of how to use UpdateVolumeKmsKey API. +func (client BlockstorageClient) UpdateVolumeKmsKey(ctx context.Context, request UpdateVolumeKmsKeyRequest) (response UpdateVolumeKmsKeyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateVolumeKmsKey, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateVolumeKmsKeyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateVolumeKmsKeyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateVolumeKmsKeyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateVolumeKmsKeyResponse") + } + return +} + +// updateVolumeKmsKey implements the OCIOperation interface (enables retrying operations) +func (client BlockstorageClient) updateVolumeKmsKey(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/volumes/{volumeId}/kmsKey", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateVolumeKmsKeyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/core_compute_client.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/core_compute_client.go new file mode 100644 index 000000000..a0d0ef03d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/core_compute_client.go @@ -0,0 +1,4887 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "context" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" + "github.com/oracle/oci-go-sdk/v54/common/auth" + "net/http" +) + +//ComputeClient a client for Compute +type ComputeClient struct { + common.BaseClient + config *common.ConfigurationProvider +} + +// NewComputeClientWithConfigurationProvider Creates a new default Compute client with the given configuration provider. +// the configuration provider will be used for the default signer as well as reading the region +func NewComputeClientWithConfigurationProvider(configProvider common.ConfigurationProvider) (client ComputeClient, err error) { + provider, err := auth.GetGenericConfigurationProvider(configProvider) + if err != nil { + return client, err + } + baseClient, e := common.NewClientWithConfig(provider) + if e != nil { + return client, e + } + return newComputeClientFromBaseClient(baseClient, provider) +} + +// NewComputeClientWithOboToken Creates a new default Compute client with the given configuration provider. +// The obotoken will be added to default headers and signed; the configuration provider will be used for the signer +// as well as reading the region +func NewComputeClientWithOboToken(configProvider common.ConfigurationProvider, oboToken string) (client ComputeClient, err error) { + baseClient, err := common.NewClientWithOboToken(configProvider, oboToken) + if err != nil { + return client, err + } + + return newComputeClientFromBaseClient(baseClient, configProvider) +} + +func newComputeClientFromBaseClient(baseClient common.BaseClient, configProvider common.ConfigurationProvider) (client ComputeClient, err error) { + common.ConfigCircuitBreakerFromEnvVar(&baseClient) + common.ConfigCircuitBreakerFromGlobalVar(&baseClient) + + client = ComputeClient{BaseClient: baseClient} + client.BasePath = "20160918" + err = client.setConfigurationProvider(configProvider) + return +} + +// SetRegion overrides the region of this client. +func (client *ComputeClient) SetRegion(region string) { + client.Host = common.StringToRegion(region).EndpointForTemplate("iaas", "https://iaas.{region}.{secondLevelDomain}") +} + +// SetConfigurationProvider sets the configuration provider including the region, returns an error if is not valid +func (client *ComputeClient) setConfigurationProvider(configProvider common.ConfigurationProvider) error { + if ok, err := common.IsConfigurationProviderValid(configProvider); !ok { + return err + } + + // Error has been checked already + region, _ := configProvider.Region() + client.SetRegion(region) + client.config = &configProvider + return nil +} + +// ConfigurationProvider the ConfigurationProvider used in this client, or null if none set +func (client *ComputeClient) ConfigurationProvider() *common.ConfigurationProvider { + return client.config +} + +// AcceptShieldedIntegrityPolicy Accept the changes to the PCR values in the measured boot report. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AcceptShieldedIntegrityPolicy.go.html to see an example of how to use AcceptShieldedIntegrityPolicy API. +func (client ComputeClient) AcceptShieldedIntegrityPolicy(ctx context.Context, request AcceptShieldedIntegrityPolicyRequest) (response AcceptShieldedIntegrityPolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.acceptShieldedIntegrityPolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AcceptShieldedIntegrityPolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AcceptShieldedIntegrityPolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AcceptShieldedIntegrityPolicyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AcceptShieldedIntegrityPolicyResponse") + } + return +} + +// acceptShieldedIntegrityPolicy implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) acceptShieldedIntegrityPolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instances/{instanceId}/actions/acceptShieldedIntegrityPolicy", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AcceptShieldedIntegrityPolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// AddImageShapeCompatibilityEntry Adds a shape to the compatible shapes list for the image. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AddImageShapeCompatibilityEntry.go.html to see an example of how to use AddImageShapeCompatibilityEntry API. +func (client ComputeClient) AddImageShapeCompatibilityEntry(ctx context.Context, request AddImageShapeCompatibilityEntryRequest) (response AddImageShapeCompatibilityEntryResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.addImageShapeCompatibilityEntry, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AddImageShapeCompatibilityEntryResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AddImageShapeCompatibilityEntryResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AddImageShapeCompatibilityEntryResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AddImageShapeCompatibilityEntryResponse") + } + return +} + +// addImageShapeCompatibilityEntry implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) addImageShapeCompatibilityEntry(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/images/{imageId}/shapes/{shapeName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AddImageShapeCompatibilityEntryResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// AttachBootVolume Attaches the specified boot volume to the specified instance. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AttachBootVolume.go.html to see an example of how to use AttachBootVolume API. +func (client ComputeClient) AttachBootVolume(ctx context.Context, request AttachBootVolumeRequest) (response AttachBootVolumeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.attachBootVolume, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AttachBootVolumeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AttachBootVolumeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AttachBootVolumeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AttachBootVolumeResponse") + } + return +} + +// attachBootVolume implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) attachBootVolume(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/bootVolumeAttachments", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AttachBootVolumeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// AttachVnic Creates a secondary VNIC and attaches it to the specified instance. +// For more information about secondary VNICs, see +// Virtual Network Interface Cards (VNICs) (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingVNICs.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AttachVnic.go.html to see an example of how to use AttachVnic API. +func (client ComputeClient) AttachVnic(ctx context.Context, request AttachVnicRequest) (response AttachVnicResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.attachVnic, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AttachVnicResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AttachVnicResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AttachVnicResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AttachVnicResponse") + } + return +} + +// attachVnic implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) attachVnic(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/vnicAttachments", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AttachVnicResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// AttachVolume Attaches the specified storage volume to the specified instance. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AttachVolume.go.html to see an example of how to use AttachVolume API. +func (client ComputeClient) AttachVolume(ctx context.Context, request AttachVolumeRequest) (response AttachVolumeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.attachVolume, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AttachVolumeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AttachVolumeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AttachVolumeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AttachVolumeResponse") + } + return +} + +// attachVolume implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) attachVolume(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/volumeAttachments", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AttachVolumeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponseWithPolymorphicBody(httpResponse, &response, &volumeattachment{}) + return response, err +} + +// CaptureConsoleHistory Captures the most recent serial console data (up to a megabyte) for the +// specified instance. +// The `CaptureConsoleHistory` operation works with the other console history operations +// as described below. +// 1. Use `CaptureConsoleHistory` to request the capture of up to a megabyte of the +// most recent console history. This call returns a `ConsoleHistory` +// object. The object will have a state of REQUESTED. +// 2. Wait for the capture operation to succeed by polling `GetConsoleHistory` with +// the identifier of the console history metadata. The state of the +// `ConsoleHistory` object will go from REQUESTED to GETTING-HISTORY and +// then SUCCEEDED (or FAILED). +// 3. Use `GetConsoleHistoryContent` to get the actual console history data (not the +// metadata). +// 4. Optionally, use `DeleteConsoleHistory` to delete the console history metadata +// and the console history data. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CaptureConsoleHistory.go.html to see an example of how to use CaptureConsoleHistory API. +func (client ComputeClient) CaptureConsoleHistory(ctx context.Context, request CaptureConsoleHistoryRequest) (response CaptureConsoleHistoryResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.captureConsoleHistory, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CaptureConsoleHistoryResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CaptureConsoleHistoryResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CaptureConsoleHistoryResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CaptureConsoleHistoryResponse") + } + return +} + +// captureConsoleHistory implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) captureConsoleHistory(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instanceConsoleHistories", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CaptureConsoleHistoryResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeComputeCapacityReservationCompartment Moves a compute capacity reservation into a different compartment. For information about +// moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeComputeCapacityReservationCompartment.go.html to see an example of how to use ChangeComputeCapacityReservationCompartment API. +func (client ComputeClient) ChangeComputeCapacityReservationCompartment(ctx context.Context, request ChangeComputeCapacityReservationCompartmentRequest) (response ChangeComputeCapacityReservationCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeComputeCapacityReservationCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeComputeCapacityReservationCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeComputeCapacityReservationCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeComputeCapacityReservationCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeComputeCapacityReservationCompartmentResponse") + } + return +} + +// changeComputeCapacityReservationCompartment implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) changeComputeCapacityReservationCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/computeCapacityReservations/{capacityReservationId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeComputeCapacityReservationCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeComputeImageCapabilitySchemaCompartment Moves a compute image capability schema into a different compartment within the same tenancy. +// For information about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeComputeImageCapabilitySchemaCompartment.go.html to see an example of how to use ChangeComputeImageCapabilitySchemaCompartment API. +func (client ComputeClient) ChangeComputeImageCapabilitySchemaCompartment(ctx context.Context, request ChangeComputeImageCapabilitySchemaCompartmentRequest) (response ChangeComputeImageCapabilitySchemaCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeComputeImageCapabilitySchemaCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeComputeImageCapabilitySchemaCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeComputeImageCapabilitySchemaCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeComputeImageCapabilitySchemaCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeComputeImageCapabilitySchemaCompartmentResponse") + } + return +} + +// changeComputeImageCapabilitySchemaCompartment implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) changeComputeImageCapabilitySchemaCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/computeImageCapabilitySchemas/{computeImageCapabilitySchemaId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeComputeImageCapabilitySchemaCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeDedicatedVmHostCompartment Moves a dedicated virtual machine host from one compartment to another. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeDedicatedVmHostCompartment.go.html to see an example of how to use ChangeDedicatedVmHostCompartment API. +func (client ComputeClient) ChangeDedicatedVmHostCompartment(ctx context.Context, request ChangeDedicatedVmHostCompartmentRequest) (response ChangeDedicatedVmHostCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeDedicatedVmHostCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeDedicatedVmHostCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeDedicatedVmHostCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeDedicatedVmHostCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeDedicatedVmHostCompartmentResponse") + } + return +} + +// changeDedicatedVmHostCompartment implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) changeDedicatedVmHostCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/dedicatedVmHosts/{dedicatedVmHostId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeDedicatedVmHostCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeImageCompartment Moves an image into a different compartment within the same tenancy. For information about moving +// resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeImageCompartment.go.html to see an example of how to use ChangeImageCompartment API. +func (client ComputeClient) ChangeImageCompartment(ctx context.Context, request ChangeImageCompartmentRequest) (response ChangeImageCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeImageCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeImageCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeImageCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeImageCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeImageCompartmentResponse") + } + return +} + +// changeImageCompartment implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) changeImageCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/images/{imageId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeImageCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeInstanceCompartment Moves an instance into a different compartment within the same tenancy. For information about +// moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// When you move an instance to a different compartment, associated resources such as boot volumes and VNICs +// are not moved. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeInstanceCompartment.go.html to see an example of how to use ChangeInstanceCompartment API. +func (client ComputeClient) ChangeInstanceCompartment(ctx context.Context, request ChangeInstanceCompartmentRequest) (response ChangeInstanceCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeInstanceCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeInstanceCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeInstanceCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeInstanceCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeInstanceCompartmentResponse") + } + return +} + +// changeInstanceCompartment implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) changeInstanceCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instances/{instanceId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeInstanceCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateAppCatalogSubscription Create a subscription for listing resource version for a compartment. It will take some time to propagate to all regions. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateAppCatalogSubscription.go.html to see an example of how to use CreateAppCatalogSubscription API. +func (client ComputeClient) CreateAppCatalogSubscription(ctx context.Context, request CreateAppCatalogSubscriptionRequest) (response CreateAppCatalogSubscriptionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createAppCatalogSubscription, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateAppCatalogSubscriptionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateAppCatalogSubscriptionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateAppCatalogSubscriptionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateAppCatalogSubscriptionResponse") + } + return +} + +// createAppCatalogSubscription implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) createAppCatalogSubscription(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/appCatalogSubscriptions", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateAppCatalogSubscriptionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateComputeCapacityReservation Creates a new compute capacity reservation in the specified compartment and availability domain. +// Compute capacity reservations let you reserve instances in a compartment. +// When you launch an instance using this reservation, you are assured that you have enough space for your instance, +// and you won't get out of capacity errors. +// For more information, see Reserved Capacity (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/reserve-capacity.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateComputeCapacityReservation.go.html to see an example of how to use CreateComputeCapacityReservation API. +func (client ComputeClient) CreateComputeCapacityReservation(ctx context.Context, request CreateComputeCapacityReservationRequest) (response CreateComputeCapacityReservationResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createComputeCapacityReservation, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateComputeCapacityReservationResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateComputeCapacityReservationResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateComputeCapacityReservationResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateComputeCapacityReservationResponse") + } + return +} + +// createComputeCapacityReservation implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) createComputeCapacityReservation(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/computeCapacityReservations", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateComputeCapacityReservationResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateComputeImageCapabilitySchema Creates compute image capability schema. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateComputeImageCapabilitySchema.go.html to see an example of how to use CreateComputeImageCapabilitySchema API. +func (client ComputeClient) CreateComputeImageCapabilitySchema(ctx context.Context, request CreateComputeImageCapabilitySchemaRequest) (response CreateComputeImageCapabilitySchemaResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createComputeImageCapabilitySchema, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateComputeImageCapabilitySchemaResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateComputeImageCapabilitySchemaResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateComputeImageCapabilitySchemaResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateComputeImageCapabilitySchemaResponse") + } + return +} + +// createComputeImageCapabilitySchema implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) createComputeImageCapabilitySchema(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/computeImageCapabilitySchemas", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateComputeImageCapabilitySchemaResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateDedicatedVmHost Creates a new dedicated virtual machine host in the specified compartment and the specified availability domain. +// Dedicated virtual machine hosts enable you to run your Compute virtual machine (VM) instances on dedicated servers +// that are a single tenant and not shared with other customers. +// For more information, see Dedicated Virtual Machine Hosts (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/dedicatedvmhosts.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateDedicatedVmHost.go.html to see an example of how to use CreateDedicatedVmHost API. +func (client ComputeClient) CreateDedicatedVmHost(ctx context.Context, request CreateDedicatedVmHostRequest) (response CreateDedicatedVmHostResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createDedicatedVmHost, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateDedicatedVmHostResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateDedicatedVmHostResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateDedicatedVmHostResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateDedicatedVmHostResponse") + } + return +} + +// createDedicatedVmHost implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) createDedicatedVmHost(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/dedicatedVmHosts", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateDedicatedVmHostResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateImage Creates a boot disk image for the specified instance or imports an exported image from the Oracle Cloud Infrastructure Object Storage service. +// When creating a new image, you must provide the OCID of the instance you want to use as the basis for the image, and +// the OCID of the compartment containing that instance. For more information about images, +// see Managing Custom Images (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/managingcustomimages.htm). +// When importing an exported image from Object Storage, you specify the source information +// in ImageSourceDetails. +// When importing an image based on the namespace, bucket name, and object name, +// use ImageSourceViaObjectStorageTupleDetails. +// When importing an image based on the Object Storage URL, use +// ImageSourceViaObjectStorageUriDetails. +// See Object Storage URLs (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/imageimportexport.htm#URLs) and Using Pre-Authenticated Requests (https://docs.cloud.oracle.com/iaas/Content/Object/Tasks/usingpreauthenticatedrequests.htm) +// for constructing URLs for image import/export. +// For more information about importing exported images, see +// Image Import/Export (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/imageimportexport.htm). +// You may optionally specify a *display name* for the image, which is simply a friendly name or description. +// It does not have to be unique, and you can change it. See UpdateImage. +// Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateImage.go.html to see an example of how to use CreateImage API. +func (client ComputeClient) CreateImage(ctx context.Context, request CreateImageRequest) (response CreateImageResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createImage, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateImageResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateImageResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateImageResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateImageResponse") + } + return +} + +// createImage implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) createImage(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/images", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateImageResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateInstanceConsoleConnection Creates a new console connection to the specified instance. +// After the console connection has been created and is available, +// you connect to the console using SSH. +// For more information about instance console connections, see Troubleshooting Instances Using Instance Console Connections (https://docs.cloud.oracle.com/iaas/Content/Compute/References/serialconsole.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateInstanceConsoleConnection.go.html to see an example of how to use CreateInstanceConsoleConnection API. +func (client ComputeClient) CreateInstanceConsoleConnection(ctx context.Context, request CreateInstanceConsoleConnectionRequest) (response CreateInstanceConsoleConnectionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createInstanceConsoleConnection, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateInstanceConsoleConnectionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateInstanceConsoleConnectionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateInstanceConsoleConnectionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateInstanceConsoleConnectionResponse") + } + return +} + +// createInstanceConsoleConnection implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) createInstanceConsoleConnection(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instanceConsoleConnections", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateInstanceConsoleConnectionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteAppCatalogSubscription Delete a subscription for a listing resource version for a compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteAppCatalogSubscription.go.html to see an example of how to use DeleteAppCatalogSubscription API. +func (client ComputeClient) DeleteAppCatalogSubscription(ctx context.Context, request DeleteAppCatalogSubscriptionRequest) (response DeleteAppCatalogSubscriptionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteAppCatalogSubscription, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteAppCatalogSubscriptionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteAppCatalogSubscriptionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteAppCatalogSubscriptionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteAppCatalogSubscriptionResponse") + } + return +} + +// deleteAppCatalogSubscription implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) deleteAppCatalogSubscription(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/appCatalogSubscriptions", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteAppCatalogSubscriptionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteComputeCapacityReservation Deletes the specified compute capacity reservation. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteComputeCapacityReservation.go.html to see an example of how to use DeleteComputeCapacityReservation API. +func (client ComputeClient) DeleteComputeCapacityReservation(ctx context.Context, request DeleteComputeCapacityReservationRequest) (response DeleteComputeCapacityReservationResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteComputeCapacityReservation, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteComputeCapacityReservationResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteComputeCapacityReservationResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteComputeCapacityReservationResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteComputeCapacityReservationResponse") + } + return +} + +// deleteComputeCapacityReservation implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) deleteComputeCapacityReservation(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/computeCapacityReservations/{capacityReservationId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteComputeCapacityReservationResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteComputeImageCapabilitySchema Deletes the specified Compute Image Capability Schema +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteComputeImageCapabilitySchema.go.html to see an example of how to use DeleteComputeImageCapabilitySchema API. +func (client ComputeClient) DeleteComputeImageCapabilitySchema(ctx context.Context, request DeleteComputeImageCapabilitySchemaRequest) (response DeleteComputeImageCapabilitySchemaResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteComputeImageCapabilitySchema, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteComputeImageCapabilitySchemaResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteComputeImageCapabilitySchemaResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteComputeImageCapabilitySchemaResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteComputeImageCapabilitySchemaResponse") + } + return +} + +// deleteComputeImageCapabilitySchema implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) deleteComputeImageCapabilitySchema(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/computeImageCapabilitySchemas/{computeImageCapabilitySchemaId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteComputeImageCapabilitySchemaResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteConsoleHistory Deletes the specified console history metadata and the console history data. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteConsoleHistory.go.html to see an example of how to use DeleteConsoleHistory API. +func (client ComputeClient) DeleteConsoleHistory(ctx context.Context, request DeleteConsoleHistoryRequest) (response DeleteConsoleHistoryResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteConsoleHistory, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteConsoleHistoryResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteConsoleHistoryResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteConsoleHistoryResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteConsoleHistoryResponse") + } + return +} + +// deleteConsoleHistory implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) deleteConsoleHistory(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/instanceConsoleHistories/{instanceConsoleHistoryId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteConsoleHistoryResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteDedicatedVmHost Deletes the specified dedicated virtual machine host. +// If any VM instances are assigned to the dedicated virtual machine host, +// the delete operation will fail and the service will return a 409 response code. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteDedicatedVmHost.go.html to see an example of how to use DeleteDedicatedVmHost API. +func (client ComputeClient) DeleteDedicatedVmHost(ctx context.Context, request DeleteDedicatedVmHostRequest) (response DeleteDedicatedVmHostResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteDedicatedVmHost, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteDedicatedVmHostResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteDedicatedVmHostResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteDedicatedVmHostResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteDedicatedVmHostResponse") + } + return +} + +// deleteDedicatedVmHost implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) deleteDedicatedVmHost(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/dedicatedVmHosts/{dedicatedVmHostId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteDedicatedVmHostResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteImage Deletes an image. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteImage.go.html to see an example of how to use DeleteImage API. +func (client ComputeClient) DeleteImage(ctx context.Context, request DeleteImageRequest) (response DeleteImageResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteImage, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteImageResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteImageResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteImageResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteImageResponse") + } + return +} + +// deleteImage implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) deleteImage(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/images/{imageId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteImageResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteInstanceConsoleConnection Deletes the specified instance console connection. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteInstanceConsoleConnection.go.html to see an example of how to use DeleteInstanceConsoleConnection API. +func (client ComputeClient) DeleteInstanceConsoleConnection(ctx context.Context, request DeleteInstanceConsoleConnectionRequest) (response DeleteInstanceConsoleConnectionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteInstanceConsoleConnection, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteInstanceConsoleConnectionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteInstanceConsoleConnectionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteInstanceConsoleConnectionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteInstanceConsoleConnectionResponse") + } + return +} + +// deleteInstanceConsoleConnection implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) deleteInstanceConsoleConnection(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/instanceConsoleConnections/{instanceConsoleConnectionId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteInstanceConsoleConnectionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DetachBootVolume Detaches a boot volume from an instance. You must specify the OCID of the boot volume attachment. +// This is an asynchronous operation. The attachment's `lifecycleState` will change to DETACHING temporarily +// until the attachment is completely removed. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DetachBootVolume.go.html to see an example of how to use DetachBootVolume API. +func (client ComputeClient) DetachBootVolume(ctx context.Context, request DetachBootVolumeRequest) (response DetachBootVolumeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.detachBootVolume, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DetachBootVolumeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DetachBootVolumeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DetachBootVolumeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DetachBootVolumeResponse") + } + return +} + +// detachBootVolume implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) detachBootVolume(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/bootVolumeAttachments/{bootVolumeAttachmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DetachBootVolumeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DetachVnic Detaches and deletes the specified secondary VNIC. +// This operation cannot be used on the instance's primary VNIC. +// When you terminate an instance, all attached VNICs (primary +// and secondary) are automatically detached and deleted. +// **Important:** If the VNIC has a +// PrivateIp that is the +// target of a route rule (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingroutetables.htm#privateip), +// deleting the VNIC causes that route rule to blackhole and the traffic +// will be dropped. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DetachVnic.go.html to see an example of how to use DetachVnic API. +func (client ComputeClient) DetachVnic(ctx context.Context, request DetachVnicRequest) (response DetachVnicResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.detachVnic, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DetachVnicResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DetachVnicResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DetachVnicResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DetachVnicResponse") + } + return +} + +// detachVnic implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) detachVnic(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/vnicAttachments/{vnicAttachmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DetachVnicResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DetachVolume Detaches a storage volume from an instance. You must specify the OCID of the volume attachment. +// This is an asynchronous operation. The attachment's `lifecycleState` will change to DETACHING temporarily +// until the attachment is completely removed. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DetachVolume.go.html to see an example of how to use DetachVolume API. +func (client ComputeClient) DetachVolume(ctx context.Context, request DetachVolumeRequest) (response DetachVolumeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.detachVolume, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DetachVolumeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DetachVolumeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DetachVolumeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DetachVolumeResponse") + } + return +} + +// detachVolume implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) detachVolume(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/volumeAttachments/{volumeAttachmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DetachVolumeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ExportImage Exports the specified image to the Oracle Cloud Infrastructure Object Storage service. You can use the Object Storage URL, +// or the namespace, bucket name, and object name when specifying the location to export to. +// For more information about exporting images, see Image Import/Export (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/imageimportexport.htm). +// To perform an image export, you need write access to the Object Storage bucket for the image, +// see Let Users Write Objects to Object Storage Buckets (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/commonpolicies.htm#Let4). +// See Object Storage URLs (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/imageimportexport.htm#URLs) and Using Pre-Authenticated Requests (https://docs.cloud.oracle.com/iaas/Content/Object/Tasks/usingpreauthenticatedrequests.htm) +// for constructing URLs for image import/export. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ExportImage.go.html to see an example of how to use ExportImage API. +func (client ComputeClient) ExportImage(ctx context.Context, request ExportImageRequest) (response ExportImageResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.exportImage, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ExportImageResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ExportImageResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ExportImageResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ExportImageResponse") + } + return +} + +// exportImage implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) exportImage(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/images/{imageId}/actions/export", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ExportImageResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetAppCatalogListing Gets the specified listing. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetAppCatalogListing.go.html to see an example of how to use GetAppCatalogListing API. +func (client ComputeClient) GetAppCatalogListing(ctx context.Context, request GetAppCatalogListingRequest) (response GetAppCatalogListingResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getAppCatalogListing, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetAppCatalogListingResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetAppCatalogListingResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetAppCatalogListingResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetAppCatalogListingResponse") + } + return +} + +// getAppCatalogListing implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getAppCatalogListing(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/appCatalogListings/{listingId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetAppCatalogListingResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetAppCatalogListingAgreements Retrieves the agreements for a particular resource version of a listing. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetAppCatalogListingAgreements.go.html to see an example of how to use GetAppCatalogListingAgreements API. +func (client ComputeClient) GetAppCatalogListingAgreements(ctx context.Context, request GetAppCatalogListingAgreementsRequest) (response GetAppCatalogListingAgreementsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getAppCatalogListingAgreements, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetAppCatalogListingAgreementsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetAppCatalogListingAgreementsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetAppCatalogListingAgreementsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetAppCatalogListingAgreementsResponse") + } + return +} + +// getAppCatalogListingAgreements implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getAppCatalogListingAgreements(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/appCatalogListings/{listingId}/resourceVersions/{resourceVersion}/agreements", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetAppCatalogListingAgreementsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetAppCatalogListingResourceVersion Gets the specified listing resource version. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetAppCatalogListingResourceVersion.go.html to see an example of how to use GetAppCatalogListingResourceVersion API. +func (client ComputeClient) GetAppCatalogListingResourceVersion(ctx context.Context, request GetAppCatalogListingResourceVersionRequest) (response GetAppCatalogListingResourceVersionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getAppCatalogListingResourceVersion, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetAppCatalogListingResourceVersionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetAppCatalogListingResourceVersionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetAppCatalogListingResourceVersionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetAppCatalogListingResourceVersionResponse") + } + return +} + +// getAppCatalogListingResourceVersion implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getAppCatalogListingResourceVersion(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/appCatalogListings/{listingId}/resourceVersions/{resourceVersion}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetAppCatalogListingResourceVersionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetBootVolumeAttachment Gets information about the specified boot volume attachment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetBootVolumeAttachment.go.html to see an example of how to use GetBootVolumeAttachment API. +func (client ComputeClient) GetBootVolumeAttachment(ctx context.Context, request GetBootVolumeAttachmentRequest) (response GetBootVolumeAttachmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getBootVolumeAttachment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetBootVolumeAttachmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetBootVolumeAttachmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetBootVolumeAttachmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetBootVolumeAttachmentResponse") + } + return +} + +// getBootVolumeAttachment implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getBootVolumeAttachment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/bootVolumeAttachments/{bootVolumeAttachmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetBootVolumeAttachmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetComputeCapacityReservation Gets information about the specified compute capacity reservation. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetComputeCapacityReservation.go.html to see an example of how to use GetComputeCapacityReservation API. +func (client ComputeClient) GetComputeCapacityReservation(ctx context.Context, request GetComputeCapacityReservationRequest) (response GetComputeCapacityReservationResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getComputeCapacityReservation, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetComputeCapacityReservationResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetComputeCapacityReservationResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetComputeCapacityReservationResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetComputeCapacityReservationResponse") + } + return +} + +// getComputeCapacityReservation implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getComputeCapacityReservation(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/computeCapacityReservations/{capacityReservationId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetComputeCapacityReservationResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetComputeGlobalImageCapabilitySchema Gets the specified Compute Global Image Capability Schema +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetComputeGlobalImageCapabilitySchema.go.html to see an example of how to use GetComputeGlobalImageCapabilitySchema API. +func (client ComputeClient) GetComputeGlobalImageCapabilitySchema(ctx context.Context, request GetComputeGlobalImageCapabilitySchemaRequest) (response GetComputeGlobalImageCapabilitySchemaResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getComputeGlobalImageCapabilitySchema, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetComputeGlobalImageCapabilitySchemaResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetComputeGlobalImageCapabilitySchemaResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetComputeGlobalImageCapabilitySchemaResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetComputeGlobalImageCapabilitySchemaResponse") + } + return +} + +// getComputeGlobalImageCapabilitySchema implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getComputeGlobalImageCapabilitySchema(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/computeGlobalImageCapabilitySchemas/{computeGlobalImageCapabilitySchemaId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetComputeGlobalImageCapabilitySchemaResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetComputeGlobalImageCapabilitySchemaVersion Gets the specified Compute Global Image Capability Schema Version +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetComputeGlobalImageCapabilitySchemaVersion.go.html to see an example of how to use GetComputeGlobalImageCapabilitySchemaVersion API. +func (client ComputeClient) GetComputeGlobalImageCapabilitySchemaVersion(ctx context.Context, request GetComputeGlobalImageCapabilitySchemaVersionRequest) (response GetComputeGlobalImageCapabilitySchemaVersionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getComputeGlobalImageCapabilitySchemaVersion, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetComputeGlobalImageCapabilitySchemaVersionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetComputeGlobalImageCapabilitySchemaVersionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetComputeGlobalImageCapabilitySchemaVersionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetComputeGlobalImageCapabilitySchemaVersionResponse") + } + return +} + +// getComputeGlobalImageCapabilitySchemaVersion implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getComputeGlobalImageCapabilitySchemaVersion(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/computeGlobalImageCapabilitySchemas/{computeGlobalImageCapabilitySchemaId}/versions/{computeGlobalImageCapabilitySchemaVersionName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetComputeGlobalImageCapabilitySchemaVersionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetComputeImageCapabilitySchema Gets the specified Compute Image Capability Schema +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetComputeImageCapabilitySchema.go.html to see an example of how to use GetComputeImageCapabilitySchema API. +func (client ComputeClient) GetComputeImageCapabilitySchema(ctx context.Context, request GetComputeImageCapabilitySchemaRequest) (response GetComputeImageCapabilitySchemaResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getComputeImageCapabilitySchema, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetComputeImageCapabilitySchemaResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetComputeImageCapabilitySchemaResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetComputeImageCapabilitySchemaResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetComputeImageCapabilitySchemaResponse") + } + return +} + +// getComputeImageCapabilitySchema implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getComputeImageCapabilitySchema(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/computeImageCapabilitySchemas/{computeImageCapabilitySchemaId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetComputeImageCapabilitySchemaResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetConsoleHistory Shows the metadata for the specified console history. +// See CaptureConsoleHistory +// for details about using the console history operations. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetConsoleHistory.go.html to see an example of how to use GetConsoleHistory API. +func (client ComputeClient) GetConsoleHistory(ctx context.Context, request GetConsoleHistoryRequest) (response GetConsoleHistoryResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getConsoleHistory, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetConsoleHistoryResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetConsoleHistoryResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetConsoleHistoryResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetConsoleHistoryResponse") + } + return +} + +// getConsoleHistory implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getConsoleHistory(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instanceConsoleHistories/{instanceConsoleHistoryId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetConsoleHistoryResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetConsoleHistoryContent Gets the actual console history data (not the metadata). +// See CaptureConsoleHistory +// for details about using the console history operations. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetConsoleHistoryContent.go.html to see an example of how to use GetConsoleHistoryContent API. +func (client ComputeClient) GetConsoleHistoryContent(ctx context.Context, request GetConsoleHistoryContentRequest) (response GetConsoleHistoryContentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getConsoleHistoryContent, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetConsoleHistoryContentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetConsoleHistoryContentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetConsoleHistoryContentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetConsoleHistoryContentResponse") + } + return +} + +// getConsoleHistoryContent implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getConsoleHistoryContent(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instanceConsoleHistories/{instanceConsoleHistoryId}/data", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetConsoleHistoryContentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetDedicatedVmHost Gets information about the specified dedicated virtual machine host. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetDedicatedVmHost.go.html to see an example of how to use GetDedicatedVmHost API. +func (client ComputeClient) GetDedicatedVmHost(ctx context.Context, request GetDedicatedVmHostRequest) (response GetDedicatedVmHostResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getDedicatedVmHost, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetDedicatedVmHostResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetDedicatedVmHostResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetDedicatedVmHostResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetDedicatedVmHostResponse") + } + return +} + +// getDedicatedVmHost implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getDedicatedVmHost(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/dedicatedVmHosts/{dedicatedVmHostId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetDedicatedVmHostResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetImage Gets the specified image. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetImage.go.html to see an example of how to use GetImage API. +func (client ComputeClient) GetImage(ctx context.Context, request GetImageRequest) (response GetImageResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getImage, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetImageResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetImageResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetImageResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetImageResponse") + } + return +} + +// getImage implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getImage(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/images/{imageId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetImageResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetImageShapeCompatibilityEntry Retrieves an image shape compatibility entry. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetImageShapeCompatibilityEntry.go.html to see an example of how to use GetImageShapeCompatibilityEntry API. +func (client ComputeClient) GetImageShapeCompatibilityEntry(ctx context.Context, request GetImageShapeCompatibilityEntryRequest) (response GetImageShapeCompatibilityEntryResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getImageShapeCompatibilityEntry, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetImageShapeCompatibilityEntryResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetImageShapeCompatibilityEntryResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetImageShapeCompatibilityEntryResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetImageShapeCompatibilityEntryResponse") + } + return +} + +// getImageShapeCompatibilityEntry implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getImageShapeCompatibilityEntry(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/images/{imageId}/shapes/{shapeName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetImageShapeCompatibilityEntryResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetInstance Gets information about the specified instance. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetInstance.go.html to see an example of how to use GetInstance API. +func (client ComputeClient) GetInstance(ctx context.Context, request GetInstanceRequest) (response GetInstanceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getInstance, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetInstanceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetInstanceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetInstanceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetInstanceResponse") + } + return +} + +// getInstance implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getInstance(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instances/{instanceId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetInstanceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetInstanceConsoleConnection Gets the specified instance console connection's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetInstanceConsoleConnection.go.html to see an example of how to use GetInstanceConsoleConnection API. +func (client ComputeClient) GetInstanceConsoleConnection(ctx context.Context, request GetInstanceConsoleConnectionRequest) (response GetInstanceConsoleConnectionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getInstanceConsoleConnection, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetInstanceConsoleConnectionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetInstanceConsoleConnectionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetInstanceConsoleConnectionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetInstanceConsoleConnectionResponse") + } + return +} + +// getInstanceConsoleConnection implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getInstanceConsoleConnection(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instanceConsoleConnections/{instanceConsoleConnectionId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetInstanceConsoleConnectionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetMeasuredBootReport Gets the measured boot report for this shielded instance. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetMeasuredBootReport.go.html to see an example of how to use GetMeasuredBootReport API. +func (client ComputeClient) GetMeasuredBootReport(ctx context.Context, request GetMeasuredBootReportRequest) (response GetMeasuredBootReportResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getMeasuredBootReport, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetMeasuredBootReportResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetMeasuredBootReportResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetMeasuredBootReportResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetMeasuredBootReportResponse") + } + return +} + +// getMeasuredBootReport implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getMeasuredBootReport(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instances/{instanceId}/measuredBootReport", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetMeasuredBootReportResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVnicAttachment Gets the information for the specified VNIC attachment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVnicAttachment.go.html to see an example of how to use GetVnicAttachment API. +func (client ComputeClient) GetVnicAttachment(ctx context.Context, request GetVnicAttachmentRequest) (response GetVnicAttachmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVnicAttachment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVnicAttachmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVnicAttachmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVnicAttachmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVnicAttachmentResponse") + } + return +} + +// getVnicAttachment implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getVnicAttachment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/vnicAttachments/{vnicAttachmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVnicAttachmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVolumeAttachment Gets information about the specified volume attachment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeAttachment.go.html to see an example of how to use GetVolumeAttachment API. +func (client ComputeClient) GetVolumeAttachment(ctx context.Context, request GetVolumeAttachmentRequest) (response GetVolumeAttachmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVolumeAttachment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVolumeAttachmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVolumeAttachmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVolumeAttachmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVolumeAttachmentResponse") + } + return +} + +// getVolumeAttachment implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getVolumeAttachment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/volumeAttachments/{volumeAttachmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVolumeAttachmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponseWithPolymorphicBody(httpResponse, &response, &volumeattachment{}) + return response, err +} + +// GetWindowsInstanceInitialCredentials Gets the generated credentials for the instance. Only works for instances that require a password to log in, such as Windows. +// For certain operating systems, users will be forced to change the initial credentials. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetWindowsInstanceInitialCredentials.go.html to see an example of how to use GetWindowsInstanceInitialCredentials API. +func (client ComputeClient) GetWindowsInstanceInitialCredentials(ctx context.Context, request GetWindowsInstanceInitialCredentialsRequest) (response GetWindowsInstanceInitialCredentialsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getWindowsInstanceInitialCredentials, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetWindowsInstanceInitialCredentialsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetWindowsInstanceInitialCredentialsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetWindowsInstanceInitialCredentialsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetWindowsInstanceInitialCredentialsResponse") + } + return +} + +// getWindowsInstanceInitialCredentials implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) getWindowsInstanceInitialCredentials(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instances/{instanceId}/initialCredentials", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetWindowsInstanceInitialCredentialsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// InstanceAction Performs one of the following power actions on the specified instance: +// - **START** - Powers on the instance. +// - **STOP** - Powers off the instance. +// - **RESET** - Powers off the instance and then powers it back on. +// - **SOFTSTOP** - Gracefully shuts down the instance by sending a shutdown command to the operating system. +// After waiting 15 minutes for the OS to shut down, the instance is powered off. +// If the applications that run on the instance take more than 15 minutes to shut down, they could be improperly stopped, resulting +// in data corruption. To avoid this, manually shut down the instance using the commands available in the OS before you softstop the +// instance. +// - **SOFTRESET** - Gracefully reboots the instance by sending a shutdown command to the operating system. +// After waiting 15 minutes for the OS to shut down, the instance is powered off and +// then powered back on. +// - **SENDDIAGNOSTICINTERRUPT** - For advanced users. **Warning: Sending a diagnostic interrupt to a live system can +// cause data corruption or system failure.** Sends a diagnostic interrupt that causes the instance's +// OS to crash and then reboot. Before you send a diagnostic interrupt, you must configure the instance to generate a +// crash dump file when it crashes. The crash dump captures information about the state of the OS at the time of +// the crash. After the OS restarts, you can analyze the crash dump to diagnose the issue. For more information, see +// Sending a Diagnostic Interrupt (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/sendingdiagnosticinterrupt.htm). +// +// +// For more information about managing instance lifecycle states, see +// Stopping and Starting an Instance (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/restartinginstance.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/InstanceAction.go.html to see an example of how to use InstanceAction API. +func (client ComputeClient) InstanceAction(ctx context.Context, request InstanceActionRequest) (response InstanceActionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.instanceAction, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = InstanceActionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = InstanceActionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(InstanceActionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into InstanceActionResponse") + } + return +} + +// instanceAction implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) instanceAction(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instances/{instanceId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response InstanceActionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// LaunchInstance Creates a new instance in the specified compartment and the specified availability domain. +// For general information about instances, see +// Overview of the Compute Service (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm). +// For information about access control and compartments, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). +// For information about availability domains, see +// Regions and Availability Domains (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/regions.htm). +// To get a list of availability domains, use the `ListAvailabilityDomains` operation +// in the Identity and Access Management Service API. +// All Oracle Cloud Infrastructure resources, including instances, get an Oracle-assigned, +// unique ID called an Oracle Cloud Identifier (OCID). +// When you create a resource, you can find its OCID in the response. You can +// also retrieve a resource's OCID by using a List API operation +// on that resource type, or by viewing the resource in the Console. +// To launch an instance using an image or a boot volume use the `sourceDetails` parameter in LaunchInstanceDetails. +// When you launch an instance, it is automatically attached to a virtual +// network interface card (VNIC), called the *primary VNIC*. The VNIC +// has a private IP address from the subnet's CIDR. You can either assign a +// private IP address of your choice or let Oracle automatically assign one. +// You can choose whether the instance has a public IP address. To retrieve the +// addresses, use the ListVnicAttachments +// operation to get the VNIC ID for the instance, and then call +// GetVnic with the VNIC ID. +// You can later add secondary VNICs to an instance. For more information, see +// Virtual Network Interface Cards (VNICs) (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingVNICs.htm). +// To launch an instance from a Marketplace image listing, you must provide the image ID of the +// listing resource version that you want, but you also must subscribe to the listing before you try +// to launch the instance. To subscribe to the listing, use the GetAppCatalogListingAgreements +// operation to get the signature for the terms of use agreement for the desired listing resource version. +// Then, call CreateAppCatalogSubscription +// with the signature. To get the image ID for the LaunchInstance operation, call +// GetAppCatalogListingResourceVersion. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/LaunchInstance.go.html to see an example of how to use LaunchInstance API. +func (client ComputeClient) LaunchInstance(ctx context.Context, request LaunchInstanceRequest) (response LaunchInstanceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.launchInstance, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = LaunchInstanceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = LaunchInstanceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(LaunchInstanceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into LaunchInstanceResponse") + } + return +} + +// launchInstance implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) launchInstance(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instances", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response LaunchInstanceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListAppCatalogListingResourceVersions Gets all resource versions for a particular listing. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListAppCatalogListingResourceVersions.go.html to see an example of how to use ListAppCatalogListingResourceVersions API. +func (client ComputeClient) ListAppCatalogListingResourceVersions(ctx context.Context, request ListAppCatalogListingResourceVersionsRequest) (response ListAppCatalogListingResourceVersionsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listAppCatalogListingResourceVersions, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListAppCatalogListingResourceVersionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListAppCatalogListingResourceVersionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListAppCatalogListingResourceVersionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListAppCatalogListingResourceVersionsResponse") + } + return +} + +// listAppCatalogListingResourceVersions implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listAppCatalogListingResourceVersions(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/appCatalogListings/{listingId}/resourceVersions", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListAppCatalogListingResourceVersionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListAppCatalogListings Lists the published listings. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListAppCatalogListings.go.html to see an example of how to use ListAppCatalogListings API. +func (client ComputeClient) ListAppCatalogListings(ctx context.Context, request ListAppCatalogListingsRequest) (response ListAppCatalogListingsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listAppCatalogListings, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListAppCatalogListingsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListAppCatalogListingsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListAppCatalogListingsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListAppCatalogListingsResponse") + } + return +} + +// listAppCatalogListings implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listAppCatalogListings(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/appCatalogListings", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListAppCatalogListingsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListAppCatalogSubscriptions Lists subscriptions for a compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListAppCatalogSubscriptions.go.html to see an example of how to use ListAppCatalogSubscriptions API. +func (client ComputeClient) ListAppCatalogSubscriptions(ctx context.Context, request ListAppCatalogSubscriptionsRequest) (response ListAppCatalogSubscriptionsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listAppCatalogSubscriptions, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListAppCatalogSubscriptionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListAppCatalogSubscriptionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListAppCatalogSubscriptionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListAppCatalogSubscriptionsResponse") + } + return +} + +// listAppCatalogSubscriptions implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listAppCatalogSubscriptions(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/appCatalogSubscriptions", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListAppCatalogSubscriptionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListBootVolumeAttachments Lists the boot volume attachments in the specified compartment. You can filter the +// list by specifying an instance OCID, boot volume OCID, or both. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListBootVolumeAttachments.go.html to see an example of how to use ListBootVolumeAttachments API. +func (client ComputeClient) ListBootVolumeAttachments(ctx context.Context, request ListBootVolumeAttachmentsRequest) (response ListBootVolumeAttachmentsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listBootVolumeAttachments, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListBootVolumeAttachmentsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListBootVolumeAttachmentsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListBootVolumeAttachmentsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListBootVolumeAttachmentsResponse") + } + return +} + +// listBootVolumeAttachments implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listBootVolumeAttachments(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/bootVolumeAttachments", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListBootVolumeAttachmentsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListComputeCapacityReservationInstanceShapes Lists the shapes that can be reserved within the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListComputeCapacityReservationInstanceShapes.go.html to see an example of how to use ListComputeCapacityReservationInstanceShapes API. +func (client ComputeClient) ListComputeCapacityReservationInstanceShapes(ctx context.Context, request ListComputeCapacityReservationInstanceShapesRequest) (response ListComputeCapacityReservationInstanceShapesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listComputeCapacityReservationInstanceShapes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListComputeCapacityReservationInstanceShapesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListComputeCapacityReservationInstanceShapesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListComputeCapacityReservationInstanceShapesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListComputeCapacityReservationInstanceShapesResponse") + } + return +} + +// listComputeCapacityReservationInstanceShapes implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listComputeCapacityReservationInstanceShapes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/computeCapacityReservationInstanceShapes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListComputeCapacityReservationInstanceShapesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListComputeCapacityReservationInstances Lists the instances launched under a capacity reservation. You can filter results by specifying criteria. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListComputeCapacityReservationInstances.go.html to see an example of how to use ListComputeCapacityReservationInstances API. +func (client ComputeClient) ListComputeCapacityReservationInstances(ctx context.Context, request ListComputeCapacityReservationInstancesRequest) (response ListComputeCapacityReservationInstancesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listComputeCapacityReservationInstances, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListComputeCapacityReservationInstancesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListComputeCapacityReservationInstancesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListComputeCapacityReservationInstancesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListComputeCapacityReservationInstancesResponse") + } + return +} + +// listComputeCapacityReservationInstances implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listComputeCapacityReservationInstances(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/computeCapacityReservations/{capacityReservationId}/instances", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListComputeCapacityReservationInstancesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListComputeCapacityReservations Lists the compute capacity reservations that match the specified criteria and compartment. +// You can limit the list by specifying a compute capacity reservation display name +// (the list will include all the identically-named compute capacity reservations in the compartment). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListComputeCapacityReservations.go.html to see an example of how to use ListComputeCapacityReservations API. +func (client ComputeClient) ListComputeCapacityReservations(ctx context.Context, request ListComputeCapacityReservationsRequest) (response ListComputeCapacityReservationsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listComputeCapacityReservations, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListComputeCapacityReservationsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListComputeCapacityReservationsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListComputeCapacityReservationsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListComputeCapacityReservationsResponse") + } + return +} + +// listComputeCapacityReservations implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listComputeCapacityReservations(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/computeCapacityReservations", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListComputeCapacityReservationsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListComputeGlobalImageCapabilitySchemaVersions Lists Compute Global Image Capability Schema versions in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListComputeGlobalImageCapabilitySchemaVersions.go.html to see an example of how to use ListComputeGlobalImageCapabilitySchemaVersions API. +func (client ComputeClient) ListComputeGlobalImageCapabilitySchemaVersions(ctx context.Context, request ListComputeGlobalImageCapabilitySchemaVersionsRequest) (response ListComputeGlobalImageCapabilitySchemaVersionsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listComputeGlobalImageCapabilitySchemaVersions, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListComputeGlobalImageCapabilitySchemaVersionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListComputeGlobalImageCapabilitySchemaVersionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListComputeGlobalImageCapabilitySchemaVersionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListComputeGlobalImageCapabilitySchemaVersionsResponse") + } + return +} + +// listComputeGlobalImageCapabilitySchemaVersions implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listComputeGlobalImageCapabilitySchemaVersions(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/computeGlobalImageCapabilitySchemas/{computeGlobalImageCapabilitySchemaId}/versions", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListComputeGlobalImageCapabilitySchemaVersionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListComputeGlobalImageCapabilitySchemas Lists Compute Global Image Capability Schema in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListComputeGlobalImageCapabilitySchemas.go.html to see an example of how to use ListComputeGlobalImageCapabilitySchemas API. +func (client ComputeClient) ListComputeGlobalImageCapabilitySchemas(ctx context.Context, request ListComputeGlobalImageCapabilitySchemasRequest) (response ListComputeGlobalImageCapabilitySchemasResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listComputeGlobalImageCapabilitySchemas, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListComputeGlobalImageCapabilitySchemasResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListComputeGlobalImageCapabilitySchemasResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListComputeGlobalImageCapabilitySchemasResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListComputeGlobalImageCapabilitySchemasResponse") + } + return +} + +// listComputeGlobalImageCapabilitySchemas implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listComputeGlobalImageCapabilitySchemas(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/computeGlobalImageCapabilitySchemas", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListComputeGlobalImageCapabilitySchemasResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListComputeImageCapabilitySchemas Lists Compute Image Capability Schema in the specified compartment. You can also query by a specific imageId. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListComputeImageCapabilitySchemas.go.html to see an example of how to use ListComputeImageCapabilitySchemas API. +func (client ComputeClient) ListComputeImageCapabilitySchemas(ctx context.Context, request ListComputeImageCapabilitySchemasRequest) (response ListComputeImageCapabilitySchemasResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listComputeImageCapabilitySchemas, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListComputeImageCapabilitySchemasResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListComputeImageCapabilitySchemasResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListComputeImageCapabilitySchemasResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListComputeImageCapabilitySchemasResponse") + } + return +} + +// listComputeImageCapabilitySchemas implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listComputeImageCapabilitySchemas(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/computeImageCapabilitySchemas", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListComputeImageCapabilitySchemasResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListConsoleHistories Lists the console history metadata for the specified compartment or instance. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListConsoleHistories.go.html to see an example of how to use ListConsoleHistories API. +func (client ComputeClient) ListConsoleHistories(ctx context.Context, request ListConsoleHistoriesRequest) (response ListConsoleHistoriesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listConsoleHistories, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListConsoleHistoriesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListConsoleHistoriesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListConsoleHistoriesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListConsoleHistoriesResponse") + } + return +} + +// listConsoleHistories implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listConsoleHistories(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instanceConsoleHistories", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListConsoleHistoriesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListDedicatedVmHostInstanceShapes Lists the shapes that can be used to launch a virtual machine instance on a dedicated virtual machine host within the specified compartment. +// You can filter the list by compatibility with a specific dedicated virtual machine host shape. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDedicatedVmHostInstanceShapes.go.html to see an example of how to use ListDedicatedVmHostInstanceShapes API. +func (client ComputeClient) ListDedicatedVmHostInstanceShapes(ctx context.Context, request ListDedicatedVmHostInstanceShapesRequest) (response ListDedicatedVmHostInstanceShapesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listDedicatedVmHostInstanceShapes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListDedicatedVmHostInstanceShapesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListDedicatedVmHostInstanceShapesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListDedicatedVmHostInstanceShapesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListDedicatedVmHostInstanceShapesResponse") + } + return +} + +// listDedicatedVmHostInstanceShapes implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listDedicatedVmHostInstanceShapes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/dedicatedVmHostInstanceShapes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListDedicatedVmHostInstanceShapesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListDedicatedVmHostInstances Returns the list of instances on the dedicated virtual machine hosts that match the specified criteria. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDedicatedVmHostInstances.go.html to see an example of how to use ListDedicatedVmHostInstances API. +func (client ComputeClient) ListDedicatedVmHostInstances(ctx context.Context, request ListDedicatedVmHostInstancesRequest) (response ListDedicatedVmHostInstancesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listDedicatedVmHostInstances, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListDedicatedVmHostInstancesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListDedicatedVmHostInstancesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListDedicatedVmHostInstancesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListDedicatedVmHostInstancesResponse") + } + return +} + +// listDedicatedVmHostInstances implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listDedicatedVmHostInstances(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/dedicatedVmHosts/{dedicatedVmHostId}/instances", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListDedicatedVmHostInstancesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListDedicatedVmHostShapes Lists the shapes that can be used to launch a dedicated virtual machine host within the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDedicatedVmHostShapes.go.html to see an example of how to use ListDedicatedVmHostShapes API. +func (client ComputeClient) ListDedicatedVmHostShapes(ctx context.Context, request ListDedicatedVmHostShapesRequest) (response ListDedicatedVmHostShapesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listDedicatedVmHostShapes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListDedicatedVmHostShapesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListDedicatedVmHostShapesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListDedicatedVmHostShapesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListDedicatedVmHostShapesResponse") + } + return +} + +// listDedicatedVmHostShapes implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listDedicatedVmHostShapes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/dedicatedVmHostShapes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListDedicatedVmHostShapesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListDedicatedVmHosts Returns the list of dedicated virtual machine hosts that match the specified criteria in the specified compartment. +// You can limit the list by specifying a dedicated virtual machine host display name. The list will include all the identically-named +// dedicated virtual machine hosts in the compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDedicatedVmHosts.go.html to see an example of how to use ListDedicatedVmHosts API. +func (client ComputeClient) ListDedicatedVmHosts(ctx context.Context, request ListDedicatedVmHostsRequest) (response ListDedicatedVmHostsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listDedicatedVmHosts, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListDedicatedVmHostsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListDedicatedVmHostsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListDedicatedVmHostsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListDedicatedVmHostsResponse") + } + return +} + +// listDedicatedVmHosts implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listDedicatedVmHosts(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/dedicatedVmHosts", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListDedicatedVmHostsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListImageShapeCompatibilityEntries Lists the compatible shapes for the specified image. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListImageShapeCompatibilityEntries.go.html to see an example of how to use ListImageShapeCompatibilityEntries API. +func (client ComputeClient) ListImageShapeCompatibilityEntries(ctx context.Context, request ListImageShapeCompatibilityEntriesRequest) (response ListImageShapeCompatibilityEntriesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listImageShapeCompatibilityEntries, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListImageShapeCompatibilityEntriesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListImageShapeCompatibilityEntriesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListImageShapeCompatibilityEntriesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListImageShapeCompatibilityEntriesResponse") + } + return +} + +// listImageShapeCompatibilityEntries implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listImageShapeCompatibilityEntries(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/images/{imageId}/shapes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListImageShapeCompatibilityEntriesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListImages Lists a subset of images available in the specified compartment, including +// platform images (https://docs.cloud.oracle.com/iaas/Content/Compute/References/images.htm) and +// custom images (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/managingcustomimages.htm). +// The list of platform images includes the three most recently published versions +// of each major distribution. +// The list of images returned is ordered to first show the recent platform images, +// then all of the custom images. +// **Caution:** Platform images are refreshed regularly. When new images are released, older versions are replaced. +// The image OCIDs remain available, but when the platform image is replaced, the image OCIDs are no longer returned as part of the platform image list. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListImages.go.html to see an example of how to use ListImages API. +func (client ComputeClient) ListImages(ctx context.Context, request ListImagesRequest) (response ListImagesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listImages, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListImagesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListImagesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListImagesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListImagesResponse") + } + return +} + +// listImages implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listImages(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/images", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListImagesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListInstanceConsoleConnections Lists the console connections for the specified compartment or instance. +// For more information about instance console connections, see Troubleshooting Instances Using Instance Console Connections (https://docs.cloud.oracle.com/iaas/Content/Compute/References/serialconsole.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListInstanceConsoleConnections.go.html to see an example of how to use ListInstanceConsoleConnections API. +func (client ComputeClient) ListInstanceConsoleConnections(ctx context.Context, request ListInstanceConsoleConnectionsRequest) (response ListInstanceConsoleConnectionsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listInstanceConsoleConnections, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListInstanceConsoleConnectionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListInstanceConsoleConnectionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListInstanceConsoleConnectionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListInstanceConsoleConnectionsResponse") + } + return +} + +// listInstanceConsoleConnections implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listInstanceConsoleConnections(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instanceConsoleConnections", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListInstanceConsoleConnectionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListInstanceDevices Gets a list of all the devices for given instance. You can optionally filter results by device availability. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListInstanceDevices.go.html to see an example of how to use ListInstanceDevices API. +func (client ComputeClient) ListInstanceDevices(ctx context.Context, request ListInstanceDevicesRequest) (response ListInstanceDevicesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listInstanceDevices, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListInstanceDevicesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListInstanceDevicesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListInstanceDevicesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListInstanceDevicesResponse") + } + return +} + +// listInstanceDevices implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listInstanceDevices(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instances/{instanceId}/devices", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListInstanceDevicesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListInstances Lists the instances in the specified compartment and the specified availability domain. +// You can filter the results by specifying an instance name (the list will include all the identically-named +// instances in the compartment). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListInstances.go.html to see an example of how to use ListInstances API. +func (client ComputeClient) ListInstances(ctx context.Context, request ListInstancesRequest) (response ListInstancesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listInstances, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListInstancesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListInstancesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListInstancesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListInstancesResponse") + } + return +} + +// listInstances implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listInstances(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instances", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListInstancesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListShapes Lists the shapes that can be used to launch an instance within the specified compartment. You can +// filter the list by compatibility with a specific image. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListShapes.go.html to see an example of how to use ListShapes API. +func (client ComputeClient) ListShapes(ctx context.Context, request ListShapesRequest) (response ListShapesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listShapes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListShapesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListShapesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListShapesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListShapesResponse") + } + return +} + +// listShapes implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listShapes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/shapes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListShapesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListVnicAttachments Lists the VNIC attachments in the specified compartment. A VNIC attachment +// resides in the same compartment as the attached instance. The list can be +// filtered by instance, VNIC, or availability domain. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVnicAttachments.go.html to see an example of how to use ListVnicAttachments API. +func (client ComputeClient) ListVnicAttachments(ctx context.Context, request ListVnicAttachmentsRequest) (response ListVnicAttachmentsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listVnicAttachments, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListVnicAttachmentsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListVnicAttachmentsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListVnicAttachmentsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListVnicAttachmentsResponse") + } + return +} + +// listVnicAttachments implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listVnicAttachments(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/vnicAttachments", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListVnicAttachmentsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +//listvolumeattachment allows to unmarshal list of polymorphic VolumeAttachment +type listvolumeattachment []volumeattachment + +//UnmarshalPolymorphicJSON unmarshals polymorphic json list of items +func (m *listvolumeattachment) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + res := make([]VolumeAttachment, len(*m)) + for i, v := range *m { + nn, err := v.UnmarshalPolymorphicJSON(v.JsonData) + if err != nil { + return nil, err + } + res[i] = nn.(VolumeAttachment) + } + return res, nil +} + +// ListVolumeAttachments Lists the volume attachments in the specified compartment. You can filter the +// list by specifying an instance OCID, volume OCID, or both. +// Currently, the only supported volume attachment type are IScsiVolumeAttachment and +// ParavirtualizedVolumeAttachment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVolumeAttachments.go.html to see an example of how to use ListVolumeAttachments API. +func (client ComputeClient) ListVolumeAttachments(ctx context.Context, request ListVolumeAttachmentsRequest) (response ListVolumeAttachmentsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listVolumeAttachments, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListVolumeAttachmentsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListVolumeAttachmentsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListVolumeAttachmentsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListVolumeAttachmentsResponse") + } + return +} + +// listVolumeAttachments implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) listVolumeAttachments(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/volumeAttachments", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListVolumeAttachmentsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponseWithPolymorphicBody(httpResponse, &response, &listvolumeattachment{}) + return response, err +} + +// RemoveImageShapeCompatibilityEntry Removes a shape from the compatible shapes list for the image. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemoveImageShapeCompatibilityEntry.go.html to see an example of how to use RemoveImageShapeCompatibilityEntry API. +func (client ComputeClient) RemoveImageShapeCompatibilityEntry(ctx context.Context, request RemoveImageShapeCompatibilityEntryRequest) (response RemoveImageShapeCompatibilityEntryResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.removeImageShapeCompatibilityEntry, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = RemoveImageShapeCompatibilityEntryResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = RemoveImageShapeCompatibilityEntryResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(RemoveImageShapeCompatibilityEntryResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into RemoveImageShapeCompatibilityEntryResponse") + } + return +} + +// removeImageShapeCompatibilityEntry implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) removeImageShapeCompatibilityEntry(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/images/{imageId}/shapes/{shapeName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response RemoveImageShapeCompatibilityEntryResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// TerminateInstance Terminates the specified instance. Any attached VNICs and volumes are automatically detached +// when the instance terminates. +// To preserve the boot volume associated with the instance, specify `true` for `PreserveBootVolumeQueryParam`. +// To delete the boot volume when the instance is deleted, specify `false` or do not specify a value for `PreserveBootVolumeQueryParam`. +// This is an asynchronous operation. The instance's `lifecycleState` will change to TERMINATING temporarily +// until the instance is completely removed. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/TerminateInstance.go.html to see an example of how to use TerminateInstance API. +func (client ComputeClient) TerminateInstance(ctx context.Context, request TerminateInstanceRequest) (response TerminateInstanceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.terminateInstance, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = TerminateInstanceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = TerminateInstanceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(TerminateInstanceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into TerminateInstanceResponse") + } + return +} + +// terminateInstance implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) terminateInstance(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/instances/{instanceId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response TerminateInstanceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateComputeCapacityReservation Updates the specified capacity reservation and its associated capacity configurations. +// Fields that are not provided in the request will not be updated. Capacity configurations that are not included will be deleted. +// Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateComputeCapacityReservation.go.html to see an example of how to use UpdateComputeCapacityReservation API. +func (client ComputeClient) UpdateComputeCapacityReservation(ctx context.Context, request UpdateComputeCapacityReservationRequest) (response UpdateComputeCapacityReservationResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateComputeCapacityReservation, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateComputeCapacityReservationResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateComputeCapacityReservationResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateComputeCapacityReservationResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateComputeCapacityReservationResponse") + } + return +} + +// updateComputeCapacityReservation implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) updateComputeCapacityReservation(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/computeCapacityReservations/{capacityReservationId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateComputeCapacityReservationResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateComputeImageCapabilitySchema Updates the specified Compute Image Capability Schema +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateComputeImageCapabilitySchema.go.html to see an example of how to use UpdateComputeImageCapabilitySchema API. +func (client ComputeClient) UpdateComputeImageCapabilitySchema(ctx context.Context, request UpdateComputeImageCapabilitySchemaRequest) (response UpdateComputeImageCapabilitySchemaResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateComputeImageCapabilitySchema, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateComputeImageCapabilitySchemaResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateComputeImageCapabilitySchemaResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateComputeImageCapabilitySchemaResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateComputeImageCapabilitySchemaResponse") + } + return +} + +// updateComputeImageCapabilitySchema implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) updateComputeImageCapabilitySchema(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/computeImageCapabilitySchemas/{computeImageCapabilitySchemaId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateComputeImageCapabilitySchemaResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateConsoleHistory Updates the specified console history metadata. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateConsoleHistory.go.html to see an example of how to use UpdateConsoleHistory API. +func (client ComputeClient) UpdateConsoleHistory(ctx context.Context, request UpdateConsoleHistoryRequest) (response UpdateConsoleHistoryResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateConsoleHistory, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateConsoleHistoryResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateConsoleHistoryResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateConsoleHistoryResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateConsoleHistoryResponse") + } + return +} + +// updateConsoleHistory implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) updateConsoleHistory(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/instanceConsoleHistories/{instanceConsoleHistoryId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateConsoleHistoryResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateDedicatedVmHost Updates the displayName, freeformTags, and definedTags attributes for the specified dedicated virtual machine host. +// If an attribute value is not included, it will not be updated. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDedicatedVmHost.go.html to see an example of how to use UpdateDedicatedVmHost API. +func (client ComputeClient) UpdateDedicatedVmHost(ctx context.Context, request UpdateDedicatedVmHostRequest) (response UpdateDedicatedVmHostResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.updateDedicatedVmHost, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateDedicatedVmHostResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateDedicatedVmHostResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateDedicatedVmHostResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateDedicatedVmHostResponse") + } + return +} + +// updateDedicatedVmHost implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) updateDedicatedVmHost(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/dedicatedVmHosts/{dedicatedVmHostId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateDedicatedVmHostResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateImage Updates the display name of the image. Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateImage.go.html to see an example of how to use UpdateImage API. +func (client ComputeClient) UpdateImage(ctx context.Context, request UpdateImageRequest) (response UpdateImageResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.updateImage, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateImageResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateImageResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateImageResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateImageResponse") + } + return +} + +// updateImage implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) updateImage(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/images/{imageId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateImageResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateInstance Updates certain fields on the specified instance. Fields that are not provided in the +// request will not be updated. Avoid entering confidential information. +// Changes to metadata fields will be reflected in the instance metadata service (this may take +// up to a minute). +// The OCID of the instance remains the same. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateInstance.go.html to see an example of how to use UpdateInstance API. +func (client ComputeClient) UpdateInstance(ctx context.Context, request UpdateInstanceRequest) (response UpdateInstanceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.updateInstance, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateInstanceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateInstanceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateInstanceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateInstanceResponse") + } + return +} + +// updateInstance implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) updateInstance(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/instances/{instanceId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateInstanceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateInstanceConsoleConnection Updates the defined tags and free-form tags for the specified instance console connection. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateInstanceConsoleConnection.go.html to see an example of how to use UpdateInstanceConsoleConnection API. +func (client ComputeClient) UpdateInstanceConsoleConnection(ctx context.Context, request UpdateInstanceConsoleConnectionRequest) (response UpdateInstanceConsoleConnectionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateInstanceConsoleConnection, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateInstanceConsoleConnectionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateInstanceConsoleConnectionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateInstanceConsoleConnectionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateInstanceConsoleConnectionResponse") + } + return +} + +// updateInstanceConsoleConnection implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) updateInstanceConsoleConnection(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/instanceConsoleConnections/{instanceConsoleConnectionId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateInstanceConsoleConnectionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateVolumeAttachment Updates information about the specified volume attachment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVolumeAttachment.go.html to see an example of how to use UpdateVolumeAttachment API. +func (client ComputeClient) UpdateVolumeAttachment(ctx context.Context, request UpdateVolumeAttachmentRequest) (response UpdateVolumeAttachmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateVolumeAttachment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateVolumeAttachmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateVolumeAttachmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateVolumeAttachmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateVolumeAttachmentResponse") + } + return +} + +// updateVolumeAttachment implements the OCIOperation interface (enables retrying operations) +func (client ComputeClient) updateVolumeAttachment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/volumeAttachments/{volumeAttachmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateVolumeAttachmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponseWithPolymorphicBody(httpResponse, &response, &volumeattachment{}) + return response, err +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/core_computemanagement_client.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/core_computemanagement_client.go new file mode 100644 index 000000000..b6718e4ca --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/core_computemanagement_client.go @@ -0,0 +1,1925 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "context" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" + "github.com/oracle/oci-go-sdk/v54/common/auth" + "net/http" +) + +//ComputeManagementClient a client for ComputeManagement +type ComputeManagementClient struct { + common.BaseClient + config *common.ConfigurationProvider +} + +// NewComputeManagementClientWithConfigurationProvider Creates a new default ComputeManagement client with the given configuration provider. +// the configuration provider will be used for the default signer as well as reading the region +func NewComputeManagementClientWithConfigurationProvider(configProvider common.ConfigurationProvider) (client ComputeManagementClient, err error) { + provider, err := auth.GetGenericConfigurationProvider(configProvider) + if err != nil { + return client, err + } + baseClient, e := common.NewClientWithConfig(provider) + if e != nil { + return client, e + } + return newComputeManagementClientFromBaseClient(baseClient, provider) +} + +// NewComputeManagementClientWithOboToken Creates a new default ComputeManagement client with the given configuration provider. +// The obotoken will be added to default headers and signed; the configuration provider will be used for the signer +// as well as reading the region +func NewComputeManagementClientWithOboToken(configProvider common.ConfigurationProvider, oboToken string) (client ComputeManagementClient, err error) { + baseClient, err := common.NewClientWithOboToken(configProvider, oboToken) + if err != nil { + return client, err + } + + return newComputeManagementClientFromBaseClient(baseClient, configProvider) +} + +func newComputeManagementClientFromBaseClient(baseClient common.BaseClient, configProvider common.ConfigurationProvider) (client ComputeManagementClient, err error) { + // ComputeManagement service default circuit breaker is enabled + baseClient.Configuration.CircuitBreaker = common.NewCircuitBreaker(common.DefaultCircuitBreakerSetting()) + common.ConfigCircuitBreakerFromEnvVar(&baseClient) + common.ConfigCircuitBreakerFromGlobalVar(&baseClient) + + client = ComputeManagementClient{BaseClient: baseClient} + client.BasePath = "20160918" + err = client.setConfigurationProvider(configProvider) + return +} + +// SetRegion overrides the region of this client. +func (client *ComputeManagementClient) SetRegion(region string) { + client.Host = common.StringToRegion(region).EndpointForTemplate("iaas", "https://iaas.{region}.{secondLevelDomain}") +} + +// SetConfigurationProvider sets the configuration provider including the region, returns an error if is not valid +func (client *ComputeManagementClient) setConfigurationProvider(configProvider common.ConfigurationProvider) error { + if ok, err := common.IsConfigurationProviderValid(configProvider); !ok { + return err + } + + // Error has been checked already + region, _ := configProvider.Region() + client.SetRegion(region) + client.config = &configProvider + return nil +} + +// ConfigurationProvider the ConfigurationProvider used in this client, or null if none set +func (client *ComputeManagementClient) ConfigurationProvider() *common.ConfigurationProvider { + return client.config +} + +// AttachInstancePoolInstance Attaches an instance to an instance pool. For information about the prerequisites +// that an instance must meet before you can attach it to a pool, see +// Attaching an Instance to an Instance Pool (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/updatinginstancepool.htm#attach-instance). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AttachInstancePoolInstance.go.html to see an example of how to use AttachInstancePoolInstance API. +func (client ComputeManagementClient) AttachInstancePoolInstance(ctx context.Context, request AttachInstancePoolInstanceRequest) (response AttachInstancePoolInstanceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.attachInstancePoolInstance, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AttachInstancePoolInstanceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AttachInstancePoolInstanceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AttachInstancePoolInstanceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AttachInstancePoolInstanceResponse") + } + return +} + +// attachInstancePoolInstance implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) attachInstancePoolInstance(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instancePools/{instancePoolId}/instances", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AttachInstancePoolInstanceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// AttachLoadBalancer Attach a load balancer to the instance pool. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AttachLoadBalancer.go.html to see an example of how to use AttachLoadBalancer API. +func (client ComputeManagementClient) AttachLoadBalancer(ctx context.Context, request AttachLoadBalancerRequest) (response AttachLoadBalancerResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.attachLoadBalancer, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AttachLoadBalancerResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AttachLoadBalancerResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AttachLoadBalancerResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AttachLoadBalancerResponse") + } + return +} + +// attachLoadBalancer implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) attachLoadBalancer(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instancePools/{instancePoolId}/actions/attachLoadBalancer", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AttachLoadBalancerResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeClusterNetworkCompartment Moves a cluster network into a different compartment within the same tenancy. For +// information about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// When you move a cluster network to a different compartment, associated resources such as the instances +// in the cluster network, boot volumes, and VNICs are not moved. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeClusterNetworkCompartment.go.html to see an example of how to use ChangeClusterNetworkCompartment API. +func (client ComputeManagementClient) ChangeClusterNetworkCompartment(ctx context.Context, request ChangeClusterNetworkCompartmentRequest) (response ChangeClusterNetworkCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeClusterNetworkCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeClusterNetworkCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeClusterNetworkCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeClusterNetworkCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeClusterNetworkCompartmentResponse") + } + return +} + +// changeClusterNetworkCompartment implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) changeClusterNetworkCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/clusterNetworks/{clusterNetworkId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeClusterNetworkCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeInstanceConfigurationCompartment Moves an instance configuration into a different compartment within the same tenancy. +// For information about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// When you move an instance configuration to a different compartment, associated resources such as +// instance pools are not moved. +// **Important:** Most of the properties for an existing instance configuration, including the compartment, +// cannot be modified after you create the instance configuration. Although you can move an instance configuration +// to a different compartment, you will not be able to use the instance configuration to manage instance pools +// in the new compartment. If you want to update an instance configuration to point to a different compartment, +// you should instead create a new instance configuration in the target compartment using +// CreateInstanceConfiguration (https://docs.cloud.oracle.com/iaas/api/#/en/iaas/20160918/InstanceConfiguration/CreateInstanceConfiguration). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeInstanceConfigurationCompartment.go.html to see an example of how to use ChangeInstanceConfigurationCompartment API. +func (client ComputeManagementClient) ChangeInstanceConfigurationCompartment(ctx context.Context, request ChangeInstanceConfigurationCompartmentRequest) (response ChangeInstanceConfigurationCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeInstanceConfigurationCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeInstanceConfigurationCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeInstanceConfigurationCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeInstanceConfigurationCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeInstanceConfigurationCompartmentResponse") + } + return +} + +// changeInstanceConfigurationCompartment implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) changeInstanceConfigurationCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instanceConfigurations/{instanceConfigurationId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeInstanceConfigurationCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeInstancePoolCompartment Moves an instance pool into a different compartment within the same tenancy. For +// information about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// When you move an instance pool to a different compartment, associated resources such as the instances in +// the pool, boot volumes, VNICs, and autoscaling configurations are not moved. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeInstancePoolCompartment.go.html to see an example of how to use ChangeInstancePoolCompartment API. +func (client ComputeManagementClient) ChangeInstancePoolCompartment(ctx context.Context, request ChangeInstancePoolCompartmentRequest) (response ChangeInstancePoolCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeInstancePoolCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeInstancePoolCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeInstancePoolCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeInstancePoolCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeInstancePoolCompartmentResponse") + } + return +} + +// changeInstancePoolCompartment implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) changeInstancePoolCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instancePools/{instancePoolId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeInstancePoolCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateClusterNetwork Creates a cluster network. For more information about cluster networks, see +// Managing Cluster Networks (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/managingclusternetworks.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateClusterNetwork.go.html to see an example of how to use CreateClusterNetwork API. +func (client ComputeManagementClient) CreateClusterNetwork(ctx context.Context, request CreateClusterNetworkRequest) (response CreateClusterNetworkResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createClusterNetwork, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateClusterNetworkResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateClusterNetworkResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateClusterNetworkResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateClusterNetworkResponse") + } + return +} + +// createClusterNetwork implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) createClusterNetwork(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/clusterNetworks", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateClusterNetworkResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateInstanceConfiguration Creates an instance configuration. An instance configuration is a template that defines the +// settings to use when creating Compute instances. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateInstanceConfiguration.go.html to see an example of how to use CreateInstanceConfiguration API. +func (client ComputeManagementClient) CreateInstanceConfiguration(ctx context.Context, request CreateInstanceConfigurationRequest) (response CreateInstanceConfigurationResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createInstanceConfiguration, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateInstanceConfigurationResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateInstanceConfigurationResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateInstanceConfigurationResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateInstanceConfigurationResponse") + } + return +} + +// createInstanceConfiguration implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) createInstanceConfiguration(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instanceConfigurations", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateInstanceConfigurationResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateInstancePool Create an instance pool. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateInstancePool.go.html to see an example of how to use CreateInstancePool API. +func (client ComputeManagementClient) CreateInstancePool(ctx context.Context, request CreateInstancePoolRequest) (response CreateInstancePoolResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createInstancePool, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateInstancePoolResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateInstancePoolResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateInstancePoolResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateInstancePoolResponse") + } + return +} + +// createInstancePool implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) createInstancePool(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instancePools", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateInstancePoolResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteInstanceConfiguration Deletes an instance configuration. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteInstanceConfiguration.go.html to see an example of how to use DeleteInstanceConfiguration API. +func (client ComputeManagementClient) DeleteInstanceConfiguration(ctx context.Context, request DeleteInstanceConfigurationRequest) (response DeleteInstanceConfigurationResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteInstanceConfiguration, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteInstanceConfigurationResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteInstanceConfigurationResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteInstanceConfigurationResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteInstanceConfigurationResponse") + } + return +} + +// deleteInstanceConfiguration implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) deleteInstanceConfiguration(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/instanceConfigurations/{instanceConfigurationId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteInstanceConfigurationResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DetachInstancePoolInstance Detaches an instance from an instance pool. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DetachInstancePoolInstance.go.html to see an example of how to use DetachInstancePoolInstance API. +func (client ComputeManagementClient) DetachInstancePoolInstance(ctx context.Context, request DetachInstancePoolInstanceRequest) (response DetachInstancePoolInstanceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.detachInstancePoolInstance, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DetachInstancePoolInstanceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DetachInstancePoolInstanceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DetachInstancePoolInstanceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DetachInstancePoolInstanceResponse") + } + return +} + +// detachInstancePoolInstance implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) detachInstancePoolInstance(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instancePools/{instancePoolId}/actions/detachInstance", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DetachInstancePoolInstanceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DetachLoadBalancer Detach a load balancer from the instance pool. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DetachLoadBalancer.go.html to see an example of how to use DetachLoadBalancer API. +func (client ComputeManagementClient) DetachLoadBalancer(ctx context.Context, request DetachLoadBalancerRequest) (response DetachLoadBalancerResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.detachLoadBalancer, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DetachLoadBalancerResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DetachLoadBalancerResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DetachLoadBalancerResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DetachLoadBalancerResponse") + } + return +} + +// detachLoadBalancer implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) detachLoadBalancer(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instancePools/{instancePoolId}/actions/detachLoadBalancer", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DetachLoadBalancerResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetClusterNetwork Gets information about the specified cluster network. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetClusterNetwork.go.html to see an example of how to use GetClusterNetwork API. +func (client ComputeManagementClient) GetClusterNetwork(ctx context.Context, request GetClusterNetworkRequest) (response GetClusterNetworkResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getClusterNetwork, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetClusterNetworkResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetClusterNetworkResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetClusterNetworkResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetClusterNetworkResponse") + } + return +} + +// getClusterNetwork implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) getClusterNetwork(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/clusterNetworks/{clusterNetworkId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetClusterNetworkResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetInstanceConfiguration Gets the specified instance configuration +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetInstanceConfiguration.go.html to see an example of how to use GetInstanceConfiguration API. +func (client ComputeManagementClient) GetInstanceConfiguration(ctx context.Context, request GetInstanceConfigurationRequest) (response GetInstanceConfigurationResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getInstanceConfiguration, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetInstanceConfigurationResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetInstanceConfigurationResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetInstanceConfigurationResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetInstanceConfigurationResponse") + } + return +} + +// getInstanceConfiguration implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) getInstanceConfiguration(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instanceConfigurations/{instanceConfigurationId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetInstanceConfigurationResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetInstancePool Gets the specified instance pool +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetInstancePool.go.html to see an example of how to use GetInstancePool API. +func (client ComputeManagementClient) GetInstancePool(ctx context.Context, request GetInstancePoolRequest) (response GetInstancePoolResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getInstancePool, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetInstancePoolResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetInstancePoolResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetInstancePoolResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetInstancePoolResponse") + } + return +} + +// getInstancePool implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) getInstancePool(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instancePools/{instancePoolId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetInstancePoolResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetInstancePoolInstance Gets information about an instance that belongs to an instance pool. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetInstancePoolInstance.go.html to see an example of how to use GetInstancePoolInstance API. +func (client ComputeManagementClient) GetInstancePoolInstance(ctx context.Context, request GetInstancePoolInstanceRequest) (response GetInstancePoolInstanceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getInstancePoolInstance, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetInstancePoolInstanceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetInstancePoolInstanceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetInstancePoolInstanceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetInstancePoolInstanceResponse") + } + return +} + +// getInstancePoolInstance implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) getInstancePoolInstance(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instancePools/{instancePoolId}/instances/{instanceId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetInstancePoolInstanceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetInstancePoolLoadBalancerAttachment Gets information about a load balancer that is attached to the specified instance pool. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetInstancePoolLoadBalancerAttachment.go.html to see an example of how to use GetInstancePoolLoadBalancerAttachment API. +func (client ComputeManagementClient) GetInstancePoolLoadBalancerAttachment(ctx context.Context, request GetInstancePoolLoadBalancerAttachmentRequest) (response GetInstancePoolLoadBalancerAttachmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getInstancePoolLoadBalancerAttachment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetInstancePoolLoadBalancerAttachmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetInstancePoolLoadBalancerAttachmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetInstancePoolLoadBalancerAttachmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetInstancePoolLoadBalancerAttachmentResponse") + } + return +} + +// getInstancePoolLoadBalancerAttachment implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) getInstancePoolLoadBalancerAttachment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instancePools/{instancePoolId}/loadBalancerAttachments/{instancePoolLoadBalancerAttachmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetInstancePoolLoadBalancerAttachmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// LaunchInstanceConfiguration Launches an instance from an instance configuration. +// If the instance configuration does not include all of the parameters that are +// required to launch an instance, such as the availability domain and subnet ID, you must +// provide these parameters when you launch an instance from the instance configuration. +// For more information, see the InstanceConfiguration +// resource. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/LaunchInstanceConfiguration.go.html to see an example of how to use LaunchInstanceConfiguration API. +func (client ComputeManagementClient) LaunchInstanceConfiguration(ctx context.Context, request LaunchInstanceConfigurationRequest) (response LaunchInstanceConfigurationResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.launchInstanceConfiguration, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = LaunchInstanceConfigurationResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = LaunchInstanceConfigurationResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(LaunchInstanceConfigurationResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into LaunchInstanceConfigurationResponse") + } + return +} + +// launchInstanceConfiguration implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) launchInstanceConfiguration(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instanceConfigurations/{instanceConfigurationId}/actions/launch", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response LaunchInstanceConfigurationResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListClusterNetworkInstances Lists the instances in the specified cluster network. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListClusterNetworkInstances.go.html to see an example of how to use ListClusterNetworkInstances API. +func (client ComputeManagementClient) ListClusterNetworkInstances(ctx context.Context, request ListClusterNetworkInstancesRequest) (response ListClusterNetworkInstancesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listClusterNetworkInstances, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListClusterNetworkInstancesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListClusterNetworkInstancesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListClusterNetworkInstancesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListClusterNetworkInstancesResponse") + } + return +} + +// listClusterNetworkInstances implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) listClusterNetworkInstances(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/clusterNetworks/{clusterNetworkId}/instances", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListClusterNetworkInstancesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListClusterNetworks Lists the cluster networks in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListClusterNetworks.go.html to see an example of how to use ListClusterNetworks API. +func (client ComputeManagementClient) ListClusterNetworks(ctx context.Context, request ListClusterNetworksRequest) (response ListClusterNetworksResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listClusterNetworks, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListClusterNetworksResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListClusterNetworksResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListClusterNetworksResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListClusterNetworksResponse") + } + return +} + +// listClusterNetworks implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) listClusterNetworks(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/clusterNetworks", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListClusterNetworksResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListInstanceConfigurations Lists the instance configurations in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListInstanceConfigurations.go.html to see an example of how to use ListInstanceConfigurations API. +func (client ComputeManagementClient) ListInstanceConfigurations(ctx context.Context, request ListInstanceConfigurationsRequest) (response ListInstanceConfigurationsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listInstanceConfigurations, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListInstanceConfigurationsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListInstanceConfigurationsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListInstanceConfigurationsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListInstanceConfigurationsResponse") + } + return +} + +// listInstanceConfigurations implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) listInstanceConfigurations(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instanceConfigurations", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListInstanceConfigurationsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListInstancePoolInstances List the instances in the specified instance pool. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListInstancePoolInstances.go.html to see an example of how to use ListInstancePoolInstances API. +func (client ComputeManagementClient) ListInstancePoolInstances(ctx context.Context, request ListInstancePoolInstancesRequest) (response ListInstancePoolInstancesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listInstancePoolInstances, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListInstancePoolInstancesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListInstancePoolInstancesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListInstancePoolInstancesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListInstancePoolInstancesResponse") + } + return +} + +// listInstancePoolInstances implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) listInstancePoolInstances(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instancePools/{instancePoolId}/instances", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListInstancePoolInstancesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListInstancePools Lists the instance pools in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListInstancePools.go.html to see an example of how to use ListInstancePools API. +func (client ComputeManagementClient) ListInstancePools(ctx context.Context, request ListInstancePoolsRequest) (response ListInstancePoolsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listInstancePools, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListInstancePoolsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListInstancePoolsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListInstancePoolsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListInstancePoolsResponse") + } + return +} + +// listInstancePools implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) listInstancePools(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/instancePools", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListInstancePoolsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ResetInstancePool Performs the reset (immediate power off and power on) action on the specified instance pool, +// which performs the action on all the instances in the pool. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ResetInstancePool.go.html to see an example of how to use ResetInstancePool API. +func (client ComputeManagementClient) ResetInstancePool(ctx context.Context, request ResetInstancePoolRequest) (response ResetInstancePoolResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.resetInstancePool, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ResetInstancePoolResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ResetInstancePoolResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ResetInstancePoolResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ResetInstancePoolResponse") + } + return +} + +// resetInstancePool implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) resetInstancePool(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instancePools/{instancePoolId}/actions/reset", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ResetInstancePoolResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// SoftresetInstancePool Performs the softreset (ACPI shutdown and power on) action on the specified instance pool, +// which performs the action on all the instances in the pool. +// Softreset gracefully reboots the instances by sending a shutdown command to the operating systems. +// After waiting 15 minutes for the OS to shut down, the instances are powered off and then powered back on. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/SoftresetInstancePool.go.html to see an example of how to use SoftresetInstancePool API. +func (client ComputeManagementClient) SoftresetInstancePool(ctx context.Context, request SoftresetInstancePoolRequest) (response SoftresetInstancePoolResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.softresetInstancePool, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = SoftresetInstancePoolResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = SoftresetInstancePoolResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(SoftresetInstancePoolResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into SoftresetInstancePoolResponse") + } + return +} + +// softresetInstancePool implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) softresetInstancePool(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instancePools/{instancePoolId}/actions/softreset", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response SoftresetInstancePoolResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// StartInstancePool Performs the start (power on) action on the specified instance pool, +// which performs the action on all the instances in the pool. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/StartInstancePool.go.html to see an example of how to use StartInstancePool API. +func (client ComputeManagementClient) StartInstancePool(ctx context.Context, request StartInstancePoolRequest) (response StartInstancePoolResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.startInstancePool, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = StartInstancePoolResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = StartInstancePoolResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(StartInstancePoolResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into StartInstancePoolResponse") + } + return +} + +// startInstancePool implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) startInstancePool(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instancePools/{instancePoolId}/actions/start", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response StartInstancePoolResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// StopInstancePool Performs the stop (immediate power off) action on the specified instance pool, +// which performs the action on all the instances in the pool. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/StopInstancePool.go.html to see an example of how to use StopInstancePool API. +func (client ComputeManagementClient) StopInstancePool(ctx context.Context, request StopInstancePoolRequest) (response StopInstancePoolResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.stopInstancePool, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = StopInstancePoolResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = StopInstancePoolResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(StopInstancePoolResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into StopInstancePoolResponse") + } + return +} + +// stopInstancePool implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) stopInstancePool(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/instancePools/{instancePoolId}/actions/stop", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response StopInstancePoolResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// TerminateClusterNetwork Terminates the specified cluster network. +// When you delete a cluster network, all of its resources are permanently deleted, +// including associated instances and instance pools. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/TerminateClusterNetwork.go.html to see an example of how to use TerminateClusterNetwork API. +func (client ComputeManagementClient) TerminateClusterNetwork(ctx context.Context, request TerminateClusterNetworkRequest) (response TerminateClusterNetworkResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.terminateClusterNetwork, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = TerminateClusterNetworkResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = TerminateClusterNetworkResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(TerminateClusterNetworkResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into TerminateClusterNetworkResponse") + } + return +} + +// terminateClusterNetwork implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) terminateClusterNetwork(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/clusterNetworks/{clusterNetworkId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response TerminateClusterNetworkResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// TerminateInstancePool Terminate the specified instance pool. +// **Warning:** When you delete an instance pool, the resources that were created by the pool are permanently +// deleted, including associated instances, attached boot volumes, and block volumes. +// If an autoscaling configuration applies to the instance pool, the autoscaling configuration will be deleted +// asynchronously after the pool is deleted. You can also manually delete the autoscaling configuration using +// the `DeleteAutoScalingConfiguration` operation in the Autoscaling API. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/TerminateInstancePool.go.html to see an example of how to use TerminateInstancePool API. +func (client ComputeManagementClient) TerminateInstancePool(ctx context.Context, request TerminateInstancePoolRequest) (response TerminateInstancePoolResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.terminateInstancePool, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = TerminateInstancePoolResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = TerminateInstancePoolResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(TerminateInstancePoolResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into TerminateInstancePoolResponse") + } + return +} + +// terminateInstancePool implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) terminateInstancePool(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/instancePools/{instancePoolId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response TerminateInstancePoolResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateClusterNetwork Updates the specified cluster network. The OCID of the cluster network remains the same. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateClusterNetwork.go.html to see an example of how to use UpdateClusterNetwork API. +func (client ComputeManagementClient) UpdateClusterNetwork(ctx context.Context, request UpdateClusterNetworkRequest) (response UpdateClusterNetworkResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.updateClusterNetwork, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateClusterNetworkResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateClusterNetworkResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateClusterNetworkResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateClusterNetworkResponse") + } + return +} + +// updateClusterNetwork implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) updateClusterNetwork(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/clusterNetworks/{clusterNetworkId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateClusterNetworkResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateInstanceConfiguration Updates the free-form tags, defined tags, and display name of an instance configuration. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateInstanceConfiguration.go.html to see an example of how to use UpdateInstanceConfiguration API. +func (client ComputeManagementClient) UpdateInstanceConfiguration(ctx context.Context, request UpdateInstanceConfigurationRequest) (response UpdateInstanceConfigurationResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.updateInstanceConfiguration, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateInstanceConfigurationResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateInstanceConfigurationResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateInstanceConfigurationResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateInstanceConfigurationResponse") + } + return +} + +// updateInstanceConfiguration implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) updateInstanceConfiguration(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/instanceConfigurations/{instanceConfigurationId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateInstanceConfigurationResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateInstancePool Update the specified instance pool. +// The OCID of the instance pool remains the same. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateInstancePool.go.html to see an example of how to use UpdateInstancePool API. +func (client ComputeManagementClient) UpdateInstancePool(ctx context.Context, request UpdateInstancePoolRequest) (response UpdateInstancePoolResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.updateInstancePool, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateInstancePoolResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateInstancePoolResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateInstancePoolResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateInstancePoolResponse") + } + return +} + +// updateInstancePool implements the OCIOperation interface (enables retrying operations) +func (client ComputeManagementClient) updateInstancePool(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/instancePools/{instancePoolId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateInstancePoolResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/core_virtualnetwork_client.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/core_virtualnetwork_client.go new file mode 100644 index 000000000..5dd1cdfcc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/core_virtualnetwork_client.go @@ -0,0 +1,13456 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "context" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" + "github.com/oracle/oci-go-sdk/v54/common/auth" + "net/http" +) + +//VirtualNetworkClient a client for VirtualNetwork +type VirtualNetworkClient struct { + common.BaseClient + config *common.ConfigurationProvider +} + +// NewVirtualNetworkClientWithConfigurationProvider Creates a new default VirtualNetwork client with the given configuration provider. +// the configuration provider will be used for the default signer as well as reading the region +func NewVirtualNetworkClientWithConfigurationProvider(configProvider common.ConfigurationProvider) (client VirtualNetworkClient, err error) { + provider, err := auth.GetGenericConfigurationProvider(configProvider) + if err != nil { + return client, err + } + baseClient, e := common.NewClientWithConfig(provider) + if e != nil { + return client, e + } + return newVirtualNetworkClientFromBaseClient(baseClient, provider) +} + +// NewVirtualNetworkClientWithOboToken Creates a new default VirtualNetwork client with the given configuration provider. +// The obotoken will be added to default headers and signed; the configuration provider will be used for the signer +// as well as reading the region +func NewVirtualNetworkClientWithOboToken(configProvider common.ConfigurationProvider, oboToken string) (client VirtualNetworkClient, err error) { + baseClient, err := common.NewClientWithOboToken(configProvider, oboToken) + if err != nil { + return client, err + } + + return newVirtualNetworkClientFromBaseClient(baseClient, configProvider) +} + +func newVirtualNetworkClientFromBaseClient(baseClient common.BaseClient, configProvider common.ConfigurationProvider) (client VirtualNetworkClient, err error) { + // VirtualNetwork service default circuit breaker is enabled + baseClient.Configuration.CircuitBreaker = common.NewCircuitBreaker(common.DefaultCircuitBreakerSetting()) + common.ConfigCircuitBreakerFromEnvVar(&baseClient) + common.ConfigCircuitBreakerFromGlobalVar(&baseClient) + + client = VirtualNetworkClient{BaseClient: baseClient} + client.BasePath = "20160918" + err = client.setConfigurationProvider(configProvider) + return +} + +// SetRegion overrides the region of this client. +func (client *VirtualNetworkClient) SetRegion(region string) { + client.Host = common.StringToRegion(region).EndpointForTemplate("iaas", "https://iaas.{region}.{secondLevelDomain}") +} + +// SetConfigurationProvider sets the configuration provider including the region, returns an error if is not valid +func (client *VirtualNetworkClient) setConfigurationProvider(configProvider common.ConfigurationProvider) error { + if ok, err := common.IsConfigurationProviderValid(configProvider); !ok { + return err + } + + // Error has been checked already + region, _ := configProvider.Region() + client.SetRegion(region) + client.config = &configProvider + return nil +} + +// ConfigurationProvider the ConfigurationProvider used in this client, or null if none set +func (client *VirtualNetworkClient) ConfigurationProvider() *common.ConfigurationProvider { + return client.config +} + +// AddDrgRouteDistributionStatements Adds one or more route distribution statements to the specified route distribution. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AddDrgRouteDistributionStatements.go.html to see an example of how to use AddDrgRouteDistributionStatements API. +func (client VirtualNetworkClient) AddDrgRouteDistributionStatements(ctx context.Context, request AddDrgRouteDistributionStatementsRequest) (response AddDrgRouteDistributionStatementsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.addDrgRouteDistributionStatements, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AddDrgRouteDistributionStatementsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AddDrgRouteDistributionStatementsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AddDrgRouteDistributionStatementsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AddDrgRouteDistributionStatementsResponse") + } + return +} + +// addDrgRouteDistributionStatements implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) addDrgRouteDistributionStatements(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/drgRouteDistributions/{drgRouteDistributionId}/actions/addDrgRouteDistributionStatements", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AddDrgRouteDistributionStatementsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// AddDrgRouteRules Adds one or more static route rules to the specified DRG route table. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AddDrgRouteRules.go.html to see an example of how to use AddDrgRouteRules API. +func (client VirtualNetworkClient) AddDrgRouteRules(ctx context.Context, request AddDrgRouteRulesRequest) (response AddDrgRouteRulesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.addDrgRouteRules, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AddDrgRouteRulesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AddDrgRouteRulesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AddDrgRouteRulesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AddDrgRouteRulesResponse") + } + return +} + +// addDrgRouteRules implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) addDrgRouteRules(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/drgRouteTables/{drgRouteTableId}/actions/addDrgRouteRules", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AddDrgRouteRulesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// AddIpv6VcnCidr Add an IPv6 CIDR to a VCN. The VCN size is always /56 and assigned by Oracle. +// Once added the IPv6 CIDR block cannot be removed or modified. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AddIpv6VcnCidr.go.html to see an example of how to use AddIpv6VcnCidr API. +func (client VirtualNetworkClient) AddIpv6VcnCidr(ctx context.Context, request AddIpv6VcnCidrRequest) (response AddIpv6VcnCidrResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.addIpv6VcnCidr, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AddIpv6VcnCidrResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AddIpv6VcnCidrResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AddIpv6VcnCidrResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AddIpv6VcnCidrResponse") + } + return +} + +// addIpv6VcnCidr implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) addIpv6VcnCidr(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/vcns/{vcnId}/actions/addIpv6Cidr", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AddIpv6VcnCidrResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// AddNetworkSecurityGroupSecurityRules Adds one or more security rules to the specified network security group. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AddNetworkSecurityGroupSecurityRules.go.html to see an example of how to use AddNetworkSecurityGroupSecurityRules API. +func (client VirtualNetworkClient) AddNetworkSecurityGroupSecurityRules(ctx context.Context, request AddNetworkSecurityGroupSecurityRulesRequest) (response AddNetworkSecurityGroupSecurityRulesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.addNetworkSecurityGroupSecurityRules, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AddNetworkSecurityGroupSecurityRulesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AddNetworkSecurityGroupSecurityRulesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AddNetworkSecurityGroupSecurityRulesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AddNetworkSecurityGroupSecurityRulesResponse") + } + return +} + +// addNetworkSecurityGroupSecurityRules implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) addNetworkSecurityGroupSecurityRules(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/networkSecurityGroups/{networkSecurityGroupId}/actions/addSecurityRules", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AddNetworkSecurityGroupSecurityRulesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// AddPublicIpPoolCapacity Adds some or all of a CIDR block to a public IP pool. +// The CIDR block (or subrange) must not overlap with any other CIDR block already added to this or any other public IP pool. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AddPublicIpPoolCapacity.go.html to see an example of how to use AddPublicIpPoolCapacity API. +func (client VirtualNetworkClient) AddPublicIpPoolCapacity(ctx context.Context, request AddPublicIpPoolCapacityRequest) (response AddPublicIpPoolCapacityResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.addPublicIpPoolCapacity, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AddPublicIpPoolCapacityResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AddPublicIpPoolCapacityResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AddPublicIpPoolCapacityResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AddPublicIpPoolCapacityResponse") + } + return +} + +// addPublicIpPoolCapacity implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) addPublicIpPoolCapacity(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/publicIpPools/{publicIpPoolId}/actions/addCapacity", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AddPublicIpPoolCapacityResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// AddVcnCidr Adds a CIDR block to a VCN. The CIDR block you add: +// - Must be valid. +// - Must not overlap with another CIDR block in the VCN, a CIDR block of a peered VCN, or the on-premises network CIDR block. +// - Must not exceed the limit of CIDR blocks allowed per VCN. +// **Note:** Adding a CIDR block places your VCN in an updating state until the changes are complete. You cannot create or update the VCN's subnets, VLANs, LPGs, or route tables during this operation. The time to completion can take a few minutes. You can use the `GetWorkRequest` operation to check the status of the update. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AddVcnCidr.go.html to see an example of how to use AddVcnCidr API. +func (client VirtualNetworkClient) AddVcnCidr(ctx context.Context, request AddVcnCidrRequest) (response AddVcnCidrResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.addVcnCidr, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AddVcnCidrResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AddVcnCidrResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AddVcnCidrResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AddVcnCidrResponse") + } + return +} + +// addVcnCidr implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) addVcnCidr(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/vcns/{vcnId}/actions/addCidr", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AddVcnCidrResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// AdvertiseByoipRange Begins BGP route advertisements for the BYOIP CIDR block you imported to the Oracle Cloud. +// The `ByoipRange` resource must be in the PROVISIONED state before the BYOIP CIDR block routes can be advertised with BGP. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AdvertiseByoipRange.go.html to see an example of how to use AdvertiseByoipRange API. +func (client VirtualNetworkClient) AdvertiseByoipRange(ctx context.Context, request AdvertiseByoipRangeRequest) (response AdvertiseByoipRangeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.advertiseByoipRange, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AdvertiseByoipRangeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AdvertiseByoipRangeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AdvertiseByoipRangeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AdvertiseByoipRangeResponse") + } + return +} + +// advertiseByoipRange implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) advertiseByoipRange(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/byoipRanges/{byoipRangeId}/actions/advertise", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AdvertiseByoipRangeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// AttachServiceId Adds the specified Service to the list of enabled +// `Service` objects for the specified gateway. You must also set up a route rule with the +// `cidrBlock` of the `Service` as the rule's destination and the service gateway as the rule's +// target. See RouteTable. +// **Note:** The `AttachServiceId` operation is an easy way to add an individual `Service` to +// the service gateway. Compare it with +// UpdateServiceGateway, which replaces +// the entire existing list of enabled `Service` objects with the list that you provide in the +// `Update` call. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/AttachServiceId.go.html to see an example of how to use AttachServiceId API. +func (client VirtualNetworkClient) AttachServiceId(ctx context.Context, request AttachServiceIdRequest) (response AttachServiceIdResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.attachServiceId, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AttachServiceIdResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AttachServiceIdResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AttachServiceIdResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AttachServiceIdResponse") + } + return +} + +// attachServiceId implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) attachServiceId(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/serviceGateways/{serviceGatewayId}/actions/attachService", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AttachServiceIdResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// BulkAddVirtualCircuitPublicPrefixes Adds one or more customer public IP prefixes to the specified public virtual circuit. +// Use this operation (and not UpdateVirtualCircuit) +// to add prefixes to the virtual circuit. Oracle must verify the customer's ownership +// of each prefix before traffic for that prefix will flow across the virtual circuit. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/BulkAddVirtualCircuitPublicPrefixes.go.html to see an example of how to use BulkAddVirtualCircuitPublicPrefixes API. +func (client VirtualNetworkClient) BulkAddVirtualCircuitPublicPrefixes(ctx context.Context, request BulkAddVirtualCircuitPublicPrefixesRequest) (response BulkAddVirtualCircuitPublicPrefixesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.bulkAddVirtualCircuitPublicPrefixes, policy) + if err != nil { + if ociResponse != nil { + response = BulkAddVirtualCircuitPublicPrefixesResponse{RawResponse: ociResponse.HTTPResponse()} + } + return + } + if convertedResponse, ok := ociResponse.(BulkAddVirtualCircuitPublicPrefixesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into BulkAddVirtualCircuitPublicPrefixesResponse") + } + return +} + +// bulkAddVirtualCircuitPublicPrefixes implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) bulkAddVirtualCircuitPublicPrefixes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/virtualCircuits/{virtualCircuitId}/actions/bulkAddPublicPrefixes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response BulkAddVirtualCircuitPublicPrefixesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// BulkDeleteVirtualCircuitPublicPrefixes Removes one or more customer public IP prefixes from the specified public virtual circuit. +// Use this operation (and not UpdateVirtualCircuit) +// to remove prefixes from the virtual circuit. When the virtual circuit's state switches +// back to PROVISIONED, Oracle stops advertising the specified prefixes across the connection. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/BulkDeleteVirtualCircuitPublicPrefixes.go.html to see an example of how to use BulkDeleteVirtualCircuitPublicPrefixes API. +func (client VirtualNetworkClient) BulkDeleteVirtualCircuitPublicPrefixes(ctx context.Context, request BulkDeleteVirtualCircuitPublicPrefixesRequest) (response BulkDeleteVirtualCircuitPublicPrefixesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.bulkDeleteVirtualCircuitPublicPrefixes, policy) + if err != nil { + if ociResponse != nil { + response = BulkDeleteVirtualCircuitPublicPrefixesResponse{RawResponse: ociResponse.HTTPResponse()} + } + return + } + if convertedResponse, ok := ociResponse.(BulkDeleteVirtualCircuitPublicPrefixesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into BulkDeleteVirtualCircuitPublicPrefixesResponse") + } + return +} + +// bulkDeleteVirtualCircuitPublicPrefixes implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) bulkDeleteVirtualCircuitPublicPrefixes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/virtualCircuits/{virtualCircuitId}/actions/bulkDeletePublicPrefixes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response BulkDeleteVirtualCircuitPublicPrefixesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeByoipRangeCompartment Moves a BYOIP CIDR block to a different compartment. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeByoipRangeCompartment.go.html to see an example of how to use ChangeByoipRangeCompartment API. +func (client VirtualNetworkClient) ChangeByoipRangeCompartment(ctx context.Context, request ChangeByoipRangeCompartmentRequest) (response ChangeByoipRangeCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeByoipRangeCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeByoipRangeCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeByoipRangeCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeByoipRangeCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeByoipRangeCompartmentResponse") + } + return +} + +// changeByoipRangeCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeByoipRangeCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/byoipRanges/{byoipRangeId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeByoipRangeCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeCpeCompartment Moves a CPE object into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeCpeCompartment.go.html to see an example of how to use ChangeCpeCompartment API. +func (client VirtualNetworkClient) ChangeCpeCompartment(ctx context.Context, request ChangeCpeCompartmentRequest) (response ChangeCpeCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeCpeCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeCpeCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeCpeCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeCpeCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeCpeCompartmentResponse") + } + return +} + +// changeCpeCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeCpeCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/cpes/{cpeId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeCpeCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeCrossConnectCompartment Moves a cross-connect into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeCrossConnectCompartment.go.html to see an example of how to use ChangeCrossConnectCompartment API. +func (client VirtualNetworkClient) ChangeCrossConnectCompartment(ctx context.Context, request ChangeCrossConnectCompartmentRequest) (response ChangeCrossConnectCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeCrossConnectCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeCrossConnectCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeCrossConnectCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeCrossConnectCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeCrossConnectCompartmentResponse") + } + return +} + +// changeCrossConnectCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeCrossConnectCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/crossConnects/{crossConnectId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeCrossConnectCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeCrossConnectGroupCompartment Moves a cross-connect group into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeCrossConnectGroupCompartment.go.html to see an example of how to use ChangeCrossConnectGroupCompartment API. +func (client VirtualNetworkClient) ChangeCrossConnectGroupCompartment(ctx context.Context, request ChangeCrossConnectGroupCompartmentRequest) (response ChangeCrossConnectGroupCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeCrossConnectGroupCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeCrossConnectGroupCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeCrossConnectGroupCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeCrossConnectGroupCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeCrossConnectGroupCompartmentResponse") + } + return +} + +// changeCrossConnectGroupCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeCrossConnectGroupCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/crossConnectGroups/{crossConnectGroupId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeCrossConnectGroupCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeDhcpOptionsCompartment Moves a set of DHCP options into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeDhcpOptionsCompartment.go.html to see an example of how to use ChangeDhcpOptionsCompartment API. +func (client VirtualNetworkClient) ChangeDhcpOptionsCompartment(ctx context.Context, request ChangeDhcpOptionsCompartmentRequest) (response ChangeDhcpOptionsCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeDhcpOptionsCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeDhcpOptionsCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeDhcpOptionsCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeDhcpOptionsCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeDhcpOptionsCompartmentResponse") + } + return +} + +// changeDhcpOptionsCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeDhcpOptionsCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/dhcps/{dhcpId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeDhcpOptionsCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeDrgCompartment Moves a DRG into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeDrgCompartment.go.html to see an example of how to use ChangeDrgCompartment API. +func (client VirtualNetworkClient) ChangeDrgCompartment(ctx context.Context, request ChangeDrgCompartmentRequest) (response ChangeDrgCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeDrgCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeDrgCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeDrgCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeDrgCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeDrgCompartmentResponse") + } + return +} + +// changeDrgCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeDrgCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/drgs/{drgId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeDrgCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeIPSecConnectionCompartment Moves an IPSec connection into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeIPSecConnectionCompartment.go.html to see an example of how to use ChangeIPSecConnectionCompartment API. +func (client VirtualNetworkClient) ChangeIPSecConnectionCompartment(ctx context.Context, request ChangeIPSecConnectionCompartmentRequest) (response ChangeIPSecConnectionCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeIPSecConnectionCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeIPSecConnectionCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeIPSecConnectionCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeIPSecConnectionCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeIPSecConnectionCompartmentResponse") + } + return +} + +// changeIPSecConnectionCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeIPSecConnectionCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/ipsecConnections/{ipscId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeIPSecConnectionCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeInternetGatewayCompartment Moves an internet gateway into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeInternetGatewayCompartment.go.html to see an example of how to use ChangeInternetGatewayCompartment API. +func (client VirtualNetworkClient) ChangeInternetGatewayCompartment(ctx context.Context, request ChangeInternetGatewayCompartmentRequest) (response ChangeInternetGatewayCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeInternetGatewayCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeInternetGatewayCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeInternetGatewayCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeInternetGatewayCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeInternetGatewayCompartmentResponse") + } + return +} + +// changeInternetGatewayCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeInternetGatewayCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/internetGateways/{igId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeInternetGatewayCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeLocalPeeringGatewayCompartment Moves a local peering gateway into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeLocalPeeringGatewayCompartment.go.html to see an example of how to use ChangeLocalPeeringGatewayCompartment API. +func (client VirtualNetworkClient) ChangeLocalPeeringGatewayCompartment(ctx context.Context, request ChangeLocalPeeringGatewayCompartmentRequest) (response ChangeLocalPeeringGatewayCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeLocalPeeringGatewayCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeLocalPeeringGatewayCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeLocalPeeringGatewayCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeLocalPeeringGatewayCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeLocalPeeringGatewayCompartmentResponse") + } + return +} + +// changeLocalPeeringGatewayCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeLocalPeeringGatewayCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/localPeeringGateways/{localPeeringGatewayId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeLocalPeeringGatewayCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeNatGatewayCompartment Moves a NAT gateway into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeNatGatewayCompartment.go.html to see an example of how to use ChangeNatGatewayCompartment API. +func (client VirtualNetworkClient) ChangeNatGatewayCompartment(ctx context.Context, request ChangeNatGatewayCompartmentRequest) (response ChangeNatGatewayCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeNatGatewayCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeNatGatewayCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeNatGatewayCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeNatGatewayCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeNatGatewayCompartmentResponse") + } + return +} + +// changeNatGatewayCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeNatGatewayCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/natGateways/{natGatewayId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeNatGatewayCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeNetworkSecurityGroupCompartment Moves a network security group into a different compartment within the same tenancy. For +// information about moving resources between compartments, see Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeNetworkSecurityGroupCompartment.go.html to see an example of how to use ChangeNetworkSecurityGroupCompartment API. +func (client VirtualNetworkClient) ChangeNetworkSecurityGroupCompartment(ctx context.Context, request ChangeNetworkSecurityGroupCompartmentRequest) (response ChangeNetworkSecurityGroupCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeNetworkSecurityGroupCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeNetworkSecurityGroupCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeNetworkSecurityGroupCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeNetworkSecurityGroupCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeNetworkSecurityGroupCompartmentResponse") + } + return +} + +// changeNetworkSecurityGroupCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeNetworkSecurityGroupCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/networkSecurityGroups/{networkSecurityGroupId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeNetworkSecurityGroupCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangePublicIpCompartment Moves a public IP into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// This operation applies only to reserved public IPs. Ephemeral public IPs always belong to the +// same compartment as their VNIC and move accordingly. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangePublicIpCompartment.go.html to see an example of how to use ChangePublicIpCompartment API. +func (client VirtualNetworkClient) ChangePublicIpCompartment(ctx context.Context, request ChangePublicIpCompartmentRequest) (response ChangePublicIpCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changePublicIpCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangePublicIpCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangePublicIpCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangePublicIpCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangePublicIpCompartmentResponse") + } + return +} + +// changePublicIpCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changePublicIpCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/publicIps/{publicIpId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangePublicIpCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangePublicIpPoolCompartment Moves a public IP pool to a different compartment. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangePublicIpPoolCompartment.go.html to see an example of how to use ChangePublicIpPoolCompartment API. +func (client VirtualNetworkClient) ChangePublicIpPoolCompartment(ctx context.Context, request ChangePublicIpPoolCompartmentRequest) (response ChangePublicIpPoolCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changePublicIpPoolCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangePublicIpPoolCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangePublicIpPoolCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangePublicIpPoolCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangePublicIpPoolCompartmentResponse") + } + return +} + +// changePublicIpPoolCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changePublicIpPoolCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/publicIpPools/{publicIpPoolId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangePublicIpPoolCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeRemotePeeringConnectionCompartment Moves a remote peering connection (RPC) into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeRemotePeeringConnectionCompartment.go.html to see an example of how to use ChangeRemotePeeringConnectionCompartment API. +func (client VirtualNetworkClient) ChangeRemotePeeringConnectionCompartment(ctx context.Context, request ChangeRemotePeeringConnectionCompartmentRequest) (response ChangeRemotePeeringConnectionCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeRemotePeeringConnectionCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeRemotePeeringConnectionCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeRemotePeeringConnectionCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeRemotePeeringConnectionCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeRemotePeeringConnectionCompartmentResponse") + } + return +} + +// changeRemotePeeringConnectionCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeRemotePeeringConnectionCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/remotePeeringConnections/{remotePeeringConnectionId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeRemotePeeringConnectionCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeRouteTableCompartment Moves a route table into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeRouteTableCompartment.go.html to see an example of how to use ChangeRouteTableCompartment API. +func (client VirtualNetworkClient) ChangeRouteTableCompartment(ctx context.Context, request ChangeRouteTableCompartmentRequest) (response ChangeRouteTableCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeRouteTableCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeRouteTableCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeRouteTableCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeRouteTableCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeRouteTableCompartmentResponse") + } + return +} + +// changeRouteTableCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeRouteTableCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/routeTables/{rtId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeRouteTableCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeSecurityListCompartment Moves a security list into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeSecurityListCompartment.go.html to see an example of how to use ChangeSecurityListCompartment API. +func (client VirtualNetworkClient) ChangeSecurityListCompartment(ctx context.Context, request ChangeSecurityListCompartmentRequest) (response ChangeSecurityListCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeSecurityListCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeSecurityListCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeSecurityListCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeSecurityListCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeSecurityListCompartmentResponse") + } + return +} + +// changeSecurityListCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeSecurityListCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/securityLists/{securityListId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeSecurityListCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeServiceGatewayCompartment Moves a service gateway into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeServiceGatewayCompartment.go.html to see an example of how to use ChangeServiceGatewayCompartment API. +func (client VirtualNetworkClient) ChangeServiceGatewayCompartment(ctx context.Context, request ChangeServiceGatewayCompartmentRequest) (response ChangeServiceGatewayCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeServiceGatewayCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeServiceGatewayCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeServiceGatewayCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeServiceGatewayCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeServiceGatewayCompartmentResponse") + } + return +} + +// changeServiceGatewayCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeServiceGatewayCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/serviceGateways/{serviceGatewayId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeServiceGatewayCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeSubnetCompartment Moves a subnet into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeSubnetCompartment.go.html to see an example of how to use ChangeSubnetCompartment API. +func (client VirtualNetworkClient) ChangeSubnetCompartment(ctx context.Context, request ChangeSubnetCompartmentRequest) (response ChangeSubnetCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeSubnetCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeSubnetCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeSubnetCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeSubnetCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeSubnetCompartmentResponse") + } + return +} + +// changeSubnetCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeSubnetCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/subnets/{subnetId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeSubnetCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeVcnCompartment Moves a VCN into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeVcnCompartment.go.html to see an example of how to use ChangeVcnCompartment API. +func (client VirtualNetworkClient) ChangeVcnCompartment(ctx context.Context, request ChangeVcnCompartmentRequest) (response ChangeVcnCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeVcnCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeVcnCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeVcnCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeVcnCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeVcnCompartmentResponse") + } + return +} + +// changeVcnCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeVcnCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/vcns/{vcnId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeVcnCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeVirtualCircuitCompartment Moves a virtual circuit into a different compartment within the same tenancy. For information +// about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeVirtualCircuitCompartment.go.html to see an example of how to use ChangeVirtualCircuitCompartment API. +func (client VirtualNetworkClient) ChangeVirtualCircuitCompartment(ctx context.Context, request ChangeVirtualCircuitCompartmentRequest) (response ChangeVirtualCircuitCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeVirtualCircuitCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeVirtualCircuitCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeVirtualCircuitCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeVirtualCircuitCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeVirtualCircuitCompartmentResponse") + } + return +} + +// changeVirtualCircuitCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeVirtualCircuitCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/virtualCircuits/{virtualCircuitId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeVirtualCircuitCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeVlanCompartment Moves a VLAN into a different compartment within the same tenancy. +// For information about moving resources between compartments, see +// Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ChangeVlanCompartment.go.html to see an example of how to use ChangeVlanCompartment API. +func (client VirtualNetworkClient) ChangeVlanCompartment(ctx context.Context, request ChangeVlanCompartmentRequest) (response ChangeVlanCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeVlanCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeVlanCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeVlanCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeVlanCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeVlanCompartmentResponse") + } + return +} + +// changeVlanCompartment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) changeVlanCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/vlans/{vlanId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeVlanCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ConnectLocalPeeringGateways Connects this local peering gateway (LPG) to another one in the same 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 LPGs in the acceptor's compartment. Without that permission, this +// operation will fail. For more information, see +// VCN Peering (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/VCNpeering.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ConnectLocalPeeringGateways.go.html to see an example of how to use ConnectLocalPeeringGateways API. +func (client VirtualNetworkClient) ConnectLocalPeeringGateways(ctx context.Context, request ConnectLocalPeeringGatewaysRequest) (response ConnectLocalPeeringGatewaysResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.connectLocalPeeringGateways, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ConnectLocalPeeringGatewaysResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ConnectLocalPeeringGatewaysResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ConnectLocalPeeringGatewaysResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ConnectLocalPeeringGatewaysResponse") + } + return +} + +// connectLocalPeeringGateways implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) connectLocalPeeringGateways(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/localPeeringGateways/{localPeeringGatewayId}/actions/connect", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ConnectLocalPeeringGatewaysResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// 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.cloud.oracle.com/iaas/Content/Network/Tasks/VCNpeering.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ConnectRemotePeeringConnections.go.html to see an example of how to use ConnectRemotePeeringConnections API. +func (client VirtualNetworkClient) ConnectRemotePeeringConnections(ctx context.Context, request ConnectRemotePeeringConnectionsRequest) (response ConnectRemotePeeringConnectionsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.connectRemotePeeringConnections, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ConnectRemotePeeringConnectionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ConnectRemotePeeringConnectionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ConnectRemotePeeringConnectionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ConnectRemotePeeringConnectionsResponse") + } + return +} + +// connectRemotePeeringConnections implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) connectRemotePeeringConnections(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/remotePeeringConnections/{remotePeeringConnectionId}/actions/connect", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ConnectRemotePeeringConnectionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateByoipRange Creates a subrange of the BYOIP CIDR block. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateByoipRange.go.html to see an example of how to use CreateByoipRange API. +func (client VirtualNetworkClient) CreateByoipRange(ctx context.Context, request CreateByoipRangeRequest) (response CreateByoipRangeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createByoipRange, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateByoipRangeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateByoipRangeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateByoipRangeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateByoipRangeResponse") + } + return +} + +// createByoipRange implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createByoipRange(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/byoipRanges", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateByoipRangeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateCpe Creates a new virtual customer-premises equipment (CPE) object in the specified compartment. For +// more information, see Site-to-Site VPN Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/overviewIPsec.htm). +// For the purposes of access control, you must provide the OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the compartment where you want +// the CPE to reside. Notice that the CPE doesn't have to be in the same compartment as the IPSec +// connection or other Networking Service components. If you're not sure which compartment to +// use, put the CPE in the same compartment as the DRG. For more information about +// compartments and access control, see Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). +// For information about OCIDs, see Resource Identifiers (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// You must provide the public IP address of your on-premises router. See +// CPE Configuration (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/configuringCPE.htm). +// You may optionally specify a *display name* for the CPE, otherwise a default is provided. It does not have to +// be unique, and you can change it. Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateCpe.go.html to see an example of how to use CreateCpe API. +func (client VirtualNetworkClient) CreateCpe(ctx context.Context, request CreateCpeRequest) (response CreateCpeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createCpe, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateCpeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateCpeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateCpeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateCpeResponse") + } + return +} + +// createCpe implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createCpe(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/cpes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateCpeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateCrossConnect Creates a new cross-connect. Oracle recommends you create each cross-connect in a +// CrossConnectGroup so you can use link aggregation +// with the connection. +// After creating the `CrossConnect` object, you need to go the FastConnect location +// and request to have the physical cable installed. For more information, see +// FastConnect Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/fastconnect.htm). +// For the purposes of access control, you must provide the OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the +// compartment where you want the cross-connect to reside. If you're +// not sure which compartment to use, put the cross-connect in the +// same compartment with your VCN. For more information about +// compartments and access control, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). +// For information about OCIDs, see +// Resource Identifiers (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// You may optionally specify a *display name* for the cross-connect. +// It does not have to be unique, and you can change it. Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateCrossConnect.go.html to see an example of how to use CreateCrossConnect API. +func (client VirtualNetworkClient) CreateCrossConnect(ctx context.Context, request CreateCrossConnectRequest) (response CreateCrossConnectResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createCrossConnect, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateCrossConnectResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateCrossConnectResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateCrossConnectResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateCrossConnectResponse") + } + return +} + +// createCrossConnect implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createCrossConnect(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/crossConnects", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateCrossConnectResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateCrossConnectGroup Creates a new cross-connect group to use with Oracle Cloud Infrastructure +// FastConnect. For more information, see +// FastConnect Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/fastconnect.htm). +// For the purposes of access control, you must provide the OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the +// compartment where you want the cross-connect group to reside. If you're +// not sure which compartment to use, put the cross-connect group in the +// same compartment with your VCN. For more information about +// compartments and access control, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). +// For information about OCIDs, see +// Resource Identifiers (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// You may optionally specify a *display name* for the cross-connect group. +// It does not have to be unique, and you can change it. Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateCrossConnectGroup.go.html to see an example of how to use CreateCrossConnectGroup API. +func (client VirtualNetworkClient) CreateCrossConnectGroup(ctx context.Context, request CreateCrossConnectGroupRequest) (response CreateCrossConnectGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createCrossConnectGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateCrossConnectGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateCrossConnectGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateCrossConnectGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateCrossConnectGroupResponse") + } + return +} + +// createCrossConnectGroup implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createCrossConnectGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/crossConnectGroups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateCrossConnectGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateDhcpOptions Creates a new set of DHCP options for the specified VCN. For more information, see +// DhcpOptions. +// For the purposes of access control, you must provide the OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the compartment where you want the set of +// DHCP options to reside. Notice that the set of options doesn't have to be in the same compartment as the VCN, +// subnets, or other Networking Service components. If you're not sure which compartment to use, put the set +// of DHCP options in the same compartment as the VCN. For more information about compartments and access control, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). For information about OCIDs, see +// Resource Identifiers (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// You may optionally specify a *display name* for the set of DHCP options, otherwise a default is provided. +// It does not have to be unique, and you can change it. Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateDhcpOptions.go.html to see an example of how to use CreateDhcpOptions API. +func (client VirtualNetworkClient) CreateDhcpOptions(ctx context.Context, request CreateDhcpOptionsRequest) (response CreateDhcpOptionsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createDhcpOptions, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateDhcpOptionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateDhcpOptionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateDhcpOptionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateDhcpOptionsResponse") + } + return +} + +// createDhcpOptions implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createDhcpOptions(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/dhcps", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateDhcpOptionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateDrg Creates a new dynamic routing gateway (DRG) in the specified compartment. For more information, +// see Dynamic Routing Gateways (DRGs) (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingDRGs.htm). +// For the purposes of access control, you must provide the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment where you want +// the DRG to reside. Notice that the DRG doesn't have to be in the same compartment as the VCN, +// the DRG attachment, or other Networking Service components. If you're not sure which compartment +// to use, put the DRG in the same compartment as the VCN. For more information about compartments +// and access control, see Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). +// For information about OCIDs, see Resource Identifiers (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// You may optionally specify a *display name* for the DRG, otherwise a default is provided. +// It does not have to be unique, and you can change it. Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateDrg.go.html to see an example of how to use CreateDrg API. +func (client VirtualNetworkClient) CreateDrg(ctx context.Context, request CreateDrgRequest) (response CreateDrgResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createDrg, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateDrgResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateDrgResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateDrgResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateDrgResponse") + } + return +} + +// createDrg implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createDrg(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/drgs", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateDrgResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateDrgAttachment Attaches the specified DRG to the specified network resource. A VCN can be attached to only one DRG +// at a time, but a DRG can be attached to more than one VCN. The response includes a `DrgAttachment` +// object with its own OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm). For more information about DRGs, see +// Dynamic Routing Gateways (DRGs) (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingDRGs.htm). +// You may optionally specify a *display name* for the attachment, otherwise a default is provided. +// It does not have to be unique, and you can change it. Avoid entering confidential information. +// For the purposes of access control, the DRG attachment is automatically placed into the currently selected compartment. +// For more information about compartments and access control, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateDrgAttachment.go.html to see an example of how to use CreateDrgAttachment API. +func (client VirtualNetworkClient) CreateDrgAttachment(ctx context.Context, request CreateDrgAttachmentRequest) (response CreateDrgAttachmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createDrgAttachment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateDrgAttachmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateDrgAttachmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateDrgAttachmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateDrgAttachmentResponse") + } + return +} + +// createDrgAttachment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createDrgAttachment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/drgAttachments", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateDrgAttachmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateDrgRouteDistribution Creates a new route distribution for the specified DRG. +// Assign the route distribution as an import distribution to a DRG route table using the `UpdateDrgRouteTable` or `CreateDrgRouteTable` operations. +// Assign the route distribution as an export distribution to a DRG attachment +// using the `UpdateDrgAttachment` or `CreateDrgAttachment` operations. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateDrgRouteDistribution.go.html to see an example of how to use CreateDrgRouteDistribution API. +func (client VirtualNetworkClient) CreateDrgRouteDistribution(ctx context.Context, request CreateDrgRouteDistributionRequest) (response CreateDrgRouteDistributionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createDrgRouteDistribution, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateDrgRouteDistributionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateDrgRouteDistributionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateDrgRouteDistributionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateDrgRouteDistributionResponse") + } + return +} + +// createDrgRouteDistribution implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createDrgRouteDistribution(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/drgRouteDistributions", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateDrgRouteDistributionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateDrgRouteTable Creates a new DRG route table for the specified DRG. Assign the DRG route table to a DRG attachment +// using the `UpdateDrgAttachment` or `CreateDrgAttachment` operations. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateDrgRouteTable.go.html to see an example of how to use CreateDrgRouteTable API. +func (client VirtualNetworkClient) CreateDrgRouteTable(ctx context.Context, request CreateDrgRouteTableRequest) (response CreateDrgRouteTableResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createDrgRouteTable, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateDrgRouteTableResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateDrgRouteTableResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateDrgRouteTableResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateDrgRouteTableResponse") + } + return +} + +// createDrgRouteTable implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createDrgRouteTable(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/drgRouteTables", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateDrgRouteTableResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateIPSecConnection Creates a new IPSec connection between the specified DRG and CPE. For more information, see +// Site-to-Site VPN Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/overviewIPsec.htm). +// If you configure at least one tunnel to use static routing, then in the request you must provide +// at least one valid static route (you're allowed a maximum of 10). For example: 10.0.0.0/16. +// If you configure both tunnels to use BGP dynamic routing, you can provide an empty list for +// the static routes. For more information, see the important note in +// IPSecConnection. +// For the purposes of access control, you must provide the OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the compartment where you want the +// IPSec connection to reside. Notice that the IPSec connection doesn't have to be in the same compartment +// as the DRG, CPE, or other Networking Service components. If you're not sure which compartment to +// use, put the IPSec connection in the same compartment as the DRG. For more information about +// compartments and access control, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). +// You may optionally specify a *display name* for the IPSec connection, otherwise a default is provided. +// It does not have to be unique, and you can change it. Avoid entering confidential information. +// After creating the IPSec connection, you need to configure your on-premises router +// with tunnel-specific information. For tunnel status and the required configuration information, see: +// * IPSecConnectionTunnel +// * IPSecConnectionTunnelSharedSecret +// For each tunnel, you need the IP address of Oracle's VPN headend and the shared secret +// (that is, the pre-shared key). For more information, see +// CPE Configuration (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/configuringCPE.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateIPSecConnection.go.html to see an example of how to use CreateIPSecConnection API. +func (client VirtualNetworkClient) CreateIPSecConnection(ctx context.Context, request CreateIPSecConnectionRequest) (response CreateIPSecConnectionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createIPSecConnection, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateIPSecConnectionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateIPSecConnectionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateIPSecConnectionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateIPSecConnectionResponse") + } + return +} + +// createIPSecConnection implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createIPSecConnection(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/ipsecConnections", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateIPSecConnectionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateInternetGateway Creates a new internet gateway for the specified VCN. For more information, see +// Access to the Internet (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingIGs.htm). +// For the purposes of access control, you must provide the OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the compartment where you want the Internet +// Gateway to reside. Notice that the internet gateway doesn't have to be in the same compartment as the VCN or +// other Networking Service components. If you're not sure which compartment to use, put the Internet +// Gateway in the same compartment with the VCN. For more information about compartments and access control, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). +// You may optionally specify a *display name* for the internet gateway, otherwise a default is provided. It +// does not have to be unique, and you can change it. Avoid entering confidential information. +// For traffic to flow between a subnet and an internet gateway, you must create a route rule accordingly in +// the subnet's route table (for example, 0.0.0.0/0 > internet gateway). See +// UpdateRouteTable. +// You must specify whether the internet gateway is enabled when you create it. If it's disabled, that means no +// traffic will flow to/from the internet even if there's a route rule that enables that traffic. You can later +// use UpdateInternetGateway to easily disable/enable +// the gateway without changing the route rule. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateInternetGateway.go.html to see an example of how to use CreateInternetGateway API. +func (client VirtualNetworkClient) CreateInternetGateway(ctx context.Context, request CreateInternetGatewayRequest) (response CreateInternetGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createInternetGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateInternetGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateInternetGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateInternetGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateInternetGatewayResponse") + } + return +} + +// createInternetGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createInternetGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/internetGateways", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateInternetGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateIpv6 Creates an IPv6 for the specified VNIC. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateIpv6.go.html to see an example of how to use CreateIpv6 API. +func (client VirtualNetworkClient) CreateIpv6(ctx context.Context, request CreateIpv6Request) (response CreateIpv6Response, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createIpv6, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateIpv6Response{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateIpv6Response{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateIpv6Response); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateIpv6Response") + } + return +} + +// createIpv6 implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createIpv6(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/ipv6", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateIpv6Response + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateLocalPeeringGateway Creates a new local peering gateway (LPG) for the specified VCN. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateLocalPeeringGateway.go.html to see an example of how to use CreateLocalPeeringGateway API. +func (client VirtualNetworkClient) CreateLocalPeeringGateway(ctx context.Context, request CreateLocalPeeringGatewayRequest) (response CreateLocalPeeringGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createLocalPeeringGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateLocalPeeringGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateLocalPeeringGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateLocalPeeringGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateLocalPeeringGatewayResponse") + } + return +} + +// createLocalPeeringGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createLocalPeeringGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/localPeeringGateways", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateLocalPeeringGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateNatGateway Creates a new NAT gateway for the specified VCN. You must also set up a route rule with the +// NAT gateway as the rule's target. See RouteTable. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateNatGateway.go.html to see an example of how to use CreateNatGateway API. +func (client VirtualNetworkClient) CreateNatGateway(ctx context.Context, request CreateNatGatewayRequest) (response CreateNatGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createNatGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateNatGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateNatGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateNatGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateNatGatewayResponse") + } + return +} + +// createNatGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createNatGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/natGateways", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateNatGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateNetworkSecurityGroup Creates a new network security group for the specified VCN. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateNetworkSecurityGroup.go.html to see an example of how to use CreateNetworkSecurityGroup API. +func (client VirtualNetworkClient) CreateNetworkSecurityGroup(ctx context.Context, request CreateNetworkSecurityGroupRequest) (response CreateNetworkSecurityGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createNetworkSecurityGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateNetworkSecurityGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateNetworkSecurityGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateNetworkSecurityGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateNetworkSecurityGroupResponse") + } + return +} + +// createNetworkSecurityGroup implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createNetworkSecurityGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/networkSecurityGroups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateNetworkSecurityGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreatePrivateIp Creates a secondary private IP for the specified VNIC. +// For more information about secondary private IPs, see +// IP Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingIPaddresses.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreatePrivateIp.go.html to see an example of how to use CreatePrivateIp API. +func (client VirtualNetworkClient) CreatePrivateIp(ctx context.Context, request CreatePrivateIpRequest) (response CreatePrivateIpResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createPrivateIp, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreatePrivateIpResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreatePrivateIpResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreatePrivateIpResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreatePrivateIpResponse") + } + return +} + +// createPrivateIp implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createPrivateIp(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/privateIps", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreatePrivateIpResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreatePublicIp Creates a public IP. Use the `lifetime` property to specify whether it's an ephemeral or +// reserved public IP. For information about limits on how many you can create, see +// Public IP Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingpublicIPs.htm). +// * **For an ephemeral public IP assigned to a private IP:** You must also specify a `privateIpId` +// with the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the primary private IP you want to assign the public IP to. The public IP is +// created in the same availability domain as the private IP. An ephemeral public IP must always be +// assigned to a private IP, and only to the *primary* private IP on a VNIC, not a secondary +// private IP. Exception: If you create a NatGateway, Oracle +// automatically assigns the NAT gateway a regional ephemeral public IP that you cannot remove. +// * **For a reserved public IP:** You may also optionally assign the public IP to a private +// IP by specifying `privateIpId`. Or you can later assign the public IP with +// UpdatePublicIp. +// **Note:** When assigning a public IP to a private IP, the private IP must not already have +// a public IP with `lifecycleState` = ASSIGNING or ASSIGNED. If it does, an error is returned. +// Also, for reserved public IPs, the optional assignment part of this operation is +// asynchronous. Poll the public IP's `lifecycleState` to determine if the assignment +// succeeded. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreatePublicIp.go.html to see an example of how to use CreatePublicIp API. +func (client VirtualNetworkClient) CreatePublicIp(ctx context.Context, request CreatePublicIpRequest) (response CreatePublicIpResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createPublicIp, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreatePublicIpResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreatePublicIpResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreatePublicIpResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreatePublicIpResponse") + } + return +} + +// createPublicIp implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createPublicIp(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/publicIps", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreatePublicIpResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreatePublicIpPool Creates a public IP pool. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreatePublicIpPool.go.html to see an example of how to use CreatePublicIpPool API. +func (client VirtualNetworkClient) CreatePublicIpPool(ctx context.Context, request CreatePublicIpPoolRequest) (response CreatePublicIpPoolResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createPublicIpPool, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreatePublicIpPoolResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreatePublicIpPoolResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreatePublicIpPoolResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreatePublicIpPoolResponse") + } + return +} + +// createPublicIpPool implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createPublicIpPool(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/publicIpPools", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreatePublicIpPoolResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateRemotePeeringConnection Creates a new remote peering connection (RPC) for the specified DRG. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateRemotePeeringConnection.go.html to see an example of how to use CreateRemotePeeringConnection API. +func (client VirtualNetworkClient) CreateRemotePeeringConnection(ctx context.Context, request CreateRemotePeeringConnectionRequest) (response CreateRemotePeeringConnectionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createRemotePeeringConnection, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateRemotePeeringConnectionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateRemotePeeringConnectionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateRemotePeeringConnectionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateRemotePeeringConnectionResponse") + } + return +} + +// createRemotePeeringConnection implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createRemotePeeringConnection(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/remotePeeringConnections", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateRemotePeeringConnectionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateRouteTable Creates a new route table for the specified VCN. In the request you must also include at least one route +// rule for the new route table. For information on the number of rules you can have in a route table, see +// Service Limits (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/servicelimits.htm). For general information about route +// tables in your VCN and the types of targets you can use in route rules, +// see Route Tables (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingroutetables.htm). +// For the purposes of access control, you must provide the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment where you want the route +// table to reside. Notice that the route table doesn't have to be in the same compartment as the VCN, subnets, +// or other Networking Service components. If you're not sure which compartment to use, put the route +// table in the same compartment as the VCN. For more information about compartments and access control, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). For information about OCIDs, see +// Resource Identifiers (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// You may optionally specify a *display name* for the route table, otherwise a default is provided. +// It does not have to be unique, and you can change it. Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateRouteTable.go.html to see an example of how to use CreateRouteTable API. +func (client VirtualNetworkClient) CreateRouteTable(ctx context.Context, request CreateRouteTableRequest) (response CreateRouteTableResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createRouteTable, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateRouteTableResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateRouteTableResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateRouteTableResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateRouteTableResponse") + } + return +} + +// createRouteTable implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createRouteTable(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/routeTables", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateRouteTableResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateSecurityList Creates a new security list for the specified VCN. For more information +// about security lists, see Security Lists (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/securitylists.htm). +// For information on the number of rules you can have in a security list, see +// Service Limits (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/servicelimits.htm). +// For the purposes of access control, you must provide the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment where you want the security +// list to reside. Notice that the security list doesn't have to be in the same compartment as the VCN, subnets, +// or other Networking Service components. If you're not sure which compartment to use, put the security +// list in the same compartment as the VCN. For more information about compartments and access control, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). For information about OCIDs, see +// Resource Identifiers (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// You may optionally specify a *display name* for the security list, otherwise a default is provided. +// It does not have to be unique, and you can change it. Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateSecurityList.go.html to see an example of how to use CreateSecurityList API. +func (client VirtualNetworkClient) CreateSecurityList(ctx context.Context, request CreateSecurityListRequest) (response CreateSecurityListResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createSecurityList, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateSecurityListResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateSecurityListResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateSecurityListResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateSecurityListResponse") + } + return +} + +// createSecurityList implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createSecurityList(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/securityLists", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateSecurityListResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateServiceGateway Creates a new service gateway in the specified compartment. +// For the purposes of access control, you must provide the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment where you want +// the service gateway to reside. For more information about compartments and access control, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). +// For information about OCIDs, see Resource Identifiers (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// You may optionally specify a *display name* for the service gateway, otherwise a default is provided. +// It does not have to be unique, and you can change it. Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateServiceGateway.go.html to see an example of how to use CreateServiceGateway API. +func (client VirtualNetworkClient) CreateServiceGateway(ctx context.Context, request CreateServiceGatewayRequest) (response CreateServiceGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createServiceGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateServiceGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateServiceGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateServiceGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateServiceGatewayResponse") + } + return +} + +// createServiceGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createServiceGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/serviceGateways", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateServiceGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateSubnet Creates a new subnet in the specified VCN. You can't change the size of the subnet after creation, +// so it's important to think about the size of subnets you need before creating them. +// For more information, see VCNs and Subnets (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingVCNs.htm). +// For information on the number of subnets you can have in a VCN, see +// Service Limits (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/servicelimits.htm). +// For the purposes of access control, you must provide the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment where you want the subnet +// to reside. Notice that the subnet doesn't have to be in the same compartment as the VCN, route tables, or +// other Networking Service components. If you're not sure which compartment to use, put the subnet in +// the same compartment as the VCN. For more information about compartments and access control, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). For information about OCIDs, +// see Resource Identifiers (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// You may optionally associate a route table with the subnet. If you don't, the subnet will use the +// VCN's default route table. For more information about route tables, see +// Route Tables (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingroutetables.htm). +// You may optionally associate a security list with the subnet. If you don't, the subnet will use the +// VCN's default security list. For more information about security lists, see +// Security Lists (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/securitylists.htm). +// You may optionally associate a set of DHCP options with the subnet. If you don't, the subnet will use the +// VCN's default set. For more information about DHCP options, see +// DHCP Options (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingDHCP.htm). +// You may optionally specify a *display name* for the subnet, otherwise a default is provided. +// It does not have to be unique, and you can change it. Avoid entering confidential information. +// You can also add a DNS label for the subnet, which is required if you want the Internet and +// VCN Resolver to resolve hostnames for instances in the subnet. For more information, see +// DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateSubnet.go.html to see an example of how to use CreateSubnet API. +func (client VirtualNetworkClient) CreateSubnet(ctx context.Context, request CreateSubnetRequest) (response CreateSubnetResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createSubnet, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateSubnetResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateSubnetResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateSubnetResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateSubnetResponse") + } + return +} + +// createSubnet implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createSubnet(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/subnets", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateSubnetResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateVcn Creates a new virtual cloud network (VCN). For more information, see +// VCNs and Subnets (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingVCNs.htm). +// For the VCN, you specify a list of one or more IPv4 CIDR blocks that meet the following criteria: +// - The CIDR blocks must be valid. +// - They must not overlap with each other or with the on-premises network CIDR block. +// - The number of CIDR blocks does not exceed the limit of CIDR blocks allowed per VCN. +// For a CIDR block, Oracle recommends that you use one of the private IP address ranges specified in RFC 1918 (https://tools.ietf.org/html/rfc1918) (10.0.0.0/8, 172.16/12, and 192.168/16). Example: +// 172.16.0.0/16. The CIDR blocks can range from /16 to /30. +// For the purposes of access control, you must provide the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment where you want the VCN to +// reside. Consult an Oracle Cloud Infrastructure administrator in your organization if you're not sure which +// compartment to use. Notice that the VCN doesn't have to be in the same compartment as the subnets or other +// Networking Service components. For more information about compartments and access control, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). For information about OCIDs, see +// Resource Identifiers (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// You may optionally specify a *display name* for the VCN, otherwise a default is provided. It does not have to +// be unique, and you can change it. Avoid entering confidential information. +// You can also add a DNS label for the VCN, which is required if you want the instances to use the +// Interent and VCN Resolver option for DNS in the VCN. For more information, see +// DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). +// The VCN automatically comes with a default route table, default security list, and default set of DHCP options. +// The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) for each is returned in the response. You can't delete these default objects, but you can change their +// contents (that is, change the route rules, security list rules, and so on). +// The VCN and subnets you create are not accessible until you attach an internet gateway or set up a Site-to-Site VPN +// or FastConnect. For more information, see +// Overview of the Networking Service (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVcn.go.html to see an example of how to use CreateVcn API. +func (client VirtualNetworkClient) CreateVcn(ctx context.Context, request CreateVcnRequest) (response CreateVcnResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createVcn, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateVcnResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateVcnResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateVcnResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateVcnResponse") + } + return +} + +// createVcn implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createVcn(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/vcns", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateVcnResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateVirtualCircuit Creates a new virtual circuit to use with Oracle Cloud +// Infrastructure FastConnect. For more information, see +// FastConnect Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/fastconnect.htm). +// For the purposes of access control, you must provide the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the +// compartment where you want the virtual circuit to reside. If you're +// not sure which compartment to use, put the virtual circuit in the +// same compartment with the DRG it's using. For more information about +// compartments and access control, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/overview.htm). +// For information about OCIDs, see +// Resource Identifiers (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// You may optionally specify a *display name* for the virtual circuit. +// It does not have to be unique, and you can change it. Avoid entering confidential information. +// **Important:** When creating a virtual circuit, you specify a DRG for +// the traffic to flow through. Make sure you attach the DRG to your +// VCN and confirm the VCN's routing sends traffic to the DRG. Otherwise +// traffic will not flow. For more information, see +// Route Tables (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingroutetables.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVirtualCircuit.go.html to see an example of how to use CreateVirtualCircuit API. +func (client VirtualNetworkClient) CreateVirtualCircuit(ctx context.Context, request CreateVirtualCircuitRequest) (response CreateVirtualCircuitResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createVirtualCircuit, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateVirtualCircuitResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateVirtualCircuitResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateVirtualCircuitResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateVirtualCircuitResponse") + } + return +} + +// createVirtualCircuit implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createVirtualCircuit(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/virtualCircuits", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateVirtualCircuitResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateVlan Creates a VLAN in the specified VCN and the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVlan.go.html to see an example of how to use CreateVlan API. +func (client VirtualNetworkClient) CreateVlan(ctx context.Context, request CreateVlanRequest) (response CreateVlanResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createVlan, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateVlanResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateVlanResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateVlanResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateVlanResponse") + } + return +} + +// createVlan implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) createVlan(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/vlans", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateVlanResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteByoipRange Deletes the specified `ByoipRange` resource. +// The resource must be in one of the following states: CREATING, PROVISIONED, ACTIVE, or FAILED. +// It must not have any subranges currently allocated to a PublicIpPool object or the deletion will fail. +// You must specify the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// If the `ByoipRange` resource is currently in the PROVISIONED or ACTIVE state, it will be de-provisioned and then deleted. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteByoipRange.go.html to see an example of how to use DeleteByoipRange API. +func (client VirtualNetworkClient) DeleteByoipRange(ctx context.Context, request DeleteByoipRangeRequest) (response DeleteByoipRangeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteByoipRange, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteByoipRangeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteByoipRangeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteByoipRangeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteByoipRangeResponse") + } + return +} + +// deleteByoipRange implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteByoipRange(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/byoipRanges/{byoipRangeId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteByoipRangeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteCpe Deletes the specified CPE object. The CPE must not be connected to a DRG. This is an asynchronous +// operation. The CPE's `lifecycleState` will change to TERMINATING temporarily until the CPE is completely +// removed. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteCpe.go.html to see an example of how to use DeleteCpe API. +func (client VirtualNetworkClient) DeleteCpe(ctx context.Context, request DeleteCpeRequest) (response DeleteCpeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteCpe, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteCpeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteCpeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteCpeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteCpeResponse") + } + return +} + +// deleteCpe implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteCpe(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/cpes/{cpeId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteCpeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteCrossConnect Deletes the specified cross-connect. It must not be mapped to a +// VirtualCircuit. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteCrossConnect.go.html to see an example of how to use DeleteCrossConnect API. +func (client VirtualNetworkClient) DeleteCrossConnect(ctx context.Context, request DeleteCrossConnectRequest) (response DeleteCrossConnectResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteCrossConnect, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteCrossConnectResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteCrossConnectResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteCrossConnectResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteCrossConnectResponse") + } + return +} + +// deleteCrossConnect implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteCrossConnect(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/crossConnects/{crossConnectId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteCrossConnectResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteCrossConnectGroup Deletes the specified cross-connect group. It must not contain any +// cross-connects, and it cannot be mapped to a +// VirtualCircuit. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteCrossConnectGroup.go.html to see an example of how to use DeleteCrossConnectGroup API. +func (client VirtualNetworkClient) DeleteCrossConnectGroup(ctx context.Context, request DeleteCrossConnectGroupRequest) (response DeleteCrossConnectGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteCrossConnectGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteCrossConnectGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteCrossConnectGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteCrossConnectGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteCrossConnectGroupResponse") + } + return +} + +// deleteCrossConnectGroup implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteCrossConnectGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/crossConnectGroups/{crossConnectGroupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteCrossConnectGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteDhcpOptions Deletes the specified set of DHCP options, but only if it's not associated with a subnet. You can't delete a +// VCN's default set of DHCP options. +// This is an asynchronous operation. The state of the set of options will switch to TERMINATING temporarily +// until the set is completely removed. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteDhcpOptions.go.html to see an example of how to use DeleteDhcpOptions API. +func (client VirtualNetworkClient) DeleteDhcpOptions(ctx context.Context, request DeleteDhcpOptionsRequest) (response DeleteDhcpOptionsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteDhcpOptions, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteDhcpOptionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteDhcpOptionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteDhcpOptionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteDhcpOptionsResponse") + } + return +} + +// deleteDhcpOptions implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteDhcpOptions(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/dhcps/{dhcpId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteDhcpOptionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteDrg Deletes the specified DRG. The DRG must not be attached to a VCN or be connected to your on-premise +// network. Also, there must not be a route table that lists the DRG as a target. This is an asynchronous +// operation. The DRG's `lifecycleState` will change to TERMINATING temporarily until the DRG is completely +// removed. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteDrg.go.html to see an example of how to use DeleteDrg API. +func (client VirtualNetworkClient) DeleteDrg(ctx context.Context, request DeleteDrgRequest) (response DeleteDrgResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteDrg, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteDrgResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteDrgResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteDrgResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteDrgResponse") + } + return +} + +// deleteDrg implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteDrg(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/drgs/{drgId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteDrgResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteDrgAttachment Detaches a DRG from a network resource by deleting the corresponding `DrgAttachment` resource. This is an asynchronous +// operation. The attachment's `lifecycleState` will temporarily change to DETACHING until the attachment +// is completely removed. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteDrgAttachment.go.html to see an example of how to use DeleteDrgAttachment API. +func (client VirtualNetworkClient) DeleteDrgAttachment(ctx context.Context, request DeleteDrgAttachmentRequest) (response DeleteDrgAttachmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteDrgAttachment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteDrgAttachmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteDrgAttachmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteDrgAttachmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteDrgAttachmentResponse") + } + return +} + +// deleteDrgAttachment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteDrgAttachment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/drgAttachments/{drgAttachmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteDrgAttachmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteDrgRouteDistribution Deletes the specified route distribution. You can't delete a route distribution currently in use by a DRG attachment or DRG route table. +// Remove the DRG route distribution from a DRG attachment or DRG route table by using the "RemoveExportDrgRouteDistribution" or "RemoveImportDrgRouteDistribution' operations. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteDrgRouteDistribution.go.html to see an example of how to use DeleteDrgRouteDistribution API. +func (client VirtualNetworkClient) DeleteDrgRouteDistribution(ctx context.Context, request DeleteDrgRouteDistributionRequest) (response DeleteDrgRouteDistributionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteDrgRouteDistribution, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteDrgRouteDistributionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteDrgRouteDistributionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteDrgRouteDistributionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteDrgRouteDistributionResponse") + } + return +} + +// deleteDrgRouteDistribution implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteDrgRouteDistribution(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/drgRouteDistributions/{drgRouteDistributionId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteDrgRouteDistributionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteDrgRouteTable Deletes the specified DRG route table. There must not be any DRG attachments assigned. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteDrgRouteTable.go.html to see an example of how to use DeleteDrgRouteTable API. +func (client VirtualNetworkClient) DeleteDrgRouteTable(ctx context.Context, request DeleteDrgRouteTableRequest) (response DeleteDrgRouteTableResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteDrgRouteTable, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteDrgRouteTableResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteDrgRouteTableResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteDrgRouteTableResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteDrgRouteTableResponse") + } + return +} + +// deleteDrgRouteTable implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteDrgRouteTable(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/drgRouteTables/{drgRouteTableId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteDrgRouteTableResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteIPSecConnection Deletes the specified IPSec connection. If your goal is to disable the Site-to-Site VPN between your VCN and +// on-premises network, it's easiest to simply detach the DRG but keep all the Site-to-Site VPN components intact. +// If you were to delete all the components and then later need to create an Site-to-Site VPN again, you would +// need to configure your on-premises router again with the new information returned from +// CreateIPSecConnection. +// This is an asynchronous operation. The connection's `lifecycleState` will change to TERMINATING temporarily +// until the connection is completely removed. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteIPSecConnection.go.html to see an example of how to use DeleteIPSecConnection API. +func (client VirtualNetworkClient) DeleteIPSecConnection(ctx context.Context, request DeleteIPSecConnectionRequest) (response DeleteIPSecConnectionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteIPSecConnection, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteIPSecConnectionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteIPSecConnectionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteIPSecConnectionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteIPSecConnectionResponse") + } + return +} + +// deleteIPSecConnection implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteIPSecConnection(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/ipsecConnections/{ipscId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteIPSecConnectionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteInternetGateway Deletes the specified internet gateway. The internet gateway does not have to be disabled, but +// there must not be a route table that lists it as a target. +// This is an asynchronous operation. The gateway's `lifecycleState` will change to TERMINATING temporarily +// until the gateway is completely removed. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteInternetGateway.go.html to see an example of how to use DeleteInternetGateway API. +func (client VirtualNetworkClient) DeleteInternetGateway(ctx context.Context, request DeleteInternetGatewayRequest) (response DeleteInternetGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteInternetGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteInternetGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteInternetGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteInternetGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteInternetGatewayResponse") + } + return +} + +// deleteInternetGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteInternetGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/internetGateways/{igId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteInternetGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteIpv6 Unassigns and deletes the specified IPv6. You must specify the object's OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm). +// The IPv6 address is returned to the subnet's pool of available addresses. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteIpv6.go.html to see an example of how to use DeleteIpv6 API. +func (client VirtualNetworkClient) DeleteIpv6(ctx context.Context, request DeleteIpv6Request) (response DeleteIpv6Response, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteIpv6, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteIpv6Response{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteIpv6Response{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteIpv6Response); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteIpv6Response") + } + return +} + +// deleteIpv6 implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteIpv6(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/ipv6/{ipv6Id}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteIpv6Response + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteLocalPeeringGateway Deletes the specified local peering gateway (LPG). +// This is an asynchronous operation; the local peering gateway's `lifecycleState` changes to TERMINATING temporarily +// until the local peering gateway is completely removed. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteLocalPeeringGateway.go.html to see an example of how to use DeleteLocalPeeringGateway API. +func (client VirtualNetworkClient) DeleteLocalPeeringGateway(ctx context.Context, request DeleteLocalPeeringGatewayRequest) (response DeleteLocalPeeringGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteLocalPeeringGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteLocalPeeringGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteLocalPeeringGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteLocalPeeringGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteLocalPeeringGatewayResponse") + } + return +} + +// deleteLocalPeeringGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteLocalPeeringGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/localPeeringGateways/{localPeeringGatewayId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteLocalPeeringGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteNatGateway Deletes the specified NAT gateway. The NAT gateway does not have to be disabled, but there +// must not be a route rule that lists the NAT gateway as a target. +// This is an asynchronous operation. The NAT gateway's `lifecycleState` will change to +// TERMINATING temporarily until the NAT gateway is completely removed. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteNatGateway.go.html to see an example of how to use DeleteNatGateway API. +func (client VirtualNetworkClient) DeleteNatGateway(ctx context.Context, request DeleteNatGatewayRequest) (response DeleteNatGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteNatGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteNatGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteNatGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteNatGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteNatGatewayResponse") + } + return +} + +// deleteNatGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteNatGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/natGateways/{natGatewayId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteNatGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteNetworkSecurityGroup Deletes the specified network security group. The group must not contain any VNICs. +// To get a list of the VNICs in a network security group, use +// ListNetworkSecurityGroupVnics. +// Each returned NetworkSecurityGroupVnic object +// contains both the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VNIC and the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VNIC's parent resource (for example, +// the Compute instance that the VNIC is attached to). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteNetworkSecurityGroup.go.html to see an example of how to use DeleteNetworkSecurityGroup API. +func (client VirtualNetworkClient) DeleteNetworkSecurityGroup(ctx context.Context, request DeleteNetworkSecurityGroupRequest) (response DeleteNetworkSecurityGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteNetworkSecurityGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteNetworkSecurityGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteNetworkSecurityGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteNetworkSecurityGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteNetworkSecurityGroupResponse") + } + return +} + +// deleteNetworkSecurityGroup implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteNetworkSecurityGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/networkSecurityGroups/{networkSecurityGroupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteNetworkSecurityGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeletePrivateIp Unassigns and deletes the specified private IP. You must +// specify the object's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). The private IP address is returned to +// the subnet's pool of available addresses. +// This operation cannot be used with primary private IPs, which are +// automatically unassigned and deleted when the VNIC is terminated. +// **Important:** If a secondary private IP is the +// target of a route rule (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingroutetables.htm#privateip), +// unassigning it from the VNIC causes that route rule to blackhole and the traffic +// will be dropped. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeletePrivateIp.go.html to see an example of how to use DeletePrivateIp API. +func (client VirtualNetworkClient) DeletePrivateIp(ctx context.Context, request DeletePrivateIpRequest) (response DeletePrivateIpResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deletePrivateIp, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeletePrivateIpResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeletePrivateIpResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeletePrivateIpResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeletePrivateIpResponse") + } + return +} + +// deletePrivateIp implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deletePrivateIp(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/privateIps/{privateIpId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeletePrivateIpResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeletePublicIp Unassigns and deletes the specified public IP (either ephemeral or reserved). +// You must specify the object's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). The public IP address is returned to the +// Oracle Cloud Infrastructure public IP pool. +// **Note:** You cannot update, unassign, or delete the public IP that Oracle automatically +// assigned to an entity for you (such as a load balancer or NAT gateway). The public IP is +// automatically deleted if the assigned entity is terminated. +// For an assigned reserved public IP, the initial unassignment portion of this operation +// is asynchronous. Poll the public IP's `lifecycleState` to determine +// if the operation succeeded. +// If you want to simply unassign a reserved public IP and return it to your pool +// of reserved public IPs, instead use +// UpdatePublicIp. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeletePublicIp.go.html to see an example of how to use DeletePublicIp API. +func (client VirtualNetworkClient) DeletePublicIp(ctx context.Context, request DeletePublicIpRequest) (response DeletePublicIpResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deletePublicIp, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeletePublicIpResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeletePublicIpResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeletePublicIpResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeletePublicIpResponse") + } + return +} + +// deletePublicIp implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deletePublicIp(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/publicIps/{publicIpId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeletePublicIpResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeletePublicIpPool Deletes the specified public IP pool. +// To delete a public IP pool it must not have any active IP address allocations. +// You must specify the object's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) when deleting an IP pool. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeletePublicIpPool.go.html to see an example of how to use DeletePublicIpPool API. +func (client VirtualNetworkClient) DeletePublicIpPool(ctx context.Context, request DeletePublicIpPoolRequest) (response DeletePublicIpPoolResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deletePublicIpPool, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeletePublicIpPoolResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeletePublicIpPoolResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeletePublicIpPoolResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeletePublicIpPoolResponse") + } + return +} + +// deletePublicIpPool implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deletePublicIpPool(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/publicIpPools/{publicIpPoolId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeletePublicIpPoolResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// 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. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteRemotePeeringConnection.go.html to see an example of how to use DeleteRemotePeeringConnection API. +func (client VirtualNetworkClient) DeleteRemotePeeringConnection(ctx context.Context, request DeleteRemotePeeringConnectionRequest) (response DeleteRemotePeeringConnectionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteRemotePeeringConnection, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteRemotePeeringConnectionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteRemotePeeringConnectionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteRemotePeeringConnectionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteRemotePeeringConnectionResponse") + } + return +} + +// deleteRemotePeeringConnection implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteRemotePeeringConnection(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/remotePeeringConnections/{remotePeeringConnectionId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteRemotePeeringConnectionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteRouteTable Deletes the specified route table, but only if it's not associated with a subnet. You can't delete a +// VCN's default route table. +// This is an asynchronous operation. The route table's `lifecycleState` will change to TERMINATING temporarily +// until the route table is completely removed. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteRouteTable.go.html to see an example of how to use DeleteRouteTable API. +func (client VirtualNetworkClient) DeleteRouteTable(ctx context.Context, request DeleteRouteTableRequest) (response DeleteRouteTableResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteRouteTable, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteRouteTableResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteRouteTableResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteRouteTableResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteRouteTableResponse") + } + return +} + +// deleteRouteTable implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteRouteTable(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/routeTables/{rtId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteRouteTableResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteSecurityList Deletes the specified security list, but only if it's not associated with a subnet. You can't delete +// a VCN's default security list. +// This is an asynchronous operation. The security list's `lifecycleState` will change to TERMINATING temporarily +// until the security list is completely removed. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteSecurityList.go.html to see an example of how to use DeleteSecurityList API. +func (client VirtualNetworkClient) DeleteSecurityList(ctx context.Context, request DeleteSecurityListRequest) (response DeleteSecurityListResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteSecurityList, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteSecurityListResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteSecurityListResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteSecurityListResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteSecurityListResponse") + } + return +} + +// deleteSecurityList implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteSecurityList(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/securityLists/{securityListId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteSecurityListResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteServiceGateway Deletes the specified service gateway. There must not be a route table that lists the service +// gateway as a target. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteServiceGateway.go.html to see an example of how to use DeleteServiceGateway API. +func (client VirtualNetworkClient) DeleteServiceGateway(ctx context.Context, request DeleteServiceGatewayRequest) (response DeleteServiceGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteServiceGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteServiceGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteServiceGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteServiceGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteServiceGatewayResponse") + } + return +} + +// deleteServiceGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteServiceGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/serviceGateways/{serviceGatewayId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteServiceGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteSubnet Deletes the specified subnet, but only if there are no instances in the subnet. This is an asynchronous +// operation. The subnet's `lifecycleState` will change to TERMINATING temporarily. If there are any +// instances in the subnet, the state will instead change back to AVAILABLE. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteSubnet.go.html to see an example of how to use DeleteSubnet API. +func (client VirtualNetworkClient) DeleteSubnet(ctx context.Context, request DeleteSubnetRequest) (response DeleteSubnetResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteSubnet, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteSubnetResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteSubnetResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteSubnetResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteSubnetResponse") + } + return +} + +// deleteSubnet implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteSubnet(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/subnets/{subnetId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteSubnetResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteVcn Deletes the specified VCN. The VCN must be empty and have no attached gateways. This is an asynchronous +// operation. The VCN's `lifecycleState` will change to TERMINATING temporarily until the VCN is completely +// removed. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVcn.go.html to see an example of how to use DeleteVcn API. +func (client VirtualNetworkClient) DeleteVcn(ctx context.Context, request DeleteVcnRequest) (response DeleteVcnResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteVcn, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteVcnResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteVcnResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteVcnResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteVcnResponse") + } + return +} + +// deleteVcn implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteVcn(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/vcns/{vcnId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteVcnResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteVirtualCircuit Deletes the specified virtual circuit. +// **Important:** If you're using FastConnect via a provider, +// make sure to also terminate the connection with +// the provider, or else the provider may continue to bill you. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVirtualCircuit.go.html to see an example of how to use DeleteVirtualCircuit API. +func (client VirtualNetworkClient) DeleteVirtualCircuit(ctx context.Context, request DeleteVirtualCircuitRequest) (response DeleteVirtualCircuitResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteVirtualCircuit, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteVirtualCircuitResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteVirtualCircuitResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteVirtualCircuitResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteVirtualCircuitResponse") + } + return +} + +// deleteVirtualCircuit implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteVirtualCircuit(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/virtualCircuits/{virtualCircuitId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteVirtualCircuitResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteVlan Deletes the specified VLAN, but only if there are no VNICs in the VLAN. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVlan.go.html to see an example of how to use DeleteVlan API. +func (client VirtualNetworkClient) DeleteVlan(ctx context.Context, request DeleteVlanRequest) (response DeleteVlanResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteVlan, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteVlanResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteVlanResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteVlanResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteVlanResponse") + } + return +} + +// deleteVlan implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) deleteVlan(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/vlans/{vlanId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteVlanResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DetachServiceId Removes the specified Service from the list of enabled +// `Service` objects for the specified gateway. You do not need to remove any route +// rules that specify this `Service` object's `cidrBlock` as the destination CIDR. However, consider +// removing the rules if your intent is to permanently disable use of the `Service` through this +// service gateway. +// **Note:** The `DetachServiceId` operation is an easy way to remove an individual `Service` from +// the service gateway. Compare it with +// UpdateServiceGateway, which replaces +// the entire existing list of enabled `Service` objects with the list that you provide in the +// `Update` call. `UpdateServiceGateway` also lets you block all traffic through the service +// gateway without having to remove each of the individual `Service` objects. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DetachServiceId.go.html to see an example of how to use DetachServiceId API. +func (client VirtualNetworkClient) DetachServiceId(ctx context.Context, request DetachServiceIdRequest) (response DetachServiceIdResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.detachServiceId, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DetachServiceIdResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DetachServiceIdResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DetachServiceIdResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DetachServiceIdResponse") + } + return +} + +// detachServiceId implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) detachServiceId(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/serviceGateways/{serviceGatewayId}/actions/detachService", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DetachServiceIdResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetAllDrgAttachments Returns a complete list of DRG attachments that belong to a particular DRG. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetAllDrgAttachments.go.html to see an example of how to use GetAllDrgAttachments API. +func (client VirtualNetworkClient) GetAllDrgAttachments(ctx context.Context, request GetAllDrgAttachmentsRequest) (response GetAllDrgAttachmentsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getAllDrgAttachments, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetAllDrgAttachmentsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetAllDrgAttachmentsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetAllDrgAttachmentsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetAllDrgAttachmentsResponse") + } + return +} + +// getAllDrgAttachments implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getAllDrgAttachments(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/drgs/{drgId}/actions/getAllDrgAttachments", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetAllDrgAttachmentsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetAllowedIkeIPSecParameters The allowed parameters for IKE IPSec +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetAllowedIkeIPSecParameters.go.html to see an example of how to use GetAllowedIkeIPSecParameters API. +func (client VirtualNetworkClient) GetAllowedIkeIPSecParameters(ctx context.Context, request GetAllowedIkeIPSecParametersRequest) (response GetAllowedIkeIPSecParametersResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getAllowedIkeIPSecParameters, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetAllowedIkeIPSecParametersResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetAllowedIkeIPSecParametersResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetAllowedIkeIPSecParametersResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetAllowedIkeIPSecParametersResponse") + } + return +} + +// getAllowedIkeIPSecParameters implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getAllowedIkeIPSecParameters(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipsecAlgorithms", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetAllowedIkeIPSecParametersResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetByoipRange Gets the `ByoipRange` resource. You must specify the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetByoipRange.go.html to see an example of how to use GetByoipRange API. +func (client VirtualNetworkClient) GetByoipRange(ctx context.Context, request GetByoipRangeRequest) (response GetByoipRangeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getByoipRange, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetByoipRangeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetByoipRangeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetByoipRangeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetByoipRangeResponse") + } + return +} + +// getByoipRange implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getByoipRange(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/byoipRanges/{byoipRangeId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetByoipRangeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetCpe Gets the specified CPE's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetCpe.go.html to see an example of how to use GetCpe API. +func (client VirtualNetworkClient) GetCpe(ctx context.Context, request GetCpeRequest) (response GetCpeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getCpe, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetCpeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetCpeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetCpeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetCpeResponse") + } + return +} + +// getCpe implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getCpe(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/cpes/{cpeId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetCpeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetCpeDeviceConfigContent Renders a set of CPE configuration content that can help a network engineer configure the actual +// CPE device (for example, a hardware router) represented by the specified Cpe +// object. +// The rendered content is specific to the type of CPE device (for example, Cisco ASA). Therefore the +// Cpe must have the CPE's device type specified by the `cpeDeviceShapeId` +// attribute. The content optionally includes answers that the customer provides (see +// UpdateTunnelCpeDeviceConfig), +// merged with a template of other information specific to the CPE device type. +// The operation returns configuration information for *all* of the +// IPSecConnection objects that use the specified CPE. +// Here are similar operations: +// * GetIpsecCpeDeviceConfigContent +// returns CPE configuration content for all IPSec tunnels in a single IPSec connection. +// * GetTunnelCpeDeviceConfigContent +// returns CPE configuration content for a specific IPSec tunnel in an IPSec connection. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetCpeDeviceConfigContent.go.html to see an example of how to use GetCpeDeviceConfigContent API. +func (client VirtualNetworkClient) GetCpeDeviceConfigContent(ctx context.Context, request GetCpeDeviceConfigContentRequest) (response GetCpeDeviceConfigContentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getCpeDeviceConfigContent, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetCpeDeviceConfigContentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetCpeDeviceConfigContentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetCpeDeviceConfigContentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetCpeDeviceConfigContentResponse") + } + return +} + +// getCpeDeviceConfigContent implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getCpeDeviceConfigContent(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/cpes/{cpeId}/cpeConfigContent", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetCpeDeviceConfigContentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetCpeDeviceShape Gets the detailed information about the specified CPE device type. This might include a set of questions +// that are specific to the particular CPE device type. The customer must supply answers to those questions +// (see UpdateTunnelCpeDeviceConfig). +// The service merges the answers with a template of other information for the CPE device type. The following +// operations return the merged content: +// * GetCpeDeviceConfigContent +// * GetIpsecCpeDeviceConfigContent +// * GetTunnelCpeDeviceConfigContent +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetCpeDeviceShape.go.html to see an example of how to use GetCpeDeviceShape API. +func (client VirtualNetworkClient) GetCpeDeviceShape(ctx context.Context, request GetCpeDeviceShapeRequest) (response GetCpeDeviceShapeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getCpeDeviceShape, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetCpeDeviceShapeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetCpeDeviceShapeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetCpeDeviceShapeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetCpeDeviceShapeResponse") + } + return +} + +// getCpeDeviceShape implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getCpeDeviceShape(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/cpeDeviceShapes/{cpeDeviceShapeId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetCpeDeviceShapeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetCrossConnect Gets the specified cross-connect's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetCrossConnect.go.html to see an example of how to use GetCrossConnect API. +func (client VirtualNetworkClient) GetCrossConnect(ctx context.Context, request GetCrossConnectRequest) (response GetCrossConnectResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getCrossConnect, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetCrossConnectResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetCrossConnectResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetCrossConnectResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetCrossConnectResponse") + } + return +} + +// getCrossConnect implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getCrossConnect(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/crossConnects/{crossConnectId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetCrossConnectResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetCrossConnectGroup Gets the specified cross-connect group's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetCrossConnectGroup.go.html to see an example of how to use GetCrossConnectGroup API. +func (client VirtualNetworkClient) GetCrossConnectGroup(ctx context.Context, request GetCrossConnectGroupRequest) (response GetCrossConnectGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getCrossConnectGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetCrossConnectGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetCrossConnectGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetCrossConnectGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetCrossConnectGroupResponse") + } + return +} + +// getCrossConnectGroup implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getCrossConnectGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/crossConnectGroups/{crossConnectGroupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetCrossConnectGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetCrossConnectLetterOfAuthority Gets the Letter of Authority for the specified cross-connect. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetCrossConnectLetterOfAuthority.go.html to see an example of how to use GetCrossConnectLetterOfAuthority API. +func (client VirtualNetworkClient) GetCrossConnectLetterOfAuthority(ctx context.Context, request GetCrossConnectLetterOfAuthorityRequest) (response GetCrossConnectLetterOfAuthorityResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getCrossConnectLetterOfAuthority, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetCrossConnectLetterOfAuthorityResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetCrossConnectLetterOfAuthorityResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetCrossConnectLetterOfAuthorityResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetCrossConnectLetterOfAuthorityResponse") + } + return +} + +// getCrossConnectLetterOfAuthority implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getCrossConnectLetterOfAuthority(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/crossConnects/{crossConnectId}/letterOfAuthority", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetCrossConnectLetterOfAuthorityResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetCrossConnectStatus Gets the status of the specified cross-connect. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetCrossConnectStatus.go.html to see an example of how to use GetCrossConnectStatus API. +func (client VirtualNetworkClient) GetCrossConnectStatus(ctx context.Context, request GetCrossConnectStatusRequest) (response GetCrossConnectStatusResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getCrossConnectStatus, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetCrossConnectStatusResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetCrossConnectStatusResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetCrossConnectStatusResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetCrossConnectStatusResponse") + } + return +} + +// getCrossConnectStatus implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getCrossConnectStatus(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/crossConnects/{crossConnectId}/status", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetCrossConnectStatusResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetDhcpOptions Gets the specified set of DHCP options. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetDhcpOptions.go.html to see an example of how to use GetDhcpOptions API. +func (client VirtualNetworkClient) GetDhcpOptions(ctx context.Context, request GetDhcpOptionsRequest) (response GetDhcpOptionsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getDhcpOptions, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetDhcpOptionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetDhcpOptionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetDhcpOptionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetDhcpOptionsResponse") + } + return +} + +// getDhcpOptions implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getDhcpOptions(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/dhcps/{dhcpId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetDhcpOptionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetDrg Gets the specified DRG's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetDrg.go.html to see an example of how to use GetDrg API. +func (client VirtualNetworkClient) GetDrg(ctx context.Context, request GetDrgRequest) (response GetDrgResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getDrg, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetDrgResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetDrgResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetDrgResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetDrgResponse") + } + return +} + +// getDrg implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getDrg(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/drgs/{drgId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetDrgResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetDrgAttachment Gets the `DrgAttachment` resource. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetDrgAttachment.go.html to see an example of how to use GetDrgAttachment API. +func (client VirtualNetworkClient) GetDrgAttachment(ctx context.Context, request GetDrgAttachmentRequest) (response GetDrgAttachmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getDrgAttachment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetDrgAttachmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetDrgAttachmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetDrgAttachmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetDrgAttachmentResponse") + } + return +} + +// getDrgAttachment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getDrgAttachment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/drgAttachments/{drgAttachmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetDrgAttachmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetDrgRedundancyStatus Gets the redundancy status for the specified DRG. For more information, see +// Redundancy Remedies (https://docs.cloud.oracle.com/iaas/Content/Network/Troubleshoot/drgredundancy.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetDrgRedundancyStatus.go.html to see an example of how to use GetDrgRedundancyStatus API. +func (client VirtualNetworkClient) GetDrgRedundancyStatus(ctx context.Context, request GetDrgRedundancyStatusRequest) (response GetDrgRedundancyStatusResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getDrgRedundancyStatus, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetDrgRedundancyStatusResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetDrgRedundancyStatusResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetDrgRedundancyStatusResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetDrgRedundancyStatusResponse") + } + return +} + +// getDrgRedundancyStatus implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getDrgRedundancyStatus(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/drgs/{drgId}/redundancyStatus", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetDrgRedundancyStatusResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetDrgRouteDistribution Gets the specified route distribution's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetDrgRouteDistribution.go.html to see an example of how to use GetDrgRouteDistribution API. +func (client VirtualNetworkClient) GetDrgRouteDistribution(ctx context.Context, request GetDrgRouteDistributionRequest) (response GetDrgRouteDistributionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getDrgRouteDistribution, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetDrgRouteDistributionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetDrgRouteDistributionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetDrgRouteDistributionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetDrgRouteDistributionResponse") + } + return +} + +// getDrgRouteDistribution implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getDrgRouteDistribution(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/drgRouteDistributions/{drgRouteDistributionId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetDrgRouteDistributionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetDrgRouteTable Gets the specified DRG route table's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetDrgRouteTable.go.html to see an example of how to use GetDrgRouteTable API. +func (client VirtualNetworkClient) GetDrgRouteTable(ctx context.Context, request GetDrgRouteTableRequest) (response GetDrgRouteTableResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getDrgRouteTable, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetDrgRouteTableResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetDrgRouteTableResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetDrgRouteTableResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetDrgRouteTableResponse") + } + return +} + +// getDrgRouteTable implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getDrgRouteTable(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/drgRouteTables/{drgRouteTableId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetDrgRouteTableResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetFastConnectProviderService Gets the specified provider service. +// For more information, see FastConnect Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/fastconnect.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetFastConnectProviderService.go.html to see an example of how to use GetFastConnectProviderService API. +func (client VirtualNetworkClient) GetFastConnectProviderService(ctx context.Context, request GetFastConnectProviderServiceRequest) (response GetFastConnectProviderServiceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getFastConnectProviderService, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetFastConnectProviderServiceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetFastConnectProviderServiceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetFastConnectProviderServiceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetFastConnectProviderServiceResponse") + } + return +} + +// getFastConnectProviderService implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getFastConnectProviderService(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/fastConnectProviderServices/{providerServiceId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetFastConnectProviderServiceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetFastConnectProviderServiceKey Gets the specified provider service key's information. Use this operation to validate a +// provider service key. An invalid key returns a 404 error. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetFastConnectProviderServiceKey.go.html to see an example of how to use GetFastConnectProviderServiceKey API. +func (client VirtualNetworkClient) GetFastConnectProviderServiceKey(ctx context.Context, request GetFastConnectProviderServiceKeyRequest) (response GetFastConnectProviderServiceKeyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getFastConnectProviderServiceKey, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetFastConnectProviderServiceKeyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetFastConnectProviderServiceKeyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetFastConnectProviderServiceKeyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetFastConnectProviderServiceKeyResponse") + } + return +} + +// getFastConnectProviderServiceKey implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getFastConnectProviderServiceKey(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/fastConnectProviderServices/{providerServiceId}/providerServiceKeys/{providerServiceKeyName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetFastConnectProviderServiceKeyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetIPSecConnection Gets the specified IPSec connection's basic information, including the static routes for the +// on-premises router. If you want the status of the connection (whether it's up or down), use +// GetIPSecConnectionTunnel. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIPSecConnection.go.html to see an example of how to use GetIPSecConnection API. +func (client VirtualNetworkClient) GetIPSecConnection(ctx context.Context, request GetIPSecConnectionRequest) (response GetIPSecConnectionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getIPSecConnection, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetIPSecConnectionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetIPSecConnectionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetIPSecConnectionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetIPSecConnectionResponse") + } + return +} + +// getIPSecConnection implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getIPSecConnection(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipsecConnections/{ipscId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetIPSecConnectionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetIPSecConnectionDeviceConfig Deprecated. To get tunnel information, instead use: +// * GetIPSecConnectionTunnel +// * GetIPSecConnectionTunnelSharedSecret +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIPSecConnectionDeviceConfig.go.html to see an example of how to use GetIPSecConnectionDeviceConfig API. +func (client VirtualNetworkClient) GetIPSecConnectionDeviceConfig(ctx context.Context, request GetIPSecConnectionDeviceConfigRequest) (response GetIPSecConnectionDeviceConfigResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getIPSecConnectionDeviceConfig, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetIPSecConnectionDeviceConfigResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetIPSecConnectionDeviceConfigResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetIPSecConnectionDeviceConfigResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetIPSecConnectionDeviceConfigResponse") + } + return +} + +// getIPSecConnectionDeviceConfig implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getIPSecConnectionDeviceConfig(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipsecConnections/{ipscId}/deviceConfig", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetIPSecConnectionDeviceConfigResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetIPSecConnectionDeviceStatus Deprecated. To get the tunnel status, instead use +// GetIPSecConnectionTunnel. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIPSecConnectionDeviceStatus.go.html to see an example of how to use GetIPSecConnectionDeviceStatus API. +func (client VirtualNetworkClient) GetIPSecConnectionDeviceStatus(ctx context.Context, request GetIPSecConnectionDeviceStatusRequest) (response GetIPSecConnectionDeviceStatusResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getIPSecConnectionDeviceStatus, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetIPSecConnectionDeviceStatusResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetIPSecConnectionDeviceStatusResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetIPSecConnectionDeviceStatusResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetIPSecConnectionDeviceStatusResponse") + } + return +} + +// getIPSecConnectionDeviceStatus implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getIPSecConnectionDeviceStatus(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipsecConnections/{ipscId}/deviceStatus", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetIPSecConnectionDeviceStatusResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetIPSecConnectionTunnel Gets the specified tunnel's information. The resulting object does not include the tunnel's +// shared secret (pre-shared key). To retrieve that, use +// GetIPSecConnectionTunnelSharedSecret. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIPSecConnectionTunnel.go.html to see an example of how to use GetIPSecConnectionTunnel API. +func (client VirtualNetworkClient) GetIPSecConnectionTunnel(ctx context.Context, request GetIPSecConnectionTunnelRequest) (response GetIPSecConnectionTunnelResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getIPSecConnectionTunnel, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetIPSecConnectionTunnelResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetIPSecConnectionTunnelResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetIPSecConnectionTunnelResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetIPSecConnectionTunnelResponse") + } + return +} + +// getIPSecConnectionTunnel implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getIPSecConnectionTunnel(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipsecConnections/{ipscId}/tunnels/{tunnelId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetIPSecConnectionTunnelResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetIPSecConnectionTunnelError Get the identified error for the specified IPSec Tunnel ID. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIPSecConnectionTunnelError.go.html to see an example of how to use GetIPSecConnectionTunnelError API. +func (client VirtualNetworkClient) GetIPSecConnectionTunnelError(ctx context.Context, request GetIPSecConnectionTunnelErrorRequest) (response GetIPSecConnectionTunnelErrorResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getIPSecConnectionTunnelError, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetIPSecConnectionTunnelErrorResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetIPSecConnectionTunnelErrorResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetIPSecConnectionTunnelErrorResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetIPSecConnectionTunnelErrorResponse") + } + return +} + +// getIPSecConnectionTunnelError implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getIPSecConnectionTunnelError(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipsecConnections/{ipscId}/tunnels/{tunnelId}/error", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetIPSecConnectionTunnelErrorResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetIPSecConnectionTunnelSharedSecret Gets the specified tunnel's shared secret (pre-shared key). To get other information +// about the tunnel, use GetIPSecConnectionTunnel. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIPSecConnectionTunnelSharedSecret.go.html to see an example of how to use GetIPSecConnectionTunnelSharedSecret API. +func (client VirtualNetworkClient) GetIPSecConnectionTunnelSharedSecret(ctx context.Context, request GetIPSecConnectionTunnelSharedSecretRequest) (response GetIPSecConnectionTunnelSharedSecretResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getIPSecConnectionTunnelSharedSecret, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetIPSecConnectionTunnelSharedSecretResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetIPSecConnectionTunnelSharedSecretResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetIPSecConnectionTunnelSharedSecretResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetIPSecConnectionTunnelSharedSecretResponse") + } + return +} + +// getIPSecConnectionTunnelSharedSecret implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getIPSecConnectionTunnelSharedSecret(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipsecConnections/{ipscId}/tunnels/{tunnelId}/sharedSecret", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetIPSecConnectionTunnelSharedSecretResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetInternetGateway Gets the specified internet gateway's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetInternetGateway.go.html to see an example of how to use GetInternetGateway API. +func (client VirtualNetworkClient) GetInternetGateway(ctx context.Context, request GetInternetGatewayRequest) (response GetInternetGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getInternetGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetInternetGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetInternetGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetInternetGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetInternetGatewayResponse") + } + return +} + +// getInternetGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getInternetGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/internetGateways/{igId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetInternetGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetIpsecCpeDeviceConfigContent Renders a set of CPE configuration content for the specified IPSec connection (for all the +// tunnels in the connection). The content helps a network engineer configure the actual CPE +// device (for example, a hardware router) that the specified IPSec connection terminates on. +// The rendered content is specific to the type of CPE device (for example, Cisco ASA). Therefore the +// Cpe used by the specified IPSecConnection +// must have the CPE's device type specified by the `cpeDeviceShapeId` attribute. The content +// optionally includes answers that the customer provides (see +// UpdateTunnelCpeDeviceConfig), +// merged with a template of other information specific to the CPE device type. +// The operation returns configuration information for all tunnels in the single specified +// IPSecConnection object. Here are other similar +// operations: +// * GetTunnelCpeDeviceConfigContent +// returns CPE configuration content for a specific tunnel within an IPSec connection. +// * GetCpeDeviceConfigContent +// returns CPE configuration content for *all* IPSec connections that use a specific CPE. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIpsecCpeDeviceConfigContent.go.html to see an example of how to use GetIpsecCpeDeviceConfigContent API. +func (client VirtualNetworkClient) GetIpsecCpeDeviceConfigContent(ctx context.Context, request GetIpsecCpeDeviceConfigContentRequest) (response GetIpsecCpeDeviceConfigContentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getIpsecCpeDeviceConfigContent, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetIpsecCpeDeviceConfigContentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetIpsecCpeDeviceConfigContentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetIpsecCpeDeviceConfigContentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetIpsecCpeDeviceConfigContentResponse") + } + return +} + +// getIpsecCpeDeviceConfigContent implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getIpsecCpeDeviceConfigContent(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipsecConnections/{ipscId}/cpeConfigContent", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetIpsecCpeDeviceConfigContentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetIpv6 Gets the specified IPv6. You must specify the object's OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm). +// Alternatively, you can get the object by using +// ListIpv6s +// with the IPv6 address (for example, 2001:0db8:0123:1111:98fe:dcba:9876:4321) and subnet OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIpv6.go.html to see an example of how to use GetIpv6 API. +func (client VirtualNetworkClient) GetIpv6(ctx context.Context, request GetIpv6Request) (response GetIpv6Response, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getIpv6, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetIpv6Response{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetIpv6Response{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetIpv6Response); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetIpv6Response") + } + return +} + +// getIpv6 implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getIpv6(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipv6/{ipv6Id}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetIpv6Response + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetLocalPeeringGateway Gets the specified local peering gateway's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetLocalPeeringGateway.go.html to see an example of how to use GetLocalPeeringGateway API. +func (client VirtualNetworkClient) GetLocalPeeringGateway(ctx context.Context, request GetLocalPeeringGatewayRequest) (response GetLocalPeeringGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getLocalPeeringGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetLocalPeeringGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetLocalPeeringGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetLocalPeeringGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetLocalPeeringGatewayResponse") + } + return +} + +// getLocalPeeringGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getLocalPeeringGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/localPeeringGateways/{localPeeringGatewayId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetLocalPeeringGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetNatGateway Gets the specified NAT gateway's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetNatGateway.go.html to see an example of how to use GetNatGateway API. +func (client VirtualNetworkClient) GetNatGateway(ctx context.Context, request GetNatGatewayRequest) (response GetNatGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getNatGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetNatGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetNatGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetNatGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetNatGatewayResponse") + } + return +} + +// getNatGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getNatGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/natGateways/{natGatewayId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetNatGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetNetworkSecurityGroup Gets the specified network security group's information. +// To list the VNICs in an NSG, see +// ListNetworkSecurityGroupVnics. +// To list the security rules in an NSG, see +// ListNetworkSecurityGroupSecurityRules. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetNetworkSecurityGroup.go.html to see an example of how to use GetNetworkSecurityGroup API. +func (client VirtualNetworkClient) GetNetworkSecurityGroup(ctx context.Context, request GetNetworkSecurityGroupRequest) (response GetNetworkSecurityGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getNetworkSecurityGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetNetworkSecurityGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetNetworkSecurityGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetNetworkSecurityGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetNetworkSecurityGroupResponse") + } + return +} + +// getNetworkSecurityGroup implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getNetworkSecurityGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/networkSecurityGroups/{networkSecurityGroupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetNetworkSecurityGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetNetworkingTopology Gets a virtual networking topology for the current region. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetNetworkingTopology.go.html to see an example of how to use GetNetworkingTopology API. +func (client VirtualNetworkClient) GetNetworkingTopology(ctx context.Context, request GetNetworkingTopologyRequest) (response GetNetworkingTopologyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getNetworkingTopology, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetNetworkingTopologyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetNetworkingTopologyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetNetworkingTopologyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetNetworkingTopologyResponse") + } + return +} + +// getNetworkingTopology implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getNetworkingTopology(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/networkingTopology", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetNetworkingTopologyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetPrivateIp Gets the specified private IP. You must specify the object's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// Alternatively, you can get the object by using +// ListPrivateIps +// with the private IP address (for example, 10.0.3.3) and subnet OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetPrivateIp.go.html to see an example of how to use GetPrivateIp API. +func (client VirtualNetworkClient) GetPrivateIp(ctx context.Context, request GetPrivateIpRequest) (response GetPrivateIpResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getPrivateIp, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetPrivateIpResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetPrivateIpResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetPrivateIpResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetPrivateIpResponse") + } + return +} + +// getPrivateIp implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getPrivateIp(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/privateIps/{privateIpId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetPrivateIpResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetPublicIp Gets the specified public IP. You must specify the object's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// Alternatively, you can get the object by using GetPublicIpByIpAddress +// with the public IP address (for example, 203.0.113.2). +// Or you can use GetPublicIpByPrivateIpId +// with the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the private IP that the public IP is assigned to. +// **Note:** If you're fetching a reserved public IP that is in the process of being +// moved to a different private IP, the service returns the public IP object with +// `lifecycleState` = ASSIGNING and `assignedEntityId` = OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the target private IP. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetPublicIp.go.html to see an example of how to use GetPublicIp API. +func (client VirtualNetworkClient) GetPublicIp(ctx context.Context, request GetPublicIpRequest) (response GetPublicIpResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getPublicIp, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetPublicIpResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetPublicIpResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetPublicIpResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetPublicIpResponse") + } + return +} + +// getPublicIp implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getPublicIp(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/publicIps/{publicIpId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetPublicIpResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetPublicIpByIpAddress Gets the public IP based on the public IP address (for example, 203.0.113.2). +// **Note:** If you're fetching a reserved public IP that is in the process of being +// moved to a different private IP, the service returns the public IP object with +// `lifecycleState` = ASSIGNING and `assignedEntityId` = OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the target private IP. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetPublicIpByIpAddress.go.html to see an example of how to use GetPublicIpByIpAddress API. +func (client VirtualNetworkClient) GetPublicIpByIpAddress(ctx context.Context, request GetPublicIpByIpAddressRequest) (response GetPublicIpByIpAddressResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getPublicIpByIpAddress, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetPublicIpByIpAddressResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetPublicIpByIpAddressResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetPublicIpByIpAddressResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetPublicIpByIpAddressResponse") + } + return +} + +// getPublicIpByIpAddress implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getPublicIpByIpAddress(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/publicIps/actions/getByIpAddress", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetPublicIpByIpAddressResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetPublicIpByPrivateIpId Gets the public IP assigned to the specified private IP. You must specify the OCID +// of the private IP. If no public IP is assigned, a 404 is returned. +// **Note:** If you're fetching a reserved public IP that is in the process of being +// moved to a different private IP, and you provide the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the original private +// IP, this operation returns a 404. If you instead provide the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the target +// private IP, or if you instead call +// GetPublicIp or +// GetPublicIpByIpAddress, the +// service returns the public IP object with `lifecycleState` = ASSIGNING and +// `assignedEntityId` = OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the target private IP. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetPublicIpByPrivateIpId.go.html to see an example of how to use GetPublicIpByPrivateIpId API. +func (client VirtualNetworkClient) GetPublicIpByPrivateIpId(ctx context.Context, request GetPublicIpByPrivateIpIdRequest) (response GetPublicIpByPrivateIpIdResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getPublicIpByPrivateIpId, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetPublicIpByPrivateIpIdResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetPublicIpByPrivateIpIdResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetPublicIpByPrivateIpIdResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetPublicIpByPrivateIpIdResponse") + } + return +} + +// getPublicIpByPrivateIpId implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getPublicIpByPrivateIpId(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/publicIps/actions/getByPrivateIpId", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetPublicIpByPrivateIpIdResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetPublicIpPool Gets the specified `PublicIpPool` object. You must specify the object's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetPublicIpPool.go.html to see an example of how to use GetPublicIpPool API. +func (client VirtualNetworkClient) GetPublicIpPool(ctx context.Context, request GetPublicIpPoolRequest) (response GetPublicIpPoolResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getPublicIpPool, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetPublicIpPoolResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetPublicIpPoolResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetPublicIpPoolResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetPublicIpPoolResponse") + } + return +} + +// getPublicIpPool implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getPublicIpPool(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/publicIpPools/{publicIpPoolId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetPublicIpPoolResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetRemotePeeringConnection Get the specified remote peering connection's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetRemotePeeringConnection.go.html to see an example of how to use GetRemotePeeringConnection API. +func (client VirtualNetworkClient) GetRemotePeeringConnection(ctx context.Context, request GetRemotePeeringConnectionRequest) (response GetRemotePeeringConnectionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getRemotePeeringConnection, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetRemotePeeringConnectionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetRemotePeeringConnectionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetRemotePeeringConnectionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetRemotePeeringConnectionResponse") + } + return +} + +// getRemotePeeringConnection implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getRemotePeeringConnection(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/remotePeeringConnections/{remotePeeringConnectionId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetRemotePeeringConnectionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetRouteTable Gets the specified route table's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetRouteTable.go.html to see an example of how to use GetRouteTable API. +func (client VirtualNetworkClient) GetRouteTable(ctx context.Context, request GetRouteTableRequest) (response GetRouteTableResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getRouteTable, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetRouteTableResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetRouteTableResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetRouteTableResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetRouteTableResponse") + } + return +} + +// getRouteTable implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getRouteTable(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/routeTables/{rtId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetRouteTableResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetSecurityList Gets the specified security list's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetSecurityList.go.html to see an example of how to use GetSecurityList API. +func (client VirtualNetworkClient) GetSecurityList(ctx context.Context, request GetSecurityListRequest) (response GetSecurityListResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getSecurityList, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetSecurityListResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetSecurityListResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetSecurityListResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetSecurityListResponse") + } + return +} + +// getSecurityList implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getSecurityList(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/securityLists/{securityListId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetSecurityListResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetService Gets the specified Service object. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetService.go.html to see an example of how to use GetService API. +func (client VirtualNetworkClient) GetService(ctx context.Context, request GetServiceRequest) (response GetServiceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getService, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetServiceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetServiceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetServiceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetServiceResponse") + } + return +} + +// getService implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getService(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/services/{serviceId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetServiceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetServiceGateway Gets the specified service gateway's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetServiceGateway.go.html to see an example of how to use GetServiceGateway API. +func (client VirtualNetworkClient) GetServiceGateway(ctx context.Context, request GetServiceGatewayRequest) (response GetServiceGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getServiceGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetServiceGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetServiceGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetServiceGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetServiceGatewayResponse") + } + return +} + +// getServiceGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getServiceGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/serviceGateways/{serviceGatewayId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetServiceGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetSubnet Gets the specified subnet's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetSubnet.go.html to see an example of how to use GetSubnet API. +func (client VirtualNetworkClient) GetSubnet(ctx context.Context, request GetSubnetRequest) (response GetSubnetResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getSubnet, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetSubnetResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetSubnetResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetSubnetResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetSubnetResponse") + } + return +} + +// getSubnet implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getSubnet(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/subnets/{subnetId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetSubnetResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetSubnetTopology Gets a topology for a given subnet. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetSubnetTopology.go.html to see an example of how to use GetSubnetTopology API. +func (client VirtualNetworkClient) GetSubnetTopology(ctx context.Context, request GetSubnetTopologyRequest) (response GetSubnetTopologyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getSubnetTopology, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetSubnetTopologyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetSubnetTopologyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetSubnetTopologyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetSubnetTopologyResponse") + } + return +} + +// getSubnetTopology implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getSubnetTopology(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/subnetTopology", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetSubnetTopologyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetTunnelCpeDeviceConfig Gets the set of CPE configuration answers for the tunnel, which the customer provided in +// UpdateTunnelCpeDeviceConfig. +// To get the full set of content for the tunnel (any answers merged with the template of other +// information specific to the CPE device type), use +// GetTunnelCpeDeviceConfigContent. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetTunnelCpeDeviceConfig.go.html to see an example of how to use GetTunnelCpeDeviceConfig API. +func (client VirtualNetworkClient) GetTunnelCpeDeviceConfig(ctx context.Context, request GetTunnelCpeDeviceConfigRequest) (response GetTunnelCpeDeviceConfigResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getTunnelCpeDeviceConfig, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetTunnelCpeDeviceConfigResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetTunnelCpeDeviceConfigResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetTunnelCpeDeviceConfigResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetTunnelCpeDeviceConfigResponse") + } + return +} + +// getTunnelCpeDeviceConfig implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getTunnelCpeDeviceConfig(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipsecConnections/{ipscId}/tunnels/{tunnelId}/tunnelDeviceConfig", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetTunnelCpeDeviceConfigResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetTunnelCpeDeviceConfigContent Renders a set of CPE configuration content for the specified IPSec tunnel. The content helps a +// network engineer configure the actual CPE device (for example, a hardware router) that the specified +// IPSec tunnel terminates on. +// The rendered content is specific to the type of CPE device (for example, Cisco ASA). Therefore the +// Cpe used by the specified IPSecConnection +// must have the CPE's device type specified by the `cpeDeviceShapeId` attribute. The content +// optionally includes answers that the customer provides (see +// UpdateTunnelCpeDeviceConfig), +// merged with a template of other information specific to the CPE device type. +// The operation returns configuration information for only the specified IPSec tunnel. +// Here are other similar operations: +// * GetIpsecCpeDeviceConfigContent +// returns CPE configuration content for all tunnels in a single IPSec connection. +// * GetCpeDeviceConfigContent +// returns CPE configuration content for *all* IPSec connections that use a specific CPE. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetTunnelCpeDeviceConfigContent.go.html to see an example of how to use GetTunnelCpeDeviceConfigContent API. +func (client VirtualNetworkClient) GetTunnelCpeDeviceConfigContent(ctx context.Context, request GetTunnelCpeDeviceConfigContentRequest) (response GetTunnelCpeDeviceConfigContentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getTunnelCpeDeviceConfigContent, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetTunnelCpeDeviceConfigContentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetTunnelCpeDeviceConfigContentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetTunnelCpeDeviceConfigContentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetTunnelCpeDeviceConfigContentResponse") + } + return +} + +// getTunnelCpeDeviceConfigContent implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getTunnelCpeDeviceConfigContent(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipsecConnections/{ipscId}/tunnels/{tunnelId}/tunnelDeviceConfig/content", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetTunnelCpeDeviceConfigContentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetUpgradeStatus Returns the DRG upgrade status. The status can be not updated, in progress, or updated. Also indicates how much of the upgrade is completed. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetUpgradeStatus.go.html to see an example of how to use GetUpgradeStatus API. +func (client VirtualNetworkClient) GetUpgradeStatus(ctx context.Context, request GetUpgradeStatusRequest) (response GetUpgradeStatusResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getUpgradeStatus, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetUpgradeStatusResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetUpgradeStatusResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetUpgradeStatusResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetUpgradeStatusResponse") + } + return +} + +// getUpgradeStatus implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getUpgradeStatus(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/drgs/{drgId}/actions/upgradeStatus", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetUpgradeStatusResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVcn Gets the specified VCN's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVcn.go.html to see an example of how to use GetVcn API. +func (client VirtualNetworkClient) GetVcn(ctx context.Context, request GetVcnRequest) (response GetVcnResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVcn, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVcnResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVcnResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVcnResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVcnResponse") + } + return +} + +// getVcn implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getVcn(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/vcns/{vcnId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVcnResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVcnDnsResolverAssociation Get the associated DNS resolver information with a vcn +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVcnDnsResolverAssociation.go.html to see an example of how to use GetVcnDnsResolverAssociation API. +func (client VirtualNetworkClient) GetVcnDnsResolverAssociation(ctx context.Context, request GetVcnDnsResolverAssociationRequest) (response GetVcnDnsResolverAssociationResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVcnDnsResolverAssociation, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVcnDnsResolverAssociationResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVcnDnsResolverAssociationResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVcnDnsResolverAssociationResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVcnDnsResolverAssociationResponse") + } + return +} + +// getVcnDnsResolverAssociation implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getVcnDnsResolverAssociation(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/vcns/{vcnId}/dnsResolverAssociation", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVcnDnsResolverAssociationResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVcnTopology Gets a virtual network topology for a given VCN. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVcnTopology.go.html to see an example of how to use GetVcnTopology API. +func (client VirtualNetworkClient) GetVcnTopology(ctx context.Context, request GetVcnTopologyRequest) (response GetVcnTopologyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVcnTopology, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVcnTopologyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVcnTopologyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVcnTopologyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVcnTopologyResponse") + } + return +} + +// getVcnTopology implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getVcnTopology(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/vcnTopology", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVcnTopologyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVirtualCircuit Gets the specified virtual circuit's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVirtualCircuit.go.html to see an example of how to use GetVirtualCircuit API. +func (client VirtualNetworkClient) GetVirtualCircuit(ctx context.Context, request GetVirtualCircuitRequest) (response GetVirtualCircuitResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVirtualCircuit, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVirtualCircuitResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVirtualCircuitResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVirtualCircuitResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVirtualCircuitResponse") + } + return +} + +// getVirtualCircuit implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getVirtualCircuit(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/virtualCircuits/{virtualCircuitId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVirtualCircuitResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVlan Gets the specified VLAN's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVlan.go.html to see an example of how to use GetVlan API. +func (client VirtualNetworkClient) GetVlan(ctx context.Context, request GetVlanRequest) (response GetVlanResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVlan, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVlanResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVlanResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVlanResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVlanResponse") + } + return +} + +// getVlan implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getVlan(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/vlans/{vlanId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVlanResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetVnic Gets the information for the specified virtual network interface card (VNIC). +// You can get the VNIC OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) from the +// ListVnicAttachments +// operation. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVnic.go.html to see an example of how to use GetVnic API. +func (client VirtualNetworkClient) GetVnic(ctx context.Context, request GetVnicRequest) (response GetVnicResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getVnic, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetVnicResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetVnicResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetVnicResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetVnicResponse") + } + return +} + +// getVnic implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) getVnic(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/vnics/{vnicId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetVnicResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListAllowedPeerRegionsForRemotePeering Lists the regions that support remote VCN peering (which is peering across regions). +// For more information, see VCN Peering (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/VCNpeering.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListAllowedPeerRegionsForRemotePeering.go.html to see an example of how to use ListAllowedPeerRegionsForRemotePeering API. +func (client VirtualNetworkClient) ListAllowedPeerRegionsForRemotePeering(ctx context.Context, request ListAllowedPeerRegionsForRemotePeeringRequest) (response ListAllowedPeerRegionsForRemotePeeringResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listAllowedPeerRegionsForRemotePeering, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListAllowedPeerRegionsForRemotePeeringResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListAllowedPeerRegionsForRemotePeeringResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListAllowedPeerRegionsForRemotePeeringResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListAllowedPeerRegionsForRemotePeeringResponse") + } + return +} + +// listAllowedPeerRegionsForRemotePeering implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listAllowedPeerRegionsForRemotePeering(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/allowedPeerRegionsForRemotePeering", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListAllowedPeerRegionsForRemotePeeringResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListByoipAllocatedRanges Lists the subranges of a BYOIP CIDR block currently allocated to an IP pool. +// Each `ByoipAllocatedRange` object also lists the IP pool where it is allocated. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListByoipAllocatedRanges.go.html to see an example of how to use ListByoipAllocatedRanges API. +func (client VirtualNetworkClient) ListByoipAllocatedRanges(ctx context.Context, request ListByoipAllocatedRangesRequest) (response ListByoipAllocatedRangesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listByoipAllocatedRanges, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListByoipAllocatedRangesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListByoipAllocatedRangesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListByoipAllocatedRangesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListByoipAllocatedRangesResponse") + } + return +} + +// listByoipAllocatedRanges implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listByoipAllocatedRanges(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/byoipRanges/{byoipRangeId}/byoipAllocatedRanges", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListByoipAllocatedRangesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListByoipRanges Lists the `ByoipRange` resources in the specified compartment. +// You can filter the list using query parameters. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListByoipRanges.go.html to see an example of how to use ListByoipRanges API. +func (client VirtualNetworkClient) ListByoipRanges(ctx context.Context, request ListByoipRangesRequest) (response ListByoipRangesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listByoipRanges, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListByoipRangesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListByoipRangesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListByoipRangesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListByoipRangesResponse") + } + return +} + +// listByoipRanges implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listByoipRanges(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/byoipRanges", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListByoipRangesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListCpeDeviceShapes Lists the CPE device types that the Networking service provides CPE configuration +// content for (example: Cisco ASA). The content helps a network engineer configure +// the actual CPE device represented by a Cpe object. +// If you want to generate CPE configuration content for one of the returned CPE device types, +// ensure that the Cpe object's `cpeDeviceShapeId` attribute is set +// to the CPE device type's OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) (returned by this operation). +// For information about generating CPE configuration content, see these operations: +// * GetCpeDeviceConfigContent +// * GetIpsecCpeDeviceConfigContent +// * GetTunnelCpeDeviceConfigContent +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListCpeDeviceShapes.go.html to see an example of how to use ListCpeDeviceShapes API. +func (client VirtualNetworkClient) ListCpeDeviceShapes(ctx context.Context, request ListCpeDeviceShapesRequest) (response ListCpeDeviceShapesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listCpeDeviceShapes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListCpeDeviceShapesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListCpeDeviceShapesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListCpeDeviceShapesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListCpeDeviceShapesResponse") + } + return +} + +// listCpeDeviceShapes implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listCpeDeviceShapes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/cpeDeviceShapes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListCpeDeviceShapesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListCpes Lists the customer-premises equipment objects (CPEs) in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListCpes.go.html to see an example of how to use ListCpes API. +func (client VirtualNetworkClient) ListCpes(ctx context.Context, request ListCpesRequest) (response ListCpesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listCpes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListCpesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListCpesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListCpesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListCpesResponse") + } + return +} + +// listCpes implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listCpes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/cpes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListCpesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListCrossConnectGroups Lists the cross-connect groups in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListCrossConnectGroups.go.html to see an example of how to use ListCrossConnectGroups API. +func (client VirtualNetworkClient) ListCrossConnectGroups(ctx context.Context, request ListCrossConnectGroupsRequest) (response ListCrossConnectGroupsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listCrossConnectGroups, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListCrossConnectGroupsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListCrossConnectGroupsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListCrossConnectGroupsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListCrossConnectGroupsResponse") + } + return +} + +// listCrossConnectGroups implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listCrossConnectGroups(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/crossConnectGroups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListCrossConnectGroupsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListCrossConnectLocations Lists the available FastConnect locations for cross-connect installation. You need +// this information so you can specify your desired location when you create a cross-connect. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListCrossConnectLocations.go.html to see an example of how to use ListCrossConnectLocations API. +func (client VirtualNetworkClient) ListCrossConnectLocations(ctx context.Context, request ListCrossConnectLocationsRequest) (response ListCrossConnectLocationsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listCrossConnectLocations, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListCrossConnectLocationsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListCrossConnectLocationsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListCrossConnectLocationsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListCrossConnectLocationsResponse") + } + return +} + +// listCrossConnectLocations implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listCrossConnectLocations(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/crossConnectLocations", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListCrossConnectLocationsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListCrossConnectMappings Lists the Cross Connect mapping Details for the specified +// virtual circuit. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListCrossConnectMappings.go.html to see an example of how to use ListCrossConnectMappings API. +func (client VirtualNetworkClient) ListCrossConnectMappings(ctx context.Context, request ListCrossConnectMappingsRequest) (response ListCrossConnectMappingsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listCrossConnectMappings, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListCrossConnectMappingsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListCrossConnectMappingsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListCrossConnectMappingsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListCrossConnectMappingsResponse") + } + return +} + +// listCrossConnectMappings implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listCrossConnectMappings(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/virtualCircuits/{virtualCircuitId}/crossConnectMappings", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListCrossConnectMappingsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListCrossConnects Lists the cross-connects in the specified compartment. You can filter the list +// by specifying the OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of a cross-connect group. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListCrossConnects.go.html to see an example of how to use ListCrossConnects API. +func (client VirtualNetworkClient) ListCrossConnects(ctx context.Context, request ListCrossConnectsRequest) (response ListCrossConnectsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listCrossConnects, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListCrossConnectsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListCrossConnectsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListCrossConnectsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListCrossConnectsResponse") + } + return +} + +// listCrossConnects implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listCrossConnects(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/crossConnects", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListCrossConnectsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListCrossconnectPortSpeedShapes Lists the available port speeds for cross-connects. You need this information +// so you can specify your desired port speed (that is, shape) when you create a +// cross-connect. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListCrossconnectPortSpeedShapes.go.html to see an example of how to use ListCrossconnectPortSpeedShapes API. +func (client VirtualNetworkClient) ListCrossconnectPortSpeedShapes(ctx context.Context, request ListCrossconnectPortSpeedShapesRequest) (response ListCrossconnectPortSpeedShapesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listCrossconnectPortSpeedShapes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListCrossconnectPortSpeedShapesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListCrossconnectPortSpeedShapesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListCrossconnectPortSpeedShapesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListCrossconnectPortSpeedShapesResponse") + } + return +} + +// listCrossconnectPortSpeedShapes implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listCrossconnectPortSpeedShapes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/crossConnectPortSpeedShapes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListCrossconnectPortSpeedShapesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListDhcpOptions Lists the sets of DHCP options in the specified VCN and specified compartment. +// If the VCN ID is not provided, then the list includes the sets of DHCP options from all VCNs in the specified compartment. +// The response includes the default set of options that automatically comes with each VCN, +// plus any other sets you've created. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDhcpOptions.go.html to see an example of how to use ListDhcpOptions API. +func (client VirtualNetworkClient) ListDhcpOptions(ctx context.Context, request ListDhcpOptionsRequest) (response ListDhcpOptionsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listDhcpOptions, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListDhcpOptionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListDhcpOptionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListDhcpOptionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListDhcpOptionsResponse") + } + return +} + +// listDhcpOptions implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listDhcpOptions(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/dhcps", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListDhcpOptionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListDrgAttachments Lists the `DrgAttachment` resource for the specified compartment. You can filter the +// results by DRG, attached network, attachment type, DRG route table or +// VCN route table. +// The LIST API lists DRG attachments by attachment type. It will default to list VCN attachments, +// but you may request to list ALL attachments of ALL types. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDrgAttachments.go.html to see an example of how to use ListDrgAttachments API. +func (client VirtualNetworkClient) ListDrgAttachments(ctx context.Context, request ListDrgAttachmentsRequest) (response ListDrgAttachmentsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listDrgAttachments, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListDrgAttachmentsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListDrgAttachmentsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListDrgAttachmentsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListDrgAttachmentsResponse") + } + return +} + +// listDrgAttachments implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listDrgAttachments(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/drgAttachments", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListDrgAttachmentsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListDrgRouteDistributionStatements Lists the statements for the specified route distribution. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDrgRouteDistributionStatements.go.html to see an example of how to use ListDrgRouteDistributionStatements API. +func (client VirtualNetworkClient) ListDrgRouteDistributionStatements(ctx context.Context, request ListDrgRouteDistributionStatementsRequest) (response ListDrgRouteDistributionStatementsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listDrgRouteDistributionStatements, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListDrgRouteDistributionStatementsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListDrgRouteDistributionStatementsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListDrgRouteDistributionStatementsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListDrgRouteDistributionStatementsResponse") + } + return +} + +// listDrgRouteDistributionStatements implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listDrgRouteDistributionStatements(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/drgRouteDistributions/{drgRouteDistributionId}/drgRouteDistributionStatements", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListDrgRouteDistributionStatementsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListDrgRouteDistributions Lists the route distributions in the specified DRG. +// To retrieve the statements in a distribution, use the +// ListDrgRouteDistributionStatements operation. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDrgRouteDistributions.go.html to see an example of how to use ListDrgRouteDistributions API. +func (client VirtualNetworkClient) ListDrgRouteDistributions(ctx context.Context, request ListDrgRouteDistributionsRequest) (response ListDrgRouteDistributionsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listDrgRouteDistributions, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListDrgRouteDistributionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListDrgRouteDistributionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListDrgRouteDistributionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListDrgRouteDistributionsResponse") + } + return +} + +// listDrgRouteDistributions implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listDrgRouteDistributions(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/drgRouteDistributions", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListDrgRouteDistributionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListDrgRouteRules Lists the route rules in the specified DRG route table. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDrgRouteRules.go.html to see an example of how to use ListDrgRouteRules API. +func (client VirtualNetworkClient) ListDrgRouteRules(ctx context.Context, request ListDrgRouteRulesRequest) (response ListDrgRouteRulesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listDrgRouteRules, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListDrgRouteRulesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListDrgRouteRulesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListDrgRouteRulesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListDrgRouteRulesResponse") + } + return +} + +// listDrgRouteRules implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listDrgRouteRules(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/drgRouteTables/{drgRouteTableId}/drgRouteRules", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListDrgRouteRulesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListDrgRouteTables Lists the DRG route tables for the specified DRG. +// Use the `ListDrgRouteRules` operation to retrieve the route rules in a table. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDrgRouteTables.go.html to see an example of how to use ListDrgRouteTables API. +func (client VirtualNetworkClient) ListDrgRouteTables(ctx context.Context, request ListDrgRouteTablesRequest) (response ListDrgRouteTablesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listDrgRouteTables, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListDrgRouteTablesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListDrgRouteTablesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListDrgRouteTablesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListDrgRouteTablesResponse") + } + return +} + +// listDrgRouteTables implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listDrgRouteTables(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/drgRouteTables", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListDrgRouteTablesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListDrgs Lists the DRGs in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDrgs.go.html to see an example of how to use ListDrgs API. +func (client VirtualNetworkClient) ListDrgs(ctx context.Context, request ListDrgsRequest) (response ListDrgsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listDrgs, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListDrgsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListDrgsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListDrgsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListDrgsResponse") + } + return +} + +// listDrgs implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listDrgs(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/drgs", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListDrgsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListFastConnectProviderServices Lists the service offerings from supported providers. You need this +// information so you can specify your desired provider and service +// offering when you create a virtual circuit. +// For the compartment ID, provide the OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of your tenancy (the root compartment). +// For more information, see FastConnect Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/fastconnect.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListFastConnectProviderServices.go.html to see an example of how to use ListFastConnectProviderServices API. +func (client VirtualNetworkClient) ListFastConnectProviderServices(ctx context.Context, request ListFastConnectProviderServicesRequest) (response ListFastConnectProviderServicesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listFastConnectProviderServices, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListFastConnectProviderServicesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListFastConnectProviderServicesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListFastConnectProviderServicesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListFastConnectProviderServicesResponse") + } + return +} + +// listFastConnectProviderServices implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listFastConnectProviderServices(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/fastConnectProviderServices", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListFastConnectProviderServicesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListFastConnectProviderVirtualCircuitBandwidthShapes Gets the list of available virtual circuit bandwidth levels for a provider. +// You need this information so you can specify your desired bandwidth level (shape) when you create a virtual circuit. +// For more information about virtual circuits, see FastConnect Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/fastconnect.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListFastConnectProviderVirtualCircuitBandwidthShapes.go.html to see an example of how to use ListFastConnectProviderVirtualCircuitBandwidthShapes API. +func (client VirtualNetworkClient) ListFastConnectProviderVirtualCircuitBandwidthShapes(ctx context.Context, request ListFastConnectProviderVirtualCircuitBandwidthShapesRequest) (response ListFastConnectProviderVirtualCircuitBandwidthShapesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listFastConnectProviderVirtualCircuitBandwidthShapes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListFastConnectProviderVirtualCircuitBandwidthShapesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListFastConnectProviderVirtualCircuitBandwidthShapesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListFastConnectProviderVirtualCircuitBandwidthShapesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListFastConnectProviderVirtualCircuitBandwidthShapesResponse") + } + return +} + +// listFastConnectProviderVirtualCircuitBandwidthShapes implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listFastConnectProviderVirtualCircuitBandwidthShapes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/fastConnectProviderServices/{providerServiceId}/virtualCircuitBandwidthShapes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListFastConnectProviderVirtualCircuitBandwidthShapesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListIPSecConnectionTunnelRoutes The routes advertised to the Customer and the routes received from the Customer. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListIPSecConnectionTunnelRoutes.go.html to see an example of how to use ListIPSecConnectionTunnelRoutes API. +func (client VirtualNetworkClient) ListIPSecConnectionTunnelRoutes(ctx context.Context, request ListIPSecConnectionTunnelRoutesRequest) (response ListIPSecConnectionTunnelRoutesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listIPSecConnectionTunnelRoutes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListIPSecConnectionTunnelRoutesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListIPSecConnectionTunnelRoutesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListIPSecConnectionTunnelRoutesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListIPSecConnectionTunnelRoutesResponse") + } + return +} + +// listIPSecConnectionTunnelRoutes implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listIPSecConnectionTunnelRoutes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipsecConnections/{ipscId}/tunnels/{tunnelId}/routes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListIPSecConnectionTunnelRoutesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListIPSecConnectionTunnelSecurityAssociations Lists the tunnel Security Associations information for the specified IPSec Tunnel ID. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListIPSecConnectionTunnelSecurityAssociations.go.html to see an example of how to use ListIPSecConnectionTunnelSecurityAssociations API. +func (client VirtualNetworkClient) ListIPSecConnectionTunnelSecurityAssociations(ctx context.Context, request ListIPSecConnectionTunnelSecurityAssociationsRequest) (response ListIPSecConnectionTunnelSecurityAssociationsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listIPSecConnectionTunnelSecurityAssociations, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListIPSecConnectionTunnelSecurityAssociationsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListIPSecConnectionTunnelSecurityAssociationsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListIPSecConnectionTunnelSecurityAssociationsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListIPSecConnectionTunnelSecurityAssociationsResponse") + } + return +} + +// listIPSecConnectionTunnelSecurityAssociations implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listIPSecConnectionTunnelSecurityAssociations(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipsecConnections/{ipscId}/tunnels/{tunnelId}/tunnelSecurityAssociations", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListIPSecConnectionTunnelSecurityAssociationsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListIPSecConnectionTunnels Lists the tunnel information for the specified IPSec connection. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListIPSecConnectionTunnels.go.html to see an example of how to use ListIPSecConnectionTunnels API. +func (client VirtualNetworkClient) ListIPSecConnectionTunnels(ctx context.Context, request ListIPSecConnectionTunnelsRequest) (response ListIPSecConnectionTunnelsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listIPSecConnectionTunnels, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListIPSecConnectionTunnelsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListIPSecConnectionTunnelsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListIPSecConnectionTunnelsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListIPSecConnectionTunnelsResponse") + } + return +} + +// listIPSecConnectionTunnels implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listIPSecConnectionTunnels(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipsecConnections/{ipscId}/tunnels", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListIPSecConnectionTunnelsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListIPSecConnections Lists the IPSec connections for the specified compartment. You can filter the +// results by DRG or CPE. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListIPSecConnections.go.html to see an example of how to use ListIPSecConnections API. +func (client VirtualNetworkClient) ListIPSecConnections(ctx context.Context, request ListIPSecConnectionsRequest) (response ListIPSecConnectionsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listIPSecConnections, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListIPSecConnectionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListIPSecConnectionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListIPSecConnectionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListIPSecConnectionsResponse") + } + return +} + +// listIPSecConnections implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listIPSecConnections(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipsecConnections", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListIPSecConnectionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListInternetGateways Lists the internet gateways in the specified VCN and the specified compartment. +// If the VCN ID is not provided, then the list includes the internet gateways from all VCNs in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListInternetGateways.go.html to see an example of how to use ListInternetGateways API. +func (client VirtualNetworkClient) ListInternetGateways(ctx context.Context, request ListInternetGatewaysRequest) (response ListInternetGatewaysResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listInternetGateways, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListInternetGatewaysResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListInternetGatewaysResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListInternetGatewaysResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListInternetGatewaysResponse") + } + return +} + +// listInternetGateways implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listInternetGateways(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/internetGateways", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListInternetGatewaysResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListIpv6s Lists the Ipv6 objects based +// on one of these filters: +// * Subnet OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// * VNIC OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// * Both IPv6 address and subnet OCID: This lets you get an `Ipv6` object based on its private +// IPv6 address (for example, 2001:0db8:0123:1111:abcd:ef01:2345:6789) and not its OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). For comparison, +// GetIpv6 requires the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListIpv6s.go.html to see an example of how to use ListIpv6s API. +func (client VirtualNetworkClient) ListIpv6s(ctx context.Context, request ListIpv6sRequest) (response ListIpv6sResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listIpv6s, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListIpv6sResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListIpv6sResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListIpv6sResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListIpv6sResponse") + } + return +} + +// listIpv6s implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listIpv6s(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/ipv6", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListIpv6sResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListLocalPeeringGateways Lists the local peering gateways (LPGs) for the specified VCN and specified compartment. +// If the VCN ID is not provided, then the list includes the LPGs from all VCNs in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListLocalPeeringGateways.go.html to see an example of how to use ListLocalPeeringGateways API. +func (client VirtualNetworkClient) ListLocalPeeringGateways(ctx context.Context, request ListLocalPeeringGatewaysRequest) (response ListLocalPeeringGatewaysResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listLocalPeeringGateways, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListLocalPeeringGatewaysResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListLocalPeeringGatewaysResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListLocalPeeringGatewaysResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListLocalPeeringGatewaysResponse") + } + return +} + +// listLocalPeeringGateways implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listLocalPeeringGateways(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/localPeeringGateways", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListLocalPeeringGatewaysResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListNatGateways Lists the NAT gateways in the specified compartment. You may optionally specify a VCN OCID +// to filter the results by VCN. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListNatGateways.go.html to see an example of how to use ListNatGateways API. +func (client VirtualNetworkClient) ListNatGateways(ctx context.Context, request ListNatGatewaysRequest) (response ListNatGatewaysResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listNatGateways, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListNatGatewaysResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListNatGatewaysResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListNatGatewaysResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListNatGatewaysResponse") + } + return +} + +// listNatGateways implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listNatGateways(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/natGateways", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListNatGatewaysResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListNetworkSecurityGroupSecurityRules Lists the security rules in the specified network security group. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListNetworkSecurityGroupSecurityRules.go.html to see an example of how to use ListNetworkSecurityGroupSecurityRules API. +func (client VirtualNetworkClient) ListNetworkSecurityGroupSecurityRules(ctx context.Context, request ListNetworkSecurityGroupSecurityRulesRequest) (response ListNetworkSecurityGroupSecurityRulesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listNetworkSecurityGroupSecurityRules, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListNetworkSecurityGroupSecurityRulesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListNetworkSecurityGroupSecurityRulesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListNetworkSecurityGroupSecurityRulesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListNetworkSecurityGroupSecurityRulesResponse") + } + return +} + +// listNetworkSecurityGroupSecurityRules implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listNetworkSecurityGroupSecurityRules(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/networkSecurityGroups/{networkSecurityGroupId}/securityRules", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListNetworkSecurityGroupSecurityRulesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListNetworkSecurityGroupVnics Lists the VNICs in the specified network security group. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListNetworkSecurityGroupVnics.go.html to see an example of how to use ListNetworkSecurityGroupVnics API. +func (client VirtualNetworkClient) ListNetworkSecurityGroupVnics(ctx context.Context, request ListNetworkSecurityGroupVnicsRequest) (response ListNetworkSecurityGroupVnicsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listNetworkSecurityGroupVnics, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListNetworkSecurityGroupVnicsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListNetworkSecurityGroupVnicsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListNetworkSecurityGroupVnicsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListNetworkSecurityGroupVnicsResponse") + } + return +} + +// listNetworkSecurityGroupVnics implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listNetworkSecurityGroupVnics(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/networkSecurityGroups/{networkSecurityGroupId}/vnics", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListNetworkSecurityGroupVnicsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListNetworkSecurityGroups Lists either the network security groups in the specified compartment, or those associated with the specified VLAN. +// You must specify either a `vlanId` or a `compartmentId`, but not both. If you specify a `vlanId`, all other parameters are ignored. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListNetworkSecurityGroups.go.html to see an example of how to use ListNetworkSecurityGroups API. +func (client VirtualNetworkClient) ListNetworkSecurityGroups(ctx context.Context, request ListNetworkSecurityGroupsRequest) (response ListNetworkSecurityGroupsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listNetworkSecurityGroups, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListNetworkSecurityGroupsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListNetworkSecurityGroupsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListNetworkSecurityGroupsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListNetworkSecurityGroupsResponse") + } + return +} + +// listNetworkSecurityGroups implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listNetworkSecurityGroups(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/networkSecurityGroups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListNetworkSecurityGroupsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListPrivateIps Lists the PrivateIp objects based +// on one of these filters: +// - Subnet OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// - VNIC OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// - Both private IP address and subnet OCID: This lets +// you get a `privateIP` object based on its private IP +// address (for example, 10.0.3.3) and not its OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). For comparison, +// GetPrivateIp +// requires the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// If you're listing all the private IPs associated with a given subnet +// or VNIC, the response includes both primary and secondary private IPs. +// If you are an Oracle Cloud VMware Solution customer and have VLANs +// in your VCN, you can filter the list by VLAN OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). See Vlan. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListPrivateIps.go.html to see an example of how to use ListPrivateIps API. +func (client VirtualNetworkClient) ListPrivateIps(ctx context.Context, request ListPrivateIpsRequest) (response ListPrivateIpsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listPrivateIps, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListPrivateIpsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListPrivateIpsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListPrivateIpsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListPrivateIpsResponse") + } + return +} + +// listPrivateIps implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listPrivateIps(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/privateIps", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListPrivateIpsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListPublicIpPools Lists the public IP pools in the specified compartment. +// You can filter the list using query parameters. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListPublicIpPools.go.html to see an example of how to use ListPublicIpPools API. +func (client VirtualNetworkClient) ListPublicIpPools(ctx context.Context, request ListPublicIpPoolsRequest) (response ListPublicIpPoolsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listPublicIpPools, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListPublicIpPoolsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListPublicIpPoolsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListPublicIpPoolsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListPublicIpPoolsResponse") + } + return +} + +// listPublicIpPools implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listPublicIpPools(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/publicIpPools", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListPublicIpPoolsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListPublicIps Lists the PublicIp objects +// in the specified compartment. You can filter the list by using query parameters. +// To list your reserved public IPs: +// * Set `scope` = `REGION` (required) +// * Leave the `availabilityDomain` parameter empty +// * Set `lifetime` = `RESERVED` +// To list the ephemeral public IPs assigned to a regional entity such as a NAT gateway: +// * Set `scope` = `REGION` (required) +// * Leave the `availabilityDomain` parameter empty +// * Set `lifetime` = `EPHEMERAL` +// To list the ephemeral public IPs assigned to private IPs: +// * Set `scope` = `AVAILABILITY_DOMAIN` (required) +// * Set the `availabilityDomain` parameter to the desired availability domain (required) +// * Set `lifetime` = `EPHEMERAL` +// **Note:** An ephemeral public IP assigned to a private IP +// is always in the same availability domain and compartment as the private IP. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListPublicIps.go.html to see an example of how to use ListPublicIps API. +func (client VirtualNetworkClient) ListPublicIps(ctx context.Context, request ListPublicIpsRequest) (response ListPublicIpsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listPublicIps, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListPublicIpsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListPublicIpsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListPublicIpsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListPublicIpsResponse") + } + return +} + +// listPublicIps implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listPublicIps(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/publicIps", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListPublicIpsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListRemotePeeringConnections Lists the remote peering connections (RPCs) for the specified DRG and compartment +// (the RPC's compartment). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListRemotePeeringConnections.go.html to see an example of how to use ListRemotePeeringConnections API. +func (client VirtualNetworkClient) ListRemotePeeringConnections(ctx context.Context, request ListRemotePeeringConnectionsRequest) (response ListRemotePeeringConnectionsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listRemotePeeringConnections, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListRemotePeeringConnectionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListRemotePeeringConnectionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListRemotePeeringConnectionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListRemotePeeringConnectionsResponse") + } + return +} + +// listRemotePeeringConnections implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listRemotePeeringConnections(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/remotePeeringConnections", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListRemotePeeringConnectionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListRouteTables Lists the route tables in the specified VCN and specified compartment. +// If the VCN ID is not provided, then the list includes the route tables from all VCNs in the specified compartment. +// The response includes the default route table that automatically comes with +// each VCN in the specified compartment, plus any route tables you've created. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListRouteTables.go.html to see an example of how to use ListRouteTables API. +func (client VirtualNetworkClient) ListRouteTables(ctx context.Context, request ListRouteTablesRequest) (response ListRouteTablesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listRouteTables, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListRouteTablesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListRouteTablesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListRouteTablesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListRouteTablesResponse") + } + return +} + +// listRouteTables implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listRouteTables(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/routeTables", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListRouteTablesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListSecurityLists Lists the security lists in the specified VCN and compartment. +// If the VCN ID is not provided, then the list includes the security lists from all VCNs in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListSecurityLists.go.html to see an example of how to use ListSecurityLists API. +func (client VirtualNetworkClient) ListSecurityLists(ctx context.Context, request ListSecurityListsRequest) (response ListSecurityListsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listSecurityLists, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListSecurityListsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListSecurityListsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListSecurityListsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListSecurityListsResponse") + } + return +} + +// listSecurityLists implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listSecurityLists(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/securityLists", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListSecurityListsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListServiceGateways Lists the service gateways in the specified compartment. You may optionally specify a VCN OCID +// to filter the results by VCN. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListServiceGateways.go.html to see an example of how to use ListServiceGateways API. +func (client VirtualNetworkClient) ListServiceGateways(ctx context.Context, request ListServiceGatewaysRequest) (response ListServiceGatewaysResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listServiceGateways, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListServiceGatewaysResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListServiceGatewaysResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListServiceGatewaysResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListServiceGatewaysResponse") + } + return +} + +// listServiceGateways implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listServiceGateways(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/serviceGateways", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListServiceGatewaysResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListServices Lists the available Service objects that you can enable for a +// service gateway in this region. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListServices.go.html to see an example of how to use ListServices API. +func (client VirtualNetworkClient) ListServices(ctx context.Context, request ListServicesRequest) (response ListServicesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listServices, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListServicesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListServicesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListServicesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListServicesResponse") + } + return +} + +// listServices implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listServices(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/services", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListServicesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListSubnets Lists the subnets in the specified VCN and the specified compartment. +// If the VCN ID is not provided, then the list includes the subnets from all VCNs in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListSubnets.go.html to see an example of how to use ListSubnets API. +func (client VirtualNetworkClient) ListSubnets(ctx context.Context, request ListSubnetsRequest) (response ListSubnetsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listSubnets, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListSubnetsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListSubnetsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListSubnetsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListSubnetsResponse") + } + return +} + +// listSubnets implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listSubnets(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/subnets", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListSubnetsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListVcns Lists the virtual cloud networks (VCNs) in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVcns.go.html to see an example of how to use ListVcns API. +func (client VirtualNetworkClient) ListVcns(ctx context.Context, request ListVcnsRequest) (response ListVcnsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listVcns, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListVcnsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListVcnsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListVcnsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListVcnsResponse") + } + return +} + +// listVcns implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listVcns(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/vcns", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListVcnsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListVirtualCircuitBandwidthShapes The deprecated operation lists available bandwidth levels for virtual circuits. For the compartment ID, provide the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of your tenancy (the root compartment). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVirtualCircuitBandwidthShapes.go.html to see an example of how to use ListVirtualCircuitBandwidthShapes API. +func (client VirtualNetworkClient) ListVirtualCircuitBandwidthShapes(ctx context.Context, request ListVirtualCircuitBandwidthShapesRequest) (response ListVirtualCircuitBandwidthShapesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listVirtualCircuitBandwidthShapes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListVirtualCircuitBandwidthShapesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListVirtualCircuitBandwidthShapesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListVirtualCircuitBandwidthShapesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListVirtualCircuitBandwidthShapesResponse") + } + return +} + +// listVirtualCircuitBandwidthShapes implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listVirtualCircuitBandwidthShapes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/virtualCircuitBandwidthShapes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListVirtualCircuitBandwidthShapesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListVirtualCircuitPublicPrefixes Lists the public IP prefixes and their details for the specified +// public virtual circuit. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVirtualCircuitPublicPrefixes.go.html to see an example of how to use ListVirtualCircuitPublicPrefixes API. +func (client VirtualNetworkClient) ListVirtualCircuitPublicPrefixes(ctx context.Context, request ListVirtualCircuitPublicPrefixesRequest) (response ListVirtualCircuitPublicPrefixesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listVirtualCircuitPublicPrefixes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListVirtualCircuitPublicPrefixesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListVirtualCircuitPublicPrefixesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListVirtualCircuitPublicPrefixesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListVirtualCircuitPublicPrefixesResponse") + } + return +} + +// listVirtualCircuitPublicPrefixes implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listVirtualCircuitPublicPrefixes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/virtualCircuits/{virtualCircuitId}/publicPrefixes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListVirtualCircuitPublicPrefixesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListVirtualCircuits Lists the virtual circuits in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVirtualCircuits.go.html to see an example of how to use ListVirtualCircuits API. +func (client VirtualNetworkClient) ListVirtualCircuits(ctx context.Context, request ListVirtualCircuitsRequest) (response ListVirtualCircuitsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listVirtualCircuits, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListVirtualCircuitsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListVirtualCircuitsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListVirtualCircuitsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListVirtualCircuitsResponse") + } + return +} + +// listVirtualCircuits implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listVirtualCircuits(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/virtualCircuits", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListVirtualCircuitsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListVlans Lists the VLANs in the specified VCN and the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVlans.go.html to see an example of how to use ListVlans API. +func (client VirtualNetworkClient) ListVlans(ctx context.Context, request ListVlansRequest) (response ListVlansResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listVlans, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListVlansResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListVlansResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListVlansResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListVlansResponse") + } + return +} + +// listVlans implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) listVlans(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/vlans", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListVlansResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ModifyVcnCidr Updates the specified CIDR block of a VCN. The new CIDR IP range must meet the following criteria: +// - Must be valid. +// - Must not overlap with another CIDR block in the VCN, a CIDR block of a peered VCN, or the on-premises network CIDR block. +// - Must not exceed the limit of CIDR blocks allowed per VCN. +// - Must include IP addresses from the original CIDR block that are used in the VCN's existing route rules. +// - No IP address in an existing subnet should be outside of the new CIDR block range. +// **Note:** Modifying a CIDR block places your VCN in an updating state until the changes are complete. You cannot create or update the VCN's subnets, VLANs, LPGs, or route tables during this operation. The time to completion can vary depending on the size of your network. Updating a small network could take about a minute, and updating a large network could take up to an hour. You can use the `GetWorkRequest` operation to check the status of the update. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ModifyVcnCidr.go.html to see an example of how to use ModifyVcnCidr API. +func (client VirtualNetworkClient) ModifyVcnCidr(ctx context.Context, request ModifyVcnCidrRequest) (response ModifyVcnCidrResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.modifyVcnCidr, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ModifyVcnCidrResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ModifyVcnCidrResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ModifyVcnCidrResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ModifyVcnCidrResponse") + } + return +} + +// modifyVcnCidr implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) modifyVcnCidr(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/vcns/{vcnId}/actions/modifyCidr", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ModifyVcnCidrResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// RemoveDrgRouteDistributionStatements Removes one or more route distribution statements from the specified route distribution's map. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemoveDrgRouteDistributionStatements.go.html to see an example of how to use RemoveDrgRouteDistributionStatements API. +func (client VirtualNetworkClient) RemoveDrgRouteDistributionStatements(ctx context.Context, request RemoveDrgRouteDistributionStatementsRequest) (response RemoveDrgRouteDistributionStatementsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.removeDrgRouteDistributionStatements, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = RemoveDrgRouteDistributionStatementsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = RemoveDrgRouteDistributionStatementsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(RemoveDrgRouteDistributionStatementsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into RemoveDrgRouteDistributionStatementsResponse") + } + return +} + +// removeDrgRouteDistributionStatements implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) removeDrgRouteDistributionStatements(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/drgRouteDistributions/{drgRouteDistributionId}/actions/removeDrgRouteDistributionStatements", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response RemoveDrgRouteDistributionStatementsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// RemoveDrgRouteRules Removes one or more route rules from the specified DRG route table. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemoveDrgRouteRules.go.html to see an example of how to use RemoveDrgRouteRules API. +func (client VirtualNetworkClient) RemoveDrgRouteRules(ctx context.Context, request RemoveDrgRouteRulesRequest) (response RemoveDrgRouteRulesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.removeDrgRouteRules, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = RemoveDrgRouteRulesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = RemoveDrgRouteRulesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(RemoveDrgRouteRulesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into RemoveDrgRouteRulesResponse") + } + return +} + +// removeDrgRouteRules implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) removeDrgRouteRules(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/drgRouteTables/{drgRouteTableId}/actions/removeDrgRouteRules", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response RemoveDrgRouteRulesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// RemoveExportDrgRouteDistribution Removes the export route distribution from the DRG attachment so no routes are advertised to it. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemoveExportDrgRouteDistribution.go.html to see an example of how to use RemoveExportDrgRouteDistribution API. +func (client VirtualNetworkClient) RemoveExportDrgRouteDistribution(ctx context.Context, request RemoveExportDrgRouteDistributionRequest) (response RemoveExportDrgRouteDistributionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.removeExportDrgRouteDistribution, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = RemoveExportDrgRouteDistributionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = RemoveExportDrgRouteDistributionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(RemoveExportDrgRouteDistributionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into RemoveExportDrgRouteDistributionResponse") + } + return +} + +// removeExportDrgRouteDistribution implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) removeExportDrgRouteDistribution(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/drgAttachments/{drgAttachmentId}/actions/removeExportDrgRouteDistribution", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response RemoveExportDrgRouteDistributionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// RemoveImportDrgRouteDistribution Removes the import route distribution from the DRG route table so no routes are imported +// into it. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemoveImportDrgRouteDistribution.go.html to see an example of how to use RemoveImportDrgRouteDistribution API. +func (client VirtualNetworkClient) RemoveImportDrgRouteDistribution(ctx context.Context, request RemoveImportDrgRouteDistributionRequest) (response RemoveImportDrgRouteDistributionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.removeImportDrgRouteDistribution, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = RemoveImportDrgRouteDistributionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = RemoveImportDrgRouteDistributionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(RemoveImportDrgRouteDistributionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into RemoveImportDrgRouteDistributionResponse") + } + return +} + +// removeImportDrgRouteDistribution implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) removeImportDrgRouteDistribution(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/drgRouteTables/{drgRouteTableId}/actions/removeImportDrgRouteDistribution", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response RemoveImportDrgRouteDistributionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// RemoveNetworkSecurityGroupSecurityRules Removes one or more security rules from the specified network security group. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemoveNetworkSecurityGroupSecurityRules.go.html to see an example of how to use RemoveNetworkSecurityGroupSecurityRules API. +func (client VirtualNetworkClient) RemoveNetworkSecurityGroupSecurityRules(ctx context.Context, request RemoveNetworkSecurityGroupSecurityRulesRequest) (response RemoveNetworkSecurityGroupSecurityRulesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.removeNetworkSecurityGroupSecurityRules, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = RemoveNetworkSecurityGroupSecurityRulesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = RemoveNetworkSecurityGroupSecurityRulesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(RemoveNetworkSecurityGroupSecurityRulesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into RemoveNetworkSecurityGroupSecurityRulesResponse") + } + return +} + +// removeNetworkSecurityGroupSecurityRules implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) removeNetworkSecurityGroupSecurityRules(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/networkSecurityGroups/{networkSecurityGroupId}/actions/removeSecurityRules", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response RemoveNetworkSecurityGroupSecurityRulesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// RemovePublicIpPoolCapacity Removes a CIDR block from the referenced public IP pool. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemovePublicIpPoolCapacity.go.html to see an example of how to use RemovePublicIpPoolCapacity API. +func (client VirtualNetworkClient) RemovePublicIpPoolCapacity(ctx context.Context, request RemovePublicIpPoolCapacityRequest) (response RemovePublicIpPoolCapacityResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.removePublicIpPoolCapacity, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = RemovePublicIpPoolCapacityResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = RemovePublicIpPoolCapacityResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(RemovePublicIpPoolCapacityResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into RemovePublicIpPoolCapacityResponse") + } + return +} + +// removePublicIpPoolCapacity implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) removePublicIpPoolCapacity(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/publicIpPools/{publicIpPoolId}/actions/removeCapacity", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response RemovePublicIpPoolCapacityResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// RemoveVcnCidr Removes a specified CIDR block from a VCN. +// **Notes:** +// - You cannot remove a CIDR block if an IP address in its range is in use. +// - Removing a CIDR block places your VCN in an updating state until the changes are complete. You cannot create or update the VCN's subnets, VLANs, LPGs, or route tables during this operation. The time to completion can take a few minutes. You can use the `GetWorkRequest` operation to check the status of the update. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemoveVcnCidr.go.html to see an example of how to use RemoveVcnCidr API. +func (client VirtualNetworkClient) RemoveVcnCidr(ctx context.Context, request RemoveVcnCidrRequest) (response RemoveVcnCidrResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.removeVcnCidr, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = RemoveVcnCidrResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = RemoveVcnCidrResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(RemoveVcnCidrResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into RemoveVcnCidrResponse") + } + return +} + +// removeVcnCidr implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) removeVcnCidr(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/vcns/{vcnId}/actions/removeCidr", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response RemoveVcnCidrResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateByoipRange Updates the tags or display name associated to the specified BYOIP CIDR block. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateByoipRange.go.html to see an example of how to use UpdateByoipRange API. +func (client VirtualNetworkClient) UpdateByoipRange(ctx context.Context, request UpdateByoipRangeRequest) (response UpdateByoipRangeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateByoipRange, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateByoipRangeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateByoipRangeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateByoipRangeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateByoipRangeResponse") + } + return +} + +// updateByoipRange implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateByoipRange(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/byoipRanges/{byoipRangeId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateByoipRangeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateCpe Updates the specified CPE's display name or tags. +// Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateCpe.go.html to see an example of how to use UpdateCpe API. +func (client VirtualNetworkClient) UpdateCpe(ctx context.Context, request UpdateCpeRequest) (response UpdateCpeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateCpe, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateCpeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateCpeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateCpeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateCpeResponse") + } + return +} + +// updateCpe implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateCpe(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/cpes/{cpeId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateCpeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateCrossConnect Updates the specified cross-connect. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateCrossConnect.go.html to see an example of how to use UpdateCrossConnect API. +func (client VirtualNetworkClient) UpdateCrossConnect(ctx context.Context, request UpdateCrossConnectRequest) (response UpdateCrossConnectResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateCrossConnect, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateCrossConnectResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateCrossConnectResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateCrossConnectResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateCrossConnectResponse") + } + return +} + +// updateCrossConnect implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateCrossConnect(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/crossConnects/{crossConnectId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateCrossConnectResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateCrossConnectGroup Updates the specified cross-connect group's display name. +// Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateCrossConnectGroup.go.html to see an example of how to use UpdateCrossConnectGroup API. +func (client VirtualNetworkClient) UpdateCrossConnectGroup(ctx context.Context, request UpdateCrossConnectGroupRequest) (response UpdateCrossConnectGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateCrossConnectGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateCrossConnectGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateCrossConnectGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateCrossConnectGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateCrossConnectGroupResponse") + } + return +} + +// updateCrossConnectGroup implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateCrossConnectGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/crossConnectGroups/{crossConnectGroupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateCrossConnectGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateDhcpOptions Updates the specified set of DHCP options. You can update the display name or the options +// themselves. Avoid entering confidential information. +// Note that the `options` object you provide replaces the entire existing set of options. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDhcpOptions.go.html to see an example of how to use UpdateDhcpOptions API. +func (client VirtualNetworkClient) UpdateDhcpOptions(ctx context.Context, request UpdateDhcpOptionsRequest) (response UpdateDhcpOptionsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateDhcpOptions, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateDhcpOptionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateDhcpOptionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateDhcpOptionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateDhcpOptionsResponse") + } + return +} + +// updateDhcpOptions implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateDhcpOptions(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/dhcps/{dhcpId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateDhcpOptionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateDrg Updates the specified DRG's display name or tags. Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDrg.go.html to see an example of how to use UpdateDrg API. +func (client VirtualNetworkClient) UpdateDrg(ctx context.Context, request UpdateDrgRequest) (response UpdateDrgResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateDrg, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateDrgResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateDrgResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateDrgResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateDrgResponse") + } + return +} + +// updateDrg implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateDrg(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/drgs/{drgId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateDrgResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateDrgAttachment Updates the display name and routing information for the specified `DrgAttachment`. +// Avoid entering confidential information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDrgAttachment.go.html to see an example of how to use UpdateDrgAttachment API. +func (client VirtualNetworkClient) UpdateDrgAttachment(ctx context.Context, request UpdateDrgAttachmentRequest) (response UpdateDrgAttachmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateDrgAttachment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateDrgAttachmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateDrgAttachmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateDrgAttachmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateDrgAttachmentResponse") + } + return +} + +// updateDrgAttachment implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateDrgAttachment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/drgAttachments/{drgAttachmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateDrgAttachmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateDrgRouteDistribution Updates the specified route distribution +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDrgRouteDistribution.go.html to see an example of how to use UpdateDrgRouteDistribution API. +func (client VirtualNetworkClient) UpdateDrgRouteDistribution(ctx context.Context, request UpdateDrgRouteDistributionRequest) (response UpdateDrgRouteDistributionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateDrgRouteDistribution, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateDrgRouteDistributionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateDrgRouteDistributionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateDrgRouteDistributionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateDrgRouteDistributionResponse") + } + return +} + +// updateDrgRouteDistribution implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateDrgRouteDistribution(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/drgRouteDistributions/{drgRouteDistributionId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateDrgRouteDistributionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateDrgRouteDistributionStatements Updates one or more route distribution statements in the specified route distribution. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDrgRouteDistributionStatements.go.html to see an example of how to use UpdateDrgRouteDistributionStatements API. +func (client VirtualNetworkClient) UpdateDrgRouteDistributionStatements(ctx context.Context, request UpdateDrgRouteDistributionStatementsRequest) (response UpdateDrgRouteDistributionStatementsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateDrgRouteDistributionStatements, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateDrgRouteDistributionStatementsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateDrgRouteDistributionStatementsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateDrgRouteDistributionStatementsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateDrgRouteDistributionStatementsResponse") + } + return +} + +// updateDrgRouteDistributionStatements implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateDrgRouteDistributionStatements(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/drgRouteDistributions/{drgRouteDistributionId}/actions/updateDrgRouteDistributionStatements", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateDrgRouteDistributionStatementsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateDrgRouteRules Updates one or more route rules in the specified DRG route table. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDrgRouteRules.go.html to see an example of how to use UpdateDrgRouteRules API. +func (client VirtualNetworkClient) UpdateDrgRouteRules(ctx context.Context, request UpdateDrgRouteRulesRequest) (response UpdateDrgRouteRulesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateDrgRouteRules, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateDrgRouteRulesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateDrgRouteRulesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateDrgRouteRulesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateDrgRouteRulesResponse") + } + return +} + +// updateDrgRouteRules implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateDrgRouteRules(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/drgRouteTables/{drgRouteTableId}/actions/updateDrgRouteRules", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateDrgRouteRulesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateDrgRouteTable Updates the specified DRG route table. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDrgRouteTable.go.html to see an example of how to use UpdateDrgRouteTable API. +func (client VirtualNetworkClient) UpdateDrgRouteTable(ctx context.Context, request UpdateDrgRouteTableRequest) (response UpdateDrgRouteTableResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateDrgRouteTable, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateDrgRouteTableResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateDrgRouteTableResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateDrgRouteTableResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateDrgRouteTableResponse") + } + return +} + +// updateDrgRouteTable implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateDrgRouteTable(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/drgRouteTables/{drgRouteTableId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateDrgRouteTableResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateIPSecConnection Updates the specified IPSec connection. +// To update an individual IPSec tunnel's attributes, use +// UpdateIPSecConnectionTunnel. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateIPSecConnection.go.html to see an example of how to use UpdateIPSecConnection API. +func (client VirtualNetworkClient) UpdateIPSecConnection(ctx context.Context, request UpdateIPSecConnectionRequest) (response UpdateIPSecConnectionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateIPSecConnection, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateIPSecConnectionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateIPSecConnectionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateIPSecConnectionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateIPSecConnectionResponse") + } + return +} + +// updateIPSecConnection implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateIPSecConnection(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/ipsecConnections/{ipscId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateIPSecConnectionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateIPSecConnectionTunnel Updates the specified tunnel. This operation lets you change tunnel attributes such as the +// routing type (BGP dynamic routing or static routing). Here are some important notes: +// * If you change the tunnel's routing type or BGP session configuration, the tunnel will go +// down while it's reprovisioned. +// * If you want to switch the tunnel's `routing` from `STATIC` to `BGP`, make sure the tunnel's +// BGP session configuration attributes have been set (BgpSessionInfo). +// * If you want to switch the tunnel's `routing` from `BGP` to `STATIC`, make sure the +// IPSecConnection already has at least one valid CIDR +// static route. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateIPSecConnectionTunnel.go.html to see an example of how to use UpdateIPSecConnectionTunnel API. +func (client VirtualNetworkClient) UpdateIPSecConnectionTunnel(ctx context.Context, request UpdateIPSecConnectionTunnelRequest) (response UpdateIPSecConnectionTunnelResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateIPSecConnectionTunnel, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateIPSecConnectionTunnelResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateIPSecConnectionTunnelResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateIPSecConnectionTunnelResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateIPSecConnectionTunnelResponse") + } + return +} + +// updateIPSecConnectionTunnel implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateIPSecConnectionTunnel(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/ipsecConnections/{ipscId}/tunnels/{tunnelId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateIPSecConnectionTunnelResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateIPSecConnectionTunnelSharedSecret Updates the shared secret (pre-shared key) for the specified tunnel. +// **Important:** If you change the shared secret, the tunnel will go down while it's reprovisioned. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateIPSecConnectionTunnelSharedSecret.go.html to see an example of how to use UpdateIPSecConnectionTunnelSharedSecret API. +func (client VirtualNetworkClient) UpdateIPSecConnectionTunnelSharedSecret(ctx context.Context, request UpdateIPSecConnectionTunnelSharedSecretRequest) (response UpdateIPSecConnectionTunnelSharedSecretResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateIPSecConnectionTunnelSharedSecret, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateIPSecConnectionTunnelSharedSecretResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateIPSecConnectionTunnelSharedSecretResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateIPSecConnectionTunnelSharedSecretResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateIPSecConnectionTunnelSharedSecretResponse") + } + return +} + +// updateIPSecConnectionTunnelSharedSecret implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateIPSecConnectionTunnelSharedSecret(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/ipsecConnections/{ipscId}/tunnels/{tunnelId}/sharedSecret", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateIPSecConnectionTunnelSharedSecretResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateInternetGateway Updates the specified internet gateway. You can disable/enable it, or change its display name +// or tags. Avoid entering confidential information. +// If the gateway is disabled, that means no traffic will flow to/from the internet even if there's +// a route rule that enables that traffic. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateInternetGateway.go.html to see an example of how to use UpdateInternetGateway API. +func (client VirtualNetworkClient) UpdateInternetGateway(ctx context.Context, request UpdateInternetGatewayRequest) (response UpdateInternetGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateInternetGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateInternetGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateInternetGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateInternetGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateInternetGatewayResponse") + } + return +} + +// updateInternetGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateInternetGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/internetGateways/{igId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateInternetGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateIpv6 Updates the specified IPv6. You must specify the object's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// Use this operation if you want to: +// * Move an IPv6 to a different VNIC in the same subnet. +// * Enable/disable internet access for an IPv6. +// * Change the display name for an IPv6. +// * Update resource tags for an IPv6. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateIpv6.go.html to see an example of how to use UpdateIpv6 API. +func (client VirtualNetworkClient) UpdateIpv6(ctx context.Context, request UpdateIpv6Request) (response UpdateIpv6Response, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateIpv6, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateIpv6Response{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateIpv6Response{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateIpv6Response); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateIpv6Response") + } + return +} + +// updateIpv6 implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateIpv6(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/ipv6/{ipv6Id}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateIpv6Response + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateLocalPeeringGateway Updates the specified local peering gateway (LPG). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateLocalPeeringGateway.go.html to see an example of how to use UpdateLocalPeeringGateway API. +func (client VirtualNetworkClient) UpdateLocalPeeringGateway(ctx context.Context, request UpdateLocalPeeringGatewayRequest) (response UpdateLocalPeeringGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateLocalPeeringGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateLocalPeeringGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateLocalPeeringGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateLocalPeeringGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateLocalPeeringGatewayResponse") + } + return +} + +// updateLocalPeeringGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateLocalPeeringGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/localPeeringGateways/{localPeeringGatewayId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateLocalPeeringGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateNatGateway Updates the specified NAT gateway. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateNatGateway.go.html to see an example of how to use UpdateNatGateway API. +func (client VirtualNetworkClient) UpdateNatGateway(ctx context.Context, request UpdateNatGatewayRequest) (response UpdateNatGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateNatGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateNatGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateNatGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateNatGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateNatGatewayResponse") + } + return +} + +// updateNatGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateNatGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/natGateways/{natGatewayId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateNatGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateNetworkSecurityGroup Updates the specified network security group. +// To add or remove an existing VNIC from the group, use +// UpdateVnic. +// To add a VNIC to the group *when you create the VNIC*, specify the NSG's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) during creation. +// For example, see the `nsgIds` attribute in CreateVnicDetails. +// To add or remove security rules from the group, use +// AddNetworkSecurityGroupSecurityRules +// or +// RemoveNetworkSecurityGroupSecurityRules. +// To edit the contents of existing security rules in the group, use +// UpdateNetworkSecurityGroupSecurityRules. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateNetworkSecurityGroup.go.html to see an example of how to use UpdateNetworkSecurityGroup API. +func (client VirtualNetworkClient) UpdateNetworkSecurityGroup(ctx context.Context, request UpdateNetworkSecurityGroupRequest) (response UpdateNetworkSecurityGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateNetworkSecurityGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateNetworkSecurityGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateNetworkSecurityGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateNetworkSecurityGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateNetworkSecurityGroupResponse") + } + return +} + +// updateNetworkSecurityGroup implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateNetworkSecurityGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/networkSecurityGroups/{networkSecurityGroupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateNetworkSecurityGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateNetworkSecurityGroupSecurityRules Updates one or more security rules in the specified network security group. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateNetworkSecurityGroupSecurityRules.go.html to see an example of how to use UpdateNetworkSecurityGroupSecurityRules API. +func (client VirtualNetworkClient) UpdateNetworkSecurityGroupSecurityRules(ctx context.Context, request UpdateNetworkSecurityGroupSecurityRulesRequest) (response UpdateNetworkSecurityGroupSecurityRulesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateNetworkSecurityGroupSecurityRules, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateNetworkSecurityGroupSecurityRulesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateNetworkSecurityGroupSecurityRulesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateNetworkSecurityGroupSecurityRulesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateNetworkSecurityGroupSecurityRulesResponse") + } + return +} + +// updateNetworkSecurityGroupSecurityRules implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateNetworkSecurityGroupSecurityRules(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/networkSecurityGroups/{networkSecurityGroupId}/actions/updateSecurityRules", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateNetworkSecurityGroupSecurityRulesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdatePrivateIp Updates the specified private IP. You must specify the object's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). +// Use this operation if you want to: +// - Move a secondary private IP to a different VNIC in the same subnet. +// - Change the display name for a secondary private IP. +// - Change the hostname for a secondary private IP. +// This operation cannot be used with primary private IPs. +// To update the hostname for the primary IP on a VNIC, use +// UpdateVnic. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdatePrivateIp.go.html to see an example of how to use UpdatePrivateIp API. +func (client VirtualNetworkClient) UpdatePrivateIp(ctx context.Context, request UpdatePrivateIpRequest) (response UpdatePrivateIpResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updatePrivateIp, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdatePrivateIpResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdatePrivateIpResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdatePrivateIpResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdatePrivateIpResponse") + } + return +} + +// updatePrivateIp implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updatePrivateIp(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/privateIps/{privateIpId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdatePrivateIpResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdatePublicIp Updates the specified public IP. You must specify the object's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). Use this operation if you want to: +// * Assign a reserved public IP in your pool to a private IP. +// * Move a reserved public IP to a different private IP. +// * Unassign a reserved public IP from a private IP (which returns it to your pool +// of reserved public IPs). +// * Change the display name or tags for a public IP. +// Assigning, moving, and unassigning a reserved public IP are asynchronous +// operations. Poll the public IP's `lifecycleState` to determine if the operation +// succeeded. +// **Note:** When moving a reserved public IP, the target private IP +// must not already have a public IP with `lifecycleState` = ASSIGNING or ASSIGNED. If it +// does, an error is returned. Also, the initial unassignment from the original +// private IP always succeeds, but the assignment to the target private IP is asynchronous and +// could fail silently (for example, if the target private IP is deleted or has a different public IP +// assigned to it in the interim). If that occurs, the public IP remains unassigned and its +// `lifecycleState` switches to AVAILABLE (it is not reassigned to its original private IP). +// You must poll the public IP's `lifecycleState` to determine if the move succeeded. +// Regarding ephemeral public IPs: +// * If you want to assign an ephemeral public IP to a primary private IP, use +// CreatePublicIp. +// * You can't move an ephemeral public IP to a different private IP. +// * If you want to unassign an ephemeral public IP from its private IP, use +// DeletePublicIp, which +// unassigns and deletes the ephemeral public IP. +// **Note:** If a public IP is assigned to a secondary private +// IP (see PrivateIp), and you move that secondary +// private IP to another VNIC, the public IP moves with it. +// **Note:** There's a limit to the number of PublicIp +// a VNIC or instance can have. If you try to move a reserved public IP +// to a VNIC or instance that has already reached its public IP limit, an error is +// returned. For information about the public IP limits, see +// Public IP Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingpublicIPs.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdatePublicIp.go.html to see an example of how to use UpdatePublicIp API. +func (client VirtualNetworkClient) UpdatePublicIp(ctx context.Context, request UpdatePublicIpRequest) (response UpdatePublicIpResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updatePublicIp, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdatePublicIpResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdatePublicIpResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdatePublicIpResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdatePublicIpResponse") + } + return +} + +// updatePublicIp implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updatePublicIp(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/publicIps/{publicIpId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdatePublicIpResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdatePublicIpPool Updates the specified public IP pool. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdatePublicIpPool.go.html to see an example of how to use UpdatePublicIpPool API. +func (client VirtualNetworkClient) UpdatePublicIpPool(ctx context.Context, request UpdatePublicIpPoolRequest) (response UpdatePublicIpPoolResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updatePublicIpPool, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdatePublicIpPoolResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdatePublicIpPoolResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdatePublicIpPoolResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdatePublicIpPoolResponse") + } + return +} + +// updatePublicIpPool implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updatePublicIpPool(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/publicIpPools/{publicIpPoolId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdatePublicIpPoolResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateRemotePeeringConnection Updates the specified remote peering connection (RPC). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateRemotePeeringConnection.go.html to see an example of how to use UpdateRemotePeeringConnection API. +func (client VirtualNetworkClient) UpdateRemotePeeringConnection(ctx context.Context, request UpdateRemotePeeringConnectionRequest) (response UpdateRemotePeeringConnectionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateRemotePeeringConnection, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateRemotePeeringConnectionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateRemotePeeringConnectionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateRemotePeeringConnectionResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateRemotePeeringConnectionResponse") + } + return +} + +// updateRemotePeeringConnection implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateRemotePeeringConnection(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/remotePeeringConnections/{remotePeeringConnectionId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateRemotePeeringConnectionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateRouteTable Updates the specified route table's display name or route rules. +// Avoid entering confidential information. +// Note that the `routeRules` object you provide replaces the entire existing set of rules. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateRouteTable.go.html to see an example of how to use UpdateRouteTable API. +func (client VirtualNetworkClient) UpdateRouteTable(ctx context.Context, request UpdateRouteTableRequest) (response UpdateRouteTableResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateRouteTable, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateRouteTableResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateRouteTableResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateRouteTableResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateRouteTableResponse") + } + return +} + +// updateRouteTable implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateRouteTable(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/routeTables/{rtId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateRouteTableResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateSecurityList Updates the specified security list's display name or rules. +// Avoid entering confidential information. +// Note that the `egressSecurityRules` or `ingressSecurityRules` objects you provide replace the entire +// existing objects. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateSecurityList.go.html to see an example of how to use UpdateSecurityList API. +func (client VirtualNetworkClient) UpdateSecurityList(ctx context.Context, request UpdateSecurityListRequest) (response UpdateSecurityListResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateSecurityList, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateSecurityListResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateSecurityListResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateSecurityListResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateSecurityListResponse") + } + return +} + +// updateSecurityList implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateSecurityList(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/securityLists/{securityListId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateSecurityListResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateServiceGateway Updates the specified service gateway. The information you provide overwrites the existing +// attributes of the gateway. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateServiceGateway.go.html to see an example of how to use UpdateServiceGateway API. +func (client VirtualNetworkClient) UpdateServiceGateway(ctx context.Context, request UpdateServiceGatewayRequest) (response UpdateServiceGatewayResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateServiceGateway, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateServiceGatewayResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateServiceGatewayResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateServiceGatewayResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateServiceGatewayResponse") + } + return +} + +// updateServiceGateway implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateServiceGateway(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/serviceGateways/{serviceGatewayId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateServiceGatewayResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateSubnet Updates the specified subnet. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateSubnet.go.html to see an example of how to use UpdateSubnet API. +func (client VirtualNetworkClient) UpdateSubnet(ctx context.Context, request UpdateSubnetRequest) (response UpdateSubnetResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateSubnet, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateSubnetResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateSubnetResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateSubnetResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateSubnetResponse") + } + return +} + +// updateSubnet implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateSubnet(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/subnets/{subnetId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateSubnetResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateTunnelCpeDeviceConfig Creates or updates the set of CPE configuration answers for the specified tunnel. +// The answers correlate to the questions that are specific to the CPE device type (see the +// `parameters` attribute of CpeDeviceShapeDetail). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateTunnelCpeDeviceConfig.go.html to see an example of how to use UpdateTunnelCpeDeviceConfig API. +func (client VirtualNetworkClient) UpdateTunnelCpeDeviceConfig(ctx context.Context, request UpdateTunnelCpeDeviceConfigRequest) (response UpdateTunnelCpeDeviceConfigResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.updateTunnelCpeDeviceConfig, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateTunnelCpeDeviceConfigResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateTunnelCpeDeviceConfigResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateTunnelCpeDeviceConfigResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateTunnelCpeDeviceConfigResponse") + } + return +} + +// updateTunnelCpeDeviceConfig implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateTunnelCpeDeviceConfig(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/ipsecConnections/{ipscId}/tunnels/{tunnelId}/tunnelDeviceConfig", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateTunnelCpeDeviceConfigResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateVcn Updates the specified VCN. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVcn.go.html to see an example of how to use UpdateVcn API. +func (client VirtualNetworkClient) UpdateVcn(ctx context.Context, request UpdateVcnRequest) (response UpdateVcnResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateVcn, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateVcnResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateVcnResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateVcnResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateVcnResponse") + } + return +} + +// updateVcn implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateVcn(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/vcns/{vcnId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateVcnResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateVirtualCircuit Updates the specified virtual circuit. This can be called by +// either the customer who owns the virtual circuit, or the +// provider (when provisioning or de-provisioning the virtual +// circuit from their end). The documentation for +// UpdateVirtualCircuitDetails +// indicates who can update each property of the virtual circuit. +// **Important:** If the virtual circuit is working and in the +// PROVISIONED state, updating any of the network-related properties +// (such as the DRG being used, the BGP ASN, and so on) will cause the virtual +// circuit's state to switch to PROVISIONING and the related BGP +// session to go down. After Oracle re-provisions the virtual circuit, +// its state will return to PROVISIONED. Make sure you confirm that +// the associated BGP session is back up. For more information +// about the various states and how to test connectivity, see +// FastConnect Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/fastconnect.htm). +// To change the list of public IP prefixes for a public virtual circuit, +// use BulkAddVirtualCircuitPublicPrefixes +// and +// BulkDeleteVirtualCircuitPublicPrefixes. +// Updating the list of prefixes does NOT cause the BGP session to go down. However, +// Oracle must verify the customer's ownership of each added prefix before +// traffic for that prefix will flow across the virtual circuit. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVirtualCircuit.go.html to see an example of how to use UpdateVirtualCircuit API. +func (client VirtualNetworkClient) UpdateVirtualCircuit(ctx context.Context, request UpdateVirtualCircuitRequest) (response UpdateVirtualCircuitResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateVirtualCircuit, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateVirtualCircuitResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateVirtualCircuitResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateVirtualCircuitResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateVirtualCircuitResponse") + } + return +} + +// updateVirtualCircuit implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateVirtualCircuit(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/virtualCircuits/{virtualCircuitId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateVirtualCircuitResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateVlan Updates the specified VLAN. Note that this operation might require changes to all +// the VNICs in the VLAN, which can take a while. The VLAN will be in the UPDATING state until the changes are complete. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVlan.go.html to see an example of how to use UpdateVlan API. +func (client VirtualNetworkClient) UpdateVlan(ctx context.Context, request UpdateVlanRequest) (response UpdateVlanResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateVlan, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateVlanResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateVlanResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateVlanResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateVlanResponse") + } + return +} + +// updateVlan implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateVlan(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/vlans/{vlanId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateVlanResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateVnic Updates the specified VNIC. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVnic.go.html to see an example of how to use UpdateVnic API. +func (client VirtualNetworkClient) UpdateVnic(ctx context.Context, request UpdateVnicRequest) (response UpdateVnicResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateVnic, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateVnicResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateVnicResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateVnicResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateVnicResponse") + } + return +} + +// updateVnic implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) updateVnic(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/vnics/{vnicId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateVnicResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpgradeDrg Upgrades the DRG. After upgrade, you can control routing inside your DRG +// via DRG attachments, route distributions, and DRG route tables. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpgradeDrg.go.html to see an example of how to use UpgradeDrg API. +func (client VirtualNetworkClient) UpgradeDrg(ctx context.Context, request UpgradeDrgRequest) (response UpgradeDrgResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.upgradeDrg, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpgradeDrgResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpgradeDrgResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpgradeDrgResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpgradeDrgResponse") + } + return +} + +// upgradeDrg implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) upgradeDrg(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/drgs/{drgId}/actions/upgrade", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpgradeDrgResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ValidateByoipRange Submits the BYOIP CIDR block you are importing for validation. Do not submit to Oracle for validation if you have not already +// modified the information for the BYOIP CIDR block with your Regional Internet Registry. See To import a CIDR block (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/BYOIP.htm#import_cidr) for details. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ValidateByoipRange.go.html to see an example of how to use ValidateByoipRange API. +func (client VirtualNetworkClient) ValidateByoipRange(ctx context.Context, request ValidateByoipRangeRequest) (response ValidateByoipRangeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.validateByoipRange, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ValidateByoipRangeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ValidateByoipRangeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ValidateByoipRangeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ValidateByoipRangeResponse") + } + return +} + +// validateByoipRange implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) validateByoipRange(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/byoipRanges/{byoipRangeId}/actions/validate", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ValidateByoipRangeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// WithdrawByoipRange Withdraws BGP route advertisement for the BYOIP CIDR block. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/WithdrawByoipRange.go.html to see an example of how to use WithdrawByoipRange API. +func (client VirtualNetworkClient) WithdrawByoipRange(ctx context.Context, request WithdrawByoipRangeRequest) (response WithdrawByoipRangeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.withdrawByoipRange, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = WithdrawByoipRangeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = WithdrawByoipRangeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(WithdrawByoipRangeResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into WithdrawByoipRangeResponse") + } + return +} + +// withdrawByoipRange implements the OCIOperation interface (enables retrying operations) +func (client VirtualNetworkClient) withdrawByoipRange(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/byoipRanges/{byoipRangeId}/actions/withdraw", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response WithdrawByoipRangeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe.go new file mode 100644 index 000000000..25ec49a18 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Cpe An object you create when setting up a Site-to-Site VPN between your on-premises network +// and VCN. The `Cpe` is a virtual representation of your customer-premises equipment, +// which is the actual router on-premises at your site at your end of the Site-to-Site VPN IPSec connection. +// For more information, +// see Overview of the Networking Service (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type Cpe struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the CPE. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The CPE's Oracle ID (OCID). + Id *string `mandatory:"true" json:"id"` + + // The public IP address of the on-premises router. + IpAddress *string `mandatory:"true" json:"ipAddress"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the CPE's device type. + // The Networking service maintains a general list of CPE device types (for example, + // Cisco ASA). For each type, Oracle provides CPE configuration content that can help + // a network engineer configure the CPE. The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) uniquely identifies the type of + // device. To get the OCIDs for the device types on the list, see + // ListCpeDeviceShapes. + // For information about how to generate CPE configuration content for a + // CPE device type, see: + // * GetCpeDeviceConfigContent + // * GetIpsecCpeDeviceConfigContent + // * GetTunnelCpeDeviceConfigContent + // * GetTunnelCpeDeviceConfig + CpeDeviceShapeId *string `mandatory:"false" json:"cpeDeviceShapeId"` + + // The date and time the CPE was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` +} + +func (m Cpe) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_config_answer.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_config_answer.go new file mode 100644 index 000000000..23c554956 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_config_answer.go @@ -0,0 +1,35 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CpeDeviceConfigAnswer An individual answer to a CPE device question. +// The answers correlate to the questions that are specific to the CPE device type (see the +// `parameters` attribute of CpeDeviceShapeDetail). +type CpeDeviceConfigAnswer struct { + + // A string that identifies the question to be answered. See the `key` attribute in + // CpeDeviceConfigQuestion. + Key *string `mandatory:"false" json:"key"` + + // The answer to the question. + Value *string `mandatory:"false" json:"value"` +} + +func (m CpeDeviceConfigAnswer) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_config_question.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_config_question.go new file mode 100644 index 000000000..1bbe93388 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_config_question.go @@ -0,0 +1,38 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CpeDeviceConfigQuestion An individual question that the customer can answer about the CPE device. +// The customer provides answers to these questions in +// UpdateTunnelCpeDeviceConfig. +type CpeDeviceConfigQuestion struct { + + // A string that identifies the question. + Key *string `mandatory:"false" json:"key"` + + // A descriptive label for the question (for example, to display in a form in a graphical interface). + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // A description or explanation of the question, to help the customer answer accurately. + Explanation *string `mandatory:"false" json:"explanation"` +} + +func (m CpeDeviceConfigQuestion) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_info.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_info.go new file mode 100644 index 000000000..b7dd2ccfe --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_info.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CpeDeviceInfo Basic information about a particular CPE device type. +type CpeDeviceInfo struct { + + // The vendor that makes the CPE device. + Vendor *string `mandatory:"false" json:"vendor"` + + // The platform or software version of the CPE device. + PlatformSoftwareVersion *string `mandatory:"false" json:"platformSoftwareVersion"` +} + +func (m CpeDeviceInfo) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_shape_detail.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_shape_detail.go new file mode 100644 index 000000000..312d3013b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_shape_detail.go @@ -0,0 +1,48 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CpeDeviceShapeDetail The detailed information about a particular CPE device type. Compare with +// CpeDeviceShapeSummary. +type CpeDeviceShapeDetail struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the CPE device shape. + // This value uniquely identifies the type of CPE device. + CpeDeviceShapeId *string `mandatory:"false" json:"cpeDeviceShapeId"` + + CpeDeviceInfo *CpeDeviceInfo `mandatory:"false" json:"cpeDeviceInfo"` + + // For certain CPE devices types, the customer can provide answers to + // questions that are specific to the device type. This attribute contains + // a list of those questions. The Networking service merges the answers with + // other information and renders a set of CPE configuration content. To + // provide the answers, use + // UpdateTunnelCpeDeviceConfig. + Parameters []CpeDeviceConfigQuestion `mandatory:"false" json:"parameters"` + + // A template of CPE device configuration information that will be merged with the customer's + // answers to the questions to render the final CPE device configuration content. Also see: + // * GetCpeDeviceConfigContent + // * GetIpsecCpeDeviceConfigContent + // * GetTunnelCpeDeviceConfigContent + Template *string `mandatory:"false" json:"template"` +} + +func (m CpeDeviceShapeDetail) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_shape_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_shape_summary.go new file mode 100644 index 000000000..cf749f729 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cpe_device_shape_summary.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CpeDeviceShapeSummary A summary of information about a particular CPE device type. Compare with +// CpeDeviceShapeDetail. +type CpeDeviceShapeSummary struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the CPE device shape. + // This value uniquely identifies the type of CPE device. + Id *string `mandatory:"false" json:"id"` + + CpeDeviceInfo *CpeDeviceInfo `mandatory:"false" json:"cpeDeviceInfo"` +} + +func (m CpeDeviceShapeSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_app_catalog_subscription_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_app_catalog_subscription_details.go new file mode 100644 index 000000000..45a097a3a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_app_catalog_subscription_details.go @@ -0,0 +1,48 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateAppCatalogSubscriptionDetails details for creating a subscription for a listing resource version. +type CreateAppCatalogSubscriptionDetails struct { + + // The compartmentID for the subscription. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the listing. + ListingId *string `mandatory:"true" json:"listingId"` + + // Listing resource version. + ListingResourceVersion *string `mandatory:"true" json:"listingResourceVersion"` + + // Oracle TOU link + OracleTermsOfUseLink *string `mandatory:"true" json:"oracleTermsOfUseLink"` + + // Date and time the agreements were retrieved, in RFC3339 (https://tools.ietf.org/html/rfc3339) format. + // Example: `2018-03-20T12:32:53.532Z` + TimeRetrieved *common.SDKTime `mandatory:"true" json:"timeRetrieved"` + + // A generated signature for this listing resource version retrieved the agreements API. + Signature *string `mandatory:"true" json:"signature"` + + // EULA link + EulaLink *string `mandatory:"false" json:"eulaLink"` +} + +func (m CreateAppCatalogSubscriptionDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_app_catalog_subscription_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_app_catalog_subscription_request_response.go new file mode 100644 index 000000000..3e44b73e9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_app_catalog_subscription_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateAppCatalogSubscriptionRequest wrapper for the CreateAppCatalogSubscription operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateAppCatalogSubscription.go.html to see an example of how to use CreateAppCatalogSubscriptionRequest. +type CreateAppCatalogSubscriptionRequest struct { + + // Request for the creation of a subscription for listing resource version for a compartment. + CreateAppCatalogSubscriptionDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateAppCatalogSubscriptionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateAppCatalogSubscriptionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateAppCatalogSubscriptionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateAppCatalogSubscriptionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateAppCatalogSubscriptionResponse wrapper for the CreateAppCatalogSubscription operation +type CreateAppCatalogSubscriptionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The AppCatalogSubscription instance + AppCatalogSubscription `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateAppCatalogSubscriptionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateAppCatalogSubscriptionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_backup_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_backup_details.go new file mode 100644 index 000000000..c9af3d487 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_backup_details.go @@ -0,0 +1,69 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateBootVolumeBackupDetails The representation of CreateBootVolumeBackupDetails +type CreateBootVolumeBackupDetails struct { + + // The OCID of the boot volume that needs to be backed up. + BootVolumeId *string `mandatory:"true" json:"bootVolumeId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The type of backup to create. If omitted, defaults to incremental. + Type CreateBootVolumeBackupDetailsTypeEnum `mandatory:"false" json:"type,omitempty"` +} + +func (m CreateBootVolumeBackupDetails) String() string { + return common.PointerString(m) +} + +// CreateBootVolumeBackupDetailsTypeEnum Enum with underlying type: string +type CreateBootVolumeBackupDetailsTypeEnum string + +// Set of constants representing the allowable values for CreateBootVolumeBackupDetailsTypeEnum +const ( + CreateBootVolumeBackupDetailsTypeFull CreateBootVolumeBackupDetailsTypeEnum = "FULL" + CreateBootVolumeBackupDetailsTypeIncremental CreateBootVolumeBackupDetailsTypeEnum = "INCREMENTAL" +) + +var mappingCreateBootVolumeBackupDetailsType = map[string]CreateBootVolumeBackupDetailsTypeEnum{ + "FULL": CreateBootVolumeBackupDetailsTypeFull, + "INCREMENTAL": CreateBootVolumeBackupDetailsTypeIncremental, +} + +// GetCreateBootVolumeBackupDetailsTypeEnumValues Enumerates the set of values for CreateBootVolumeBackupDetailsTypeEnum +func GetCreateBootVolumeBackupDetailsTypeEnumValues() []CreateBootVolumeBackupDetailsTypeEnum { + values := make([]CreateBootVolumeBackupDetailsTypeEnum, 0) + for _, v := range mappingCreateBootVolumeBackupDetailsType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_backup_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_backup_request_response.go new file mode 100644 index 000000000..54e628875 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_backup_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateBootVolumeBackupRequest wrapper for the CreateBootVolumeBackup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateBootVolumeBackup.go.html to see an example of how to use CreateBootVolumeBackupRequest. +type CreateBootVolumeBackupRequest struct { + + // Request to create a new backup of given boot volume. + CreateBootVolumeBackupDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateBootVolumeBackupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateBootVolumeBackupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateBootVolumeBackupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateBootVolumeBackupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateBootVolumeBackupResponse wrapper for the CreateBootVolumeBackup operation +type CreateBootVolumeBackupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The BootVolumeBackup instance + BootVolumeBackup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateBootVolumeBackupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateBootVolumeBackupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_details.go new file mode 100644 index 000000000..264697e49 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_details.go @@ -0,0 +1,136 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateBootVolumeDetails The representation of CreateBootVolumeDetails +type CreateBootVolumeDetails struct { + + // The OCID of the compartment that contains the boot volume. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + SourceDetails BootVolumeSourceDetails `mandatory:"true" json:"sourceDetails"` + + // The availability domain of the volume. Omissible for cloning a volume. The new volume will be created in the availability domain of the source volume. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" json:"availabilityDomain"` + + // If provided, specifies the ID of the boot volume backup policy to assign to the newly + // created boot volume. If omitted, no policy will be assigned. + BackupPolicyId *string `mandatory:"false" json:"backupPolicyId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID of the Key Management key to assign as the master encryption key + // for the boot volume. + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` + + // The size of the volume in GBs. + SizeInGBs *int64 `mandatory:"false" json:"sizeInGBs"` + + // The number of volume performance units (VPUs) that will be applied to this volume per GB, + // representing the Block Volume service's elastic performance options. + // See Block Volume Elastic Performance (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/blockvolumeelasticperformance.htm) for more information. + // Allowed values: + // * `10`: Represents Balanced option. + // * `20`: Represents Higher Performance option. + VpusPerGB *int64 `mandatory:"false" json:"vpusPerGB"` + + // Specifies whether the auto-tune performance is enabled for this boot volume. + IsAutoTuneEnabled *bool `mandatory:"false" json:"isAutoTuneEnabled"` + + // The list of boot volume replicas to be enabled for this boot volume + // in the specified destination availability domains. + BootVolumeReplicas []BootVolumeReplicaDetails `mandatory:"false" json:"bootVolumeReplicas"` +} + +func (m CreateBootVolumeDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *CreateBootVolumeDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + AvailabilityDomain *string `json:"availabilityDomain"` + BackupPolicyId *string `json:"backupPolicyId"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + DisplayName *string `json:"displayName"` + FreeformTags map[string]string `json:"freeformTags"` + KmsKeyId *string `json:"kmsKeyId"` + SizeInGBs *int64 `json:"sizeInGBs"` + VpusPerGB *int64 `json:"vpusPerGB"` + IsAutoTuneEnabled *bool `json:"isAutoTuneEnabled"` + BootVolumeReplicas []BootVolumeReplicaDetails `json:"bootVolumeReplicas"` + CompartmentId *string `json:"compartmentId"` + SourceDetails bootvolumesourcedetails `json:"sourceDetails"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.AvailabilityDomain = model.AvailabilityDomain + + m.BackupPolicyId = model.BackupPolicyId + + m.DefinedTags = model.DefinedTags + + m.DisplayName = model.DisplayName + + m.FreeformTags = model.FreeformTags + + m.KmsKeyId = model.KmsKeyId + + m.SizeInGBs = model.SizeInGBs + + m.VpusPerGB = model.VpusPerGB + + m.IsAutoTuneEnabled = model.IsAutoTuneEnabled + + m.BootVolumeReplicas = make([]BootVolumeReplicaDetails, len(model.BootVolumeReplicas)) + for i, n := range model.BootVolumeReplicas { + m.BootVolumeReplicas[i] = n + } + + m.CompartmentId = model.CompartmentId + + nn, e = model.SourceDetails.UnmarshalPolymorphicJSON(model.SourceDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.SourceDetails = nn.(BootVolumeSourceDetails) + } else { + m.SourceDetails = nil + } + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_request_response.go new file mode 100644 index 000000000..8b6f97cc2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_boot_volume_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateBootVolumeRequest wrapper for the CreateBootVolume operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateBootVolume.go.html to see an example of how to use CreateBootVolumeRequest. +type CreateBootVolumeRequest struct { + + // Request to create a new boot volume. + CreateBootVolumeDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateBootVolumeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateBootVolumeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateBootVolumeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateBootVolumeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateBootVolumeResponse wrapper for the CreateBootVolume operation +type CreateBootVolumeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The BootVolume instance + BootVolume `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateBootVolumeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateBootVolumeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_byoip_range_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_byoip_range_details.go new file mode 100644 index 000000000..f9bc28fb0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_byoip_range_details.go @@ -0,0 +1,47 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateByoipRangeDetails The information used to create a `ByoipRange` resource. +type CreateByoipRangeDetails struct { + + // The BYOIP CIDR block. You can assign some or all of it to a public IP pool after it is validated. + // Example: `10.0.1.0/24` + CidrBlock *string `mandatory:"true" json:"cidrBlock"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the BYOIP CIDR block. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CreateByoipRangeDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_byoip_range_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_byoip_range_request_response.go new file mode 100644 index 000000000..bf0fd0902 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_byoip_range_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateByoipRangeRequest wrapper for the CreateByoipRange operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateByoipRange.go.html to see an example of how to use CreateByoipRangeRequest. +type CreateByoipRangeRequest struct { + + // Details needed to create a BYOIP CIDR block subrange. + CreateByoipRangeDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateByoipRangeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateByoipRangeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateByoipRangeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateByoipRangeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateByoipRangeResponse wrapper for the CreateByoipRange operation +type CreateByoipRangeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ByoipRange instance + ByoipRange `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateByoipRangeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateByoipRangeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cluster_network_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cluster_network_details.go new file mode 100644 index 000000000..3d98871bd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cluster_network_details.go @@ -0,0 +1,50 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateClusterNetworkDetails The data to create a cluster network. +type CreateClusterNetworkDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment + // containing the cluster network. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The data to create the instance pools in the cluster network. + // Each cluster network can have one instance pool. + InstancePools []CreateClusterNetworkInstancePoolDetails `mandatory:"true" json:"instancePools"` + + PlacementConfiguration *ClusterNetworkPlacementConfigurationDetails `mandatory:"true" json:"placementConfiguration"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CreateClusterNetworkDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cluster_network_instance_pool_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cluster_network_instance_pool_details.go new file mode 100644 index 000000000..17d9d17f0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cluster_network_instance_pool_details.go @@ -0,0 +1,47 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateClusterNetworkInstancePoolDetails The data to create an instance pool in a cluster network. +type CreateClusterNetworkInstancePoolDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance configuration + // associated with the instance pool. + InstanceConfigurationId *string `mandatory:"true" json:"instanceConfigurationId"` + + // The number of instances that should be in the instance pool. + Size *int `mandatory:"true" json:"size"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CreateClusterNetworkInstancePoolDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cluster_network_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cluster_network_request_response.go new file mode 100644 index 000000000..d59509f96 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cluster_network_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateClusterNetworkRequest wrapper for the CreateClusterNetwork operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateClusterNetwork.go.html to see an example of how to use CreateClusterNetworkRequest. +type CreateClusterNetworkRequest struct { + + // Cluster network creation details + CreateClusterNetworkDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateClusterNetworkRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateClusterNetworkRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateClusterNetworkRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateClusterNetworkRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateClusterNetworkResponse wrapper for the CreateClusterNetwork operation +type CreateClusterNetworkResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ClusterNetwork instance + ClusterNetwork `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response CreateClusterNetworkResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateClusterNetworkResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_capacity_reservation_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_capacity_reservation_details.go new file mode 100644 index 000000000..e2d55422f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_capacity_reservation_details.go @@ -0,0 +1,56 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateComputeCapacityReservationDetails The details for creating a new compute capacity reservation. +type CreateComputeCapacityReservationDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the capacity reservation. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The availability domain of this compute capacity reservation. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Whether this capacity reservation is the default. + // For more information, see Capacity Reservations (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/reserve-capacity.htm#default). + IsDefaultReservation *bool `mandatory:"false" json:"isDefaultReservation"` + + // The capacity configurations for the capacity reservation. + // To use the reservation for the desired shape, specify the shape, count, and + // optionally the fault domain where you want this configuration. + InstanceReservationConfigs []InstanceReservationConfigDetails `mandatory:"false" json:"instanceReservationConfigs"` +} + +func (m CreateComputeCapacityReservationDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_capacity_reservation_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_capacity_reservation_request_response.go new file mode 100644 index 000000000..8a6541e8f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_capacity_reservation_request_response.go @@ -0,0 +1,92 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateComputeCapacityReservationRequest wrapper for the CreateComputeCapacityReservation operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateComputeCapacityReservation.go.html to see an example of how to use CreateComputeCapacityReservationRequest. +type CreateComputeCapacityReservationRequest struct { + + // Details for creating a new compute capacity reservation. + // **Caution:** Avoid using any confidential information when you use the API to supply string values. + CreateComputeCapacityReservationDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateComputeCapacityReservationRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateComputeCapacityReservationRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateComputeCapacityReservationRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateComputeCapacityReservationRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateComputeCapacityReservationResponse wrapper for the CreateComputeCapacityReservation operation +type CreateComputeCapacityReservationResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ComputeCapacityReservation instance + ComputeCapacityReservation `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` + + // Location of the resource. + Location *string `presentIn:"header" name:"location"` +} + +func (response CreateComputeCapacityReservationResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateComputeCapacityReservationResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_image_capability_schema_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_image_capability_schema_details.go new file mode 100644 index 000000000..40d857b6c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_image_capability_schema_details.go @@ -0,0 +1,98 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateComputeImageCapabilitySchemaDetails Create Image Capability Schema for an image. +type CreateComputeImageCapabilitySchemaDetails struct { + + // The OCID of the compartment that contains the resource. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name of the compute global image capability schema version + ComputeGlobalImageCapabilitySchemaVersionName *string `mandatory:"true" json:"computeGlobalImageCapabilitySchemaVersionName"` + + // The ocid of the image + ImageId *string `mandatory:"true" json:"imageId"` + + // The map of each capability name to its ImageCapabilitySchemaDescriptor. + SchemaData map[string]ImageCapabilitySchemaDescriptor `mandatory:"true" json:"schemaData"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m CreateComputeImageCapabilitySchemaDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *CreateComputeImageCapabilitySchemaDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + FreeformTags map[string]string `json:"freeformTags"` + DisplayName *string `json:"displayName"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + CompartmentId *string `json:"compartmentId"` + ComputeGlobalImageCapabilitySchemaVersionName *string `json:"computeGlobalImageCapabilitySchemaVersionName"` + ImageId *string `json:"imageId"` + SchemaData map[string]imagecapabilityschemadescriptor `json:"schemaData"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.FreeformTags = model.FreeformTags + + m.DisplayName = model.DisplayName + + m.DefinedTags = model.DefinedTags + + m.CompartmentId = model.CompartmentId + + m.ComputeGlobalImageCapabilitySchemaVersionName = model.ComputeGlobalImageCapabilitySchemaVersionName + + m.ImageId = model.ImageId + + m.SchemaData = make(map[string]ImageCapabilitySchemaDescriptor) + for k, v := range model.SchemaData { + nn, e = v.UnmarshalPolymorphicJSON(v.JsonData) + if e != nil { + return e + } + if nn != nil { + m.SchemaData[k] = nn.(ImageCapabilitySchemaDescriptor) + } else { + m.SchemaData[k] = nil + } + } + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_image_capability_schema_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_image_capability_schema_request_response.go new file mode 100644 index 000000000..cb8ffcc75 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_compute_image_capability_schema_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateComputeImageCapabilitySchemaRequest wrapper for the CreateComputeImageCapabilitySchema operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateComputeImageCapabilitySchema.go.html to see an example of how to use CreateComputeImageCapabilitySchemaRequest. +type CreateComputeImageCapabilitySchemaRequest struct { + + // Compute Image Capability Schema creation details + CreateComputeImageCapabilitySchemaDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateComputeImageCapabilitySchemaRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateComputeImageCapabilitySchemaRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateComputeImageCapabilitySchemaRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateComputeImageCapabilitySchemaRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateComputeImageCapabilitySchemaResponse wrapper for the CreateComputeImageCapabilitySchema operation +type CreateComputeImageCapabilitySchemaResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ComputeImageCapabilitySchema instance + ComputeImageCapabilitySchema `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateComputeImageCapabilitySchemaResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateComputeImageCapabilitySchemaResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cpe_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cpe_details.go new file mode 100644 index 000000000..d89aebe55 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cpe_details.go @@ -0,0 +1,59 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateCpeDetails The representation of CreateCpeDetails +type CreateCpeDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the CPE. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The public IP address of the on-premises router. + // Example: `203.0.113.2` + IpAddress *string `mandatory:"true" json:"ipAddress"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the CPE device type. You can provide + // a value if you want to later generate CPE device configuration content for IPSec connections + // that use this CPE. You can also call UpdateCpe later to + // provide a value. For a list of possible values, see + // ListCpeDeviceShapes. + // For more information about generating CPE device configuration content, see: + // * GetCpeDeviceConfigContent + // * GetIpsecCpeDeviceConfigContent + // * GetTunnelCpeDeviceConfigContent + // * GetTunnelCpeDeviceConfig + CpeDeviceShapeId *string `mandatory:"false" json:"cpeDeviceShapeId"` +} + +func (m CreateCpeDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cpe_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cpe_request_response.go new file mode 100644 index 000000000..1ff991579 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cpe_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateCpeRequest wrapper for the CreateCpe operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateCpe.go.html to see an example of how to use CreateCpeRequest. +type CreateCpeRequest struct { + + // Details for creating a CPE. + CreateCpeDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateCpeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateCpeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateCpeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateCpeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateCpeResponse wrapper for the CreateCpe operation +type CreateCpeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Cpe instance + Cpe `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateCpeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateCpeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_details.go new file mode 100644 index 000000000..310122043 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_details.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateCrossConnectDetails The representation of CreateCrossConnectDetails +type CreateCrossConnectDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the cross-connect. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name of the FastConnect location where this cross-connect will be installed. + // To get a list of the available locations, see + // ListCrossConnectLocations. + // Example: `CyrusOne, Chandler, AZ` + LocationName *string `mandatory:"true" json:"locationName"` + + // The port speed for this cross-connect. To get a list of the available port speeds, see + // ListCrossconnectPortSpeedShapes. + // Example: `10 Gbps` + PortSpeedShapeName *string `mandatory:"true" json:"portSpeedShapeName"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the cross-connect group to put this cross-connect in. + CrossConnectGroupId *string `mandatory:"false" json:"crossConnectGroupId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // If you already have an existing cross-connect or cross-connect group at this FastConnect + // location, and you want this new cross-connect to be on a different router (for the + // purposes of redundancy), provide the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of that existing cross-connect or + // cross-connect group. + FarCrossConnectOrCrossConnectGroupId *string `mandatory:"false" json:"farCrossConnectOrCrossConnectGroupId"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // If you already have an existing cross-connect or cross-connect group at this FastConnect + // location, and you want this new cross-connect to be on the same router, provide the + // OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of that existing cross-connect or cross-connect group. + NearCrossConnectOrCrossConnectGroupId *string `mandatory:"false" json:"nearCrossConnectOrCrossConnectGroupId"` + + // A reference name or identifier for the physical fiber connection that this cross-connect + // uses. + CustomerReferenceName *string `mandatory:"false" json:"customerReferenceName"` + + MacsecProperties *CreateMacsecProperties `mandatory:"false" json:"macsecProperties"` +} + +func (m CreateCrossConnectDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_group_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_group_details.go new file mode 100644 index 000000000..3e989186b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_group_details.go @@ -0,0 +1,49 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateCrossConnectGroupDetails The representation of CreateCrossConnectGroupDetails +type CreateCrossConnectGroupDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the cross-connect group. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // A reference name or identifier for the physical fiber connection that this cross-connect + // group uses. + CustomerReferenceName *string `mandatory:"false" json:"customerReferenceName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + MacsecProperties *CreateMacsecProperties `mandatory:"false" json:"macsecProperties"` +} + +func (m CreateCrossConnectGroupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_group_request_response.go new file mode 100644 index 000000000..fd183a44a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_group_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateCrossConnectGroupRequest wrapper for the CreateCrossConnectGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateCrossConnectGroup.go.html to see an example of how to use CreateCrossConnectGroupRequest. +type CreateCrossConnectGroupRequest struct { + + // Details to create a CrossConnectGroup + CreateCrossConnectGroupDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateCrossConnectGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateCrossConnectGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateCrossConnectGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateCrossConnectGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateCrossConnectGroupResponse wrapper for the CreateCrossConnectGroup operation +type CreateCrossConnectGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The CrossConnectGroup instance + CrossConnectGroup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateCrossConnectGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateCrossConnectGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_request_response.go new file mode 100644 index 000000000..fc1a5e23e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_cross_connect_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateCrossConnectRequest wrapper for the CreateCrossConnect operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateCrossConnect.go.html to see an example of how to use CreateCrossConnectRequest. +type CreateCrossConnectRequest struct { + + // Details to create a CrossConnect + CreateCrossConnectDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateCrossConnectRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateCrossConnectRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateCrossConnectRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateCrossConnectRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateCrossConnectResponse wrapper for the CreateCrossConnect operation +type CreateCrossConnectResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The CrossConnect instance + CrossConnect `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateCrossConnectResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateCrossConnectResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_dedicated_vm_host_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_dedicated_vm_host_details.go new file mode 100644 index 000000000..fd20c1602 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_dedicated_vm_host_details.go @@ -0,0 +1,60 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateDedicatedVmHostDetails The details for creating a new dedicated virtual machine host. +type CreateDedicatedVmHostDetails struct { + + // The availability domain of the dedicated virtual machine host. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The dedicated virtual machine host shape. The shape determines the number of CPUs and + // other resources available for VM instances launched on the dedicated virtual machine host. + DedicatedVmHostShape *string `mandatory:"true" json:"dedicatedVmHostShape"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The fault domain for the dedicated virtual machine host's assigned instances. + // For more information, see Fault Domains (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/regions.htm#fault). + // If you do not specify the fault domain, the system selects one for you. To change the fault domain for a dedicated virtual machine host, + // delete it and create a new dedicated virtual machine host in the preferred fault domain. + // To get a list of fault domains, use the `ListFaultDomains` operation in + // the Identity and Access Management Service API (https://docs.cloud.oracle.com/iaas/api/#/en/identity/20160918/). + // Example: `FAULT-DOMAIN-1` + FaultDomain *string `mandatory:"false" json:"faultDomain"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CreateDedicatedVmHostDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_dedicated_vm_host_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_dedicated_vm_host_request_response.go new file mode 100644 index 000000000..45bb20127 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_dedicated_vm_host_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateDedicatedVmHostRequest wrapper for the CreateDedicatedVmHost operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateDedicatedVmHost.go.html to see an example of how to use CreateDedicatedVmHostRequest. +type CreateDedicatedVmHostRequest struct { + + // The details for creating a new dedicated virtual machine host. + CreateDedicatedVmHostDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateDedicatedVmHostRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateDedicatedVmHostRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateDedicatedVmHostRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateDedicatedVmHostRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateDedicatedVmHostResponse wrapper for the CreateDedicatedVmHost operation +type CreateDedicatedVmHostResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DedicatedVmHost instance + DedicatedVmHost `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response CreateDedicatedVmHostResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateDedicatedVmHostResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_dhcp_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_dhcp_details.go new file mode 100644 index 000000000..eb00d71d8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_dhcp_details.go @@ -0,0 +1,123 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateDhcpDetails The representation of CreateDhcpDetails +type CreateDhcpDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the set of DHCP options. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // A set of DHCP options. + Options []DhcpOption `mandatory:"true" json:"options"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN the set of DHCP options belongs to. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The search domain name type of DHCP options + DomainNameType CreateDhcpDetailsDomainNameTypeEnum `mandatory:"false" json:"domainNameType,omitempty"` +} + +func (m CreateDhcpDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *CreateDhcpDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + DisplayName *string `json:"displayName"` + FreeformTags map[string]string `json:"freeformTags"` + DomainNameType CreateDhcpDetailsDomainNameTypeEnum `json:"domainNameType"` + CompartmentId *string `json:"compartmentId"` + Options []dhcpoption `json:"options"` + VcnId *string `json:"vcnId"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.DefinedTags = model.DefinedTags + + m.DisplayName = model.DisplayName + + m.FreeformTags = model.FreeformTags + + m.DomainNameType = model.DomainNameType + + m.CompartmentId = model.CompartmentId + + m.Options = make([]DhcpOption, len(model.Options)) + for i, n := range model.Options { + nn, e = n.UnmarshalPolymorphicJSON(n.JsonData) + if e != nil { + return e + } + if nn != nil { + m.Options[i] = nn.(DhcpOption) + } else { + m.Options[i] = nil + } + } + + m.VcnId = model.VcnId + + return +} + +// CreateDhcpDetailsDomainNameTypeEnum Enum with underlying type: string +type CreateDhcpDetailsDomainNameTypeEnum string + +// Set of constants representing the allowable values for CreateDhcpDetailsDomainNameTypeEnum +const ( + CreateDhcpDetailsDomainNameTypeSubnetDomain CreateDhcpDetailsDomainNameTypeEnum = "SUBNET_DOMAIN" + CreateDhcpDetailsDomainNameTypeVcnDomain CreateDhcpDetailsDomainNameTypeEnum = "VCN_DOMAIN" + CreateDhcpDetailsDomainNameTypeCustomDomain CreateDhcpDetailsDomainNameTypeEnum = "CUSTOM_DOMAIN" +) + +var mappingCreateDhcpDetailsDomainNameType = map[string]CreateDhcpDetailsDomainNameTypeEnum{ + "SUBNET_DOMAIN": CreateDhcpDetailsDomainNameTypeSubnetDomain, + "VCN_DOMAIN": CreateDhcpDetailsDomainNameTypeVcnDomain, + "CUSTOM_DOMAIN": CreateDhcpDetailsDomainNameTypeCustomDomain, +} + +// GetCreateDhcpDetailsDomainNameTypeEnumValues Enumerates the set of values for CreateDhcpDetailsDomainNameTypeEnum +func GetCreateDhcpDetailsDomainNameTypeEnumValues() []CreateDhcpDetailsDomainNameTypeEnum { + values := make([]CreateDhcpDetailsDomainNameTypeEnum, 0) + for _, v := range mappingCreateDhcpDetailsDomainNameType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_dhcp_options_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_dhcp_options_request_response.go new file mode 100644 index 000000000..95af68912 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_dhcp_options_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateDhcpOptionsRequest wrapper for the CreateDhcpOptions operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateDhcpOptions.go.html to see an example of how to use CreateDhcpOptionsRequest. +type CreateDhcpOptionsRequest struct { + + // Request object for creating a new set of DHCP options. + CreateDhcpDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateDhcpOptionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateDhcpOptionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateDhcpOptionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateDhcpOptionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateDhcpOptionsResponse wrapper for the CreateDhcpOptions operation +type CreateDhcpOptionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DhcpOptions instance + DhcpOptions `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateDhcpOptionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateDhcpOptionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_attachment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_attachment_details.go new file mode 100644 index 000000000..cf065ed25 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_attachment_details.go @@ -0,0 +1,109 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateDrgAttachmentDetails The representation of CreateDrgAttachmentDetails +type CreateDrgAttachmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"true" json:"drgId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the DRG route table that is assigned to this attachment. + // The DRG route table manages traffic inside the DRG. + DrgRouteTableId *string `mandatory:"false" json:"drgRouteTableId"` + + NetworkDetails DrgAttachmentNetworkCreateDetails `mandatory:"false" json:"networkDetails"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the route table used by the DRG attachment. + // If you don't specify a route table here, the DRG attachment is created without an associated route + // table. The Networking service does NOT automatically associate the attached VCN's default route table + // with the DRG attachment. + // For information about why you would associate a route table with a DRG attachment, see: + // * Transit Routing: Access to Multiple VCNs in Same Region (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitrouting.htm) + // * Transit Routing: Private Access to Oracle Services (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitroutingoracleservices.htm) + // This field is deprecated. Instead, use the networkDetails field to specify the VCN route table for this attachment. + RouteTableId *string `mandatory:"false" json:"routeTableId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the VCN. + // This field is deprecated. Instead, use the `networkDetails` field to specify the OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the attached resource. + VcnId *string `mandatory:"false" json:"vcnId"` +} + +func (m CreateDrgAttachmentDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *CreateDrgAttachmentDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + DisplayName *string `json:"displayName"` + DrgRouteTableId *string `json:"drgRouteTableId"` + NetworkDetails drgattachmentnetworkcreatedetails `json:"networkDetails"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + FreeformTags map[string]string `json:"freeformTags"` + RouteTableId *string `json:"routeTableId"` + VcnId *string `json:"vcnId"` + DrgId *string `json:"drgId"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.DisplayName = model.DisplayName + + m.DrgRouteTableId = model.DrgRouteTableId + + nn, e = model.NetworkDetails.UnmarshalPolymorphicJSON(model.NetworkDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.NetworkDetails = nn.(DrgAttachmentNetworkCreateDetails) + } else { + m.NetworkDetails = nil + } + + m.DefinedTags = model.DefinedTags + + m.FreeformTags = model.FreeformTags + + m.RouteTableId = model.RouteTableId + + m.VcnId = model.VcnId + + m.DrgId = model.DrgId + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_attachment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_attachment_request_response.go new file mode 100644 index 000000000..693b65ee2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_attachment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateDrgAttachmentRequest wrapper for the CreateDrgAttachment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateDrgAttachment.go.html to see an example of how to use CreateDrgAttachmentRequest. +type CreateDrgAttachmentRequest struct { + + // Details for creating a `DrgAttachment`. + CreateDrgAttachmentDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateDrgAttachmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateDrgAttachmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateDrgAttachmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateDrgAttachmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateDrgAttachmentResponse wrapper for the CreateDrgAttachment operation +type CreateDrgAttachmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DrgAttachment instance + DrgAttachment `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateDrgAttachmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateDrgAttachmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_details.go new file mode 100644 index 000000000..bb897890e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_details.go @@ -0,0 +1,43 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateDrgDetails The representation of CreateDrgDetails +type CreateDrgDetails struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the compartment to contain the DRG. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CreateDrgDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_request_response.go new file mode 100644 index 000000000..861f23801 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateDrgRequest wrapper for the CreateDrg operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateDrg.go.html to see an example of how to use CreateDrgRequest. +type CreateDrgRequest struct { + + // Details for creating a DRG. + CreateDrgDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateDrgRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateDrgRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateDrgRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateDrgRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateDrgResponse wrapper for the CreateDrg operation +type CreateDrgResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Drg instance + Drg `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateDrgResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateDrgResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_distribution_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_distribution_details.go new file mode 100644 index 000000000..d5e6b52d8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_distribution_details.go @@ -0,0 +1,67 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateDrgRouteDistributionDetails Details used to create a route distribution. +type CreateDrgRouteDistributionDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG the DRG route table belongs to. + DrgId *string `mandatory:"true" json:"drgId"` + + // Whether this distribution defines how routes get imported into route tables or exported through DRG Attachments + DistributionType CreateDrgRouteDistributionDetailsDistributionTypeEnum `mandatory:"true" json:"distributionType"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CreateDrgRouteDistributionDetails) String() string { + return common.PointerString(m) +} + +// CreateDrgRouteDistributionDetailsDistributionTypeEnum Enum with underlying type: string +type CreateDrgRouteDistributionDetailsDistributionTypeEnum string + +// Set of constants representing the allowable values for CreateDrgRouteDistributionDetailsDistributionTypeEnum +const ( + CreateDrgRouteDistributionDetailsDistributionTypeImport CreateDrgRouteDistributionDetailsDistributionTypeEnum = "IMPORT" +) + +var mappingCreateDrgRouteDistributionDetailsDistributionType = map[string]CreateDrgRouteDistributionDetailsDistributionTypeEnum{ + "IMPORT": CreateDrgRouteDistributionDetailsDistributionTypeImport, +} + +// GetCreateDrgRouteDistributionDetailsDistributionTypeEnumValues Enumerates the set of values for CreateDrgRouteDistributionDetailsDistributionTypeEnum +func GetCreateDrgRouteDistributionDetailsDistributionTypeEnumValues() []CreateDrgRouteDistributionDetailsDistributionTypeEnum { + values := make([]CreateDrgRouteDistributionDetailsDistributionTypeEnum, 0) + for _, v := range mappingCreateDrgRouteDistributionDetailsDistributionType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_distribution_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_distribution_request_response.go new file mode 100644 index 000000000..0b8c463ed --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_distribution_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateDrgRouteDistributionRequest wrapper for the CreateDrgRouteDistribution operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateDrgRouteDistribution.go.html to see an example of how to use CreateDrgRouteDistributionRequest. +type CreateDrgRouteDistributionRequest struct { + + // Details for creating a route distribution. + CreateDrgRouteDistributionDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateDrgRouteDistributionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateDrgRouteDistributionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateDrgRouteDistributionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateDrgRouteDistributionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateDrgRouteDistributionResponse wrapper for the CreateDrgRouteDistribution operation +type CreateDrgRouteDistributionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DrgRouteDistribution instance + DrgRouteDistribution `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateDrgRouteDistributionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateDrgRouteDistributionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_table_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_table_details.go new file mode 100644 index 000000000..c565dc195 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_table_details.go @@ -0,0 +1,51 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateDrgRouteTableDetails Details used in a request to create a DRG route table. +type CreateDrgRouteTableDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG the DRG route table belongs to. + DrgId *string `mandatory:"true" json:"drgId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the import route distribution used to specify how incoming route advertisements through + // referenced attachments are inserted into the DRG route table. + ImportDrgRouteDistributionId *string `mandatory:"false" json:"importDrgRouteDistributionId"` + + // If you want traffic to be routed using ECMP across your virtual circuits or IPSec tunnels to + // your on-premises networks, enable ECMP on the DRG route table. + IsEcmpEnabled *bool `mandatory:"false" json:"isEcmpEnabled"` +} + +func (m CreateDrgRouteTableDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_table_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_table_request_response.go new file mode 100644 index 000000000..5fdc17de8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_drg_route_table_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateDrgRouteTableRequest wrapper for the CreateDrgRouteTable operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateDrgRouteTable.go.html to see an example of how to use CreateDrgRouteTableRequest. +type CreateDrgRouteTableRequest struct { + + // Details for creating a DRG route table. + CreateDrgRouteTableDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateDrgRouteTableRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateDrgRouteTableRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateDrgRouteTableRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateDrgRouteTableRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateDrgRouteTableResponse wrapper for the CreateDrgRouteTable operation +type CreateDrgRouteTableResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DrgRouteTable instance + DrgRouteTable `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateDrgRouteTableResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateDrgRouteTableResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_i_p_sec_connection_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_i_p_sec_connection_request_response.go new file mode 100644 index 000000000..a4e091c1d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_i_p_sec_connection_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateIPSecConnectionRequest wrapper for the CreateIPSecConnection operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateIPSecConnection.go.html to see an example of how to use CreateIPSecConnectionRequest. +type CreateIPSecConnectionRequest struct { + + // Details for creating an `IPSecConnection`. + CreateIpSecConnectionDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateIPSecConnectionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateIPSecConnectionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateIPSecConnectionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateIPSecConnectionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateIPSecConnectionResponse wrapper for the CreateIPSecConnection operation +type CreateIPSecConnectionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IpSecConnection instance + IpSecConnection `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateIPSecConnectionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateIPSecConnectionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_image_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_image_details.go new file mode 100644 index 000000000..cf572ad73 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_image_details.go @@ -0,0 +1,127 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateImageDetails Either instanceId or imageSourceDetails must be provided in addition to other required parameters. +type CreateImageDetails struct { + + // The OCID of the compartment you want the image to be created in. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name for the image. It does not have to be unique, and it's changeable. + // Avoid entering confidential information. + // You cannot use a platform image name as a custom image name. + // Example: `My Oracle Linux image` + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + ImageSourceDetails ImageSourceDetails `mandatory:"false" json:"imageSourceDetails"` + + // The OCID of the instance you want to use as the basis for the image. + InstanceId *string `mandatory:"false" json:"instanceId"` + + // Specifies the configuration mode for launching virtual machine (VM) instances. The configuration modes are: + // * `NATIVE` - VM instances launch with paravirtualized boot and VFIO devices. The default value for platform images. + // * `EMULATED` - VM instances launch with emulated devices, such as the E1000 network driver and emulated SCSI disk controller. + // * `PARAVIRTUALIZED` - VM instances launch with paravirtualized devices using VirtIO drivers. + // * `CUSTOM` - VM instances launch with custom configuration settings specified in the `LaunchOptions` parameter. + LaunchMode CreateImageDetailsLaunchModeEnum `mandatory:"false" json:"launchMode,omitempty"` +} + +func (m CreateImageDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *CreateImageDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + DisplayName *string `json:"displayName"` + FreeformTags map[string]string `json:"freeformTags"` + ImageSourceDetails imagesourcedetails `json:"imageSourceDetails"` + InstanceId *string `json:"instanceId"` + LaunchMode CreateImageDetailsLaunchModeEnum `json:"launchMode"` + CompartmentId *string `json:"compartmentId"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.DefinedTags = model.DefinedTags + + m.DisplayName = model.DisplayName + + m.FreeformTags = model.FreeformTags + + nn, e = model.ImageSourceDetails.UnmarshalPolymorphicJSON(model.ImageSourceDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.ImageSourceDetails = nn.(ImageSourceDetails) + } else { + m.ImageSourceDetails = nil + } + + m.InstanceId = model.InstanceId + + m.LaunchMode = model.LaunchMode + + m.CompartmentId = model.CompartmentId + + return +} + +// CreateImageDetailsLaunchModeEnum Enum with underlying type: string +type CreateImageDetailsLaunchModeEnum string + +// Set of constants representing the allowable values for CreateImageDetailsLaunchModeEnum +const ( + CreateImageDetailsLaunchModeNative CreateImageDetailsLaunchModeEnum = "NATIVE" + CreateImageDetailsLaunchModeEmulated CreateImageDetailsLaunchModeEnum = "EMULATED" + CreateImageDetailsLaunchModeParavirtualized CreateImageDetailsLaunchModeEnum = "PARAVIRTUALIZED" + CreateImageDetailsLaunchModeCustom CreateImageDetailsLaunchModeEnum = "CUSTOM" +) + +var mappingCreateImageDetailsLaunchMode = map[string]CreateImageDetailsLaunchModeEnum{ + "NATIVE": CreateImageDetailsLaunchModeNative, + "EMULATED": CreateImageDetailsLaunchModeEmulated, + "PARAVIRTUALIZED": CreateImageDetailsLaunchModeParavirtualized, + "CUSTOM": CreateImageDetailsLaunchModeCustom, +} + +// GetCreateImageDetailsLaunchModeEnumValues Enumerates the set of values for CreateImageDetailsLaunchModeEnum +func GetCreateImageDetailsLaunchModeEnumValues() []CreateImageDetailsLaunchModeEnum { + values := make([]CreateImageDetailsLaunchModeEnum, 0) + for _, v := range mappingCreateImageDetailsLaunchMode { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_image_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_image_request_response.go new file mode 100644 index 000000000..4cea8c983 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_image_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateImageRequest wrapper for the CreateImage operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateImage.go.html to see an example of how to use CreateImageRequest. +type CreateImageRequest struct { + + // Image creation details + CreateImageDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateImageRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateImageRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateImageRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateImageRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateImageResponse wrapper for the CreateImage operation +type CreateImageResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Image instance + Image `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response CreateImageResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateImageResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_base.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_base.go new file mode 100644 index 000000000..a998b657a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_base.go @@ -0,0 +1,139 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateInstanceConfigurationBase Creation details for an instance configuration. +type CreateInstanceConfigurationBase interface { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment + // containing the instance configuration. + GetCompartmentId() *string + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + GetDefinedTags() map[string]map[string]interface{} + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + GetDisplayName() *string + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + GetFreeformTags() map[string]string +} + +type createinstanceconfigurationbase struct { + JsonData []byte + CompartmentId *string `mandatory:"true" json:"compartmentId"` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + DisplayName *string `mandatory:"false" json:"displayName"` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + Source string `json:"source"` +} + +// UnmarshalJSON unmarshals json +func (m *createinstanceconfigurationbase) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalercreateinstanceconfigurationbase createinstanceconfigurationbase + s := struct { + Model Unmarshalercreateinstanceconfigurationbase + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.CompartmentId = s.Model.CompartmentId + m.DefinedTags = s.Model.DefinedTags + m.DisplayName = s.Model.DisplayName + m.FreeformTags = s.Model.FreeformTags + m.Source = s.Model.Source + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *createinstanceconfigurationbase) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Source { + case "NONE": + mm := CreateInstanceConfigurationDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "INSTANCE": + mm := CreateInstanceConfigurationFromInstanceDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetCompartmentId returns CompartmentId +func (m createinstanceconfigurationbase) GetCompartmentId() *string { + return m.CompartmentId +} + +//GetDefinedTags returns DefinedTags +func (m createinstanceconfigurationbase) GetDefinedTags() map[string]map[string]interface{} { + return m.DefinedTags +} + +//GetDisplayName returns DisplayName +func (m createinstanceconfigurationbase) GetDisplayName() *string { + return m.DisplayName +} + +//GetFreeformTags returns FreeformTags +func (m createinstanceconfigurationbase) GetFreeformTags() map[string]string { + return m.FreeformTags +} + +func (m createinstanceconfigurationbase) String() string { + return common.PointerString(m) +} + +// CreateInstanceConfigurationBaseSourceEnum Enum with underlying type: string +type CreateInstanceConfigurationBaseSourceEnum string + +// Set of constants representing the allowable values for CreateInstanceConfigurationBaseSourceEnum +const ( + CreateInstanceConfigurationBaseSourceNone CreateInstanceConfigurationBaseSourceEnum = "NONE" + CreateInstanceConfigurationBaseSourceInstance CreateInstanceConfigurationBaseSourceEnum = "INSTANCE" +) + +var mappingCreateInstanceConfigurationBaseSource = map[string]CreateInstanceConfigurationBaseSourceEnum{ + "NONE": CreateInstanceConfigurationBaseSourceNone, + "INSTANCE": CreateInstanceConfigurationBaseSourceInstance, +} + +// GetCreateInstanceConfigurationBaseSourceEnumValues Enumerates the set of values for CreateInstanceConfigurationBaseSourceEnum +func GetCreateInstanceConfigurationBaseSourceEnumValues() []CreateInstanceConfigurationBaseSourceEnum { + values := make([]CreateInstanceConfigurationBaseSourceEnum, 0) + for _, v := range mappingCreateInstanceConfigurationBaseSource { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_details.go new file mode 100644 index 000000000..4db52b272 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_details.go @@ -0,0 +1,117 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateInstanceConfigurationDetails Details for creating an instance configuration by providing a list of configuration settings. +type CreateInstanceConfigurationDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment + // containing the instance configuration. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + InstanceDetails InstanceConfigurationInstanceDetails `mandatory:"true" json:"instanceDetails"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +//GetCompartmentId returns CompartmentId +func (m CreateInstanceConfigurationDetails) GetCompartmentId() *string { + return m.CompartmentId +} + +//GetDefinedTags returns DefinedTags +func (m CreateInstanceConfigurationDetails) GetDefinedTags() map[string]map[string]interface{} { + return m.DefinedTags +} + +//GetDisplayName returns DisplayName +func (m CreateInstanceConfigurationDetails) GetDisplayName() *string { + return m.DisplayName +} + +//GetFreeformTags returns FreeformTags +func (m CreateInstanceConfigurationDetails) GetFreeformTags() map[string]string { + return m.FreeformTags +} + +func (m CreateInstanceConfigurationDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m CreateInstanceConfigurationDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeCreateInstanceConfigurationDetails CreateInstanceConfigurationDetails + s := struct { + DiscriminatorParam string `json:"source"` + MarshalTypeCreateInstanceConfigurationDetails + }{ + "NONE", + (MarshalTypeCreateInstanceConfigurationDetails)(m), + } + + return json.Marshal(&s) +} + +// UnmarshalJSON unmarshals from json +func (m *CreateInstanceConfigurationDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + DisplayName *string `json:"displayName"` + FreeformTags map[string]string `json:"freeformTags"` + CompartmentId *string `json:"compartmentId"` + InstanceDetails instanceconfigurationinstancedetails `json:"instanceDetails"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.DefinedTags = model.DefinedTags + + m.DisplayName = model.DisplayName + + m.FreeformTags = model.FreeformTags + + m.CompartmentId = model.CompartmentId + + nn, e = model.InstanceDetails.UnmarshalPolymorphicJSON(model.InstanceDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.InstanceDetails = nn.(InstanceConfigurationInstanceDetails) + } else { + m.InstanceDetails = nil + } + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_from_instance_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_from_instance_details.go new file mode 100644 index 000000000..c27cbfcf8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_from_instance_details.go @@ -0,0 +1,83 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateInstanceConfigurationFromInstanceDetails Details for creating an instance configuration using an existing instance as a template. +type CreateInstanceConfigurationFromInstanceDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment + // containing the instance configuration. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance to use to create the + // instance configuration. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +//GetCompartmentId returns CompartmentId +func (m CreateInstanceConfigurationFromInstanceDetails) GetCompartmentId() *string { + return m.CompartmentId +} + +//GetDefinedTags returns DefinedTags +func (m CreateInstanceConfigurationFromInstanceDetails) GetDefinedTags() map[string]map[string]interface{} { + return m.DefinedTags +} + +//GetDisplayName returns DisplayName +func (m CreateInstanceConfigurationFromInstanceDetails) GetDisplayName() *string { + return m.DisplayName +} + +//GetFreeformTags returns FreeformTags +func (m CreateInstanceConfigurationFromInstanceDetails) GetFreeformTags() map[string]string { + return m.FreeformTags +} + +func (m CreateInstanceConfigurationFromInstanceDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m CreateInstanceConfigurationFromInstanceDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeCreateInstanceConfigurationFromInstanceDetails CreateInstanceConfigurationFromInstanceDetails + s := struct { + DiscriminatorParam string `json:"source"` + MarshalTypeCreateInstanceConfigurationFromInstanceDetails + }{ + "INSTANCE", + (MarshalTypeCreateInstanceConfigurationFromInstanceDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_request_response.go new file mode 100644 index 000000000..5e5dbd406 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_configuration_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateInstanceConfigurationRequest wrapper for the CreateInstanceConfiguration operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateInstanceConfiguration.go.html to see an example of how to use CreateInstanceConfigurationRequest. +type CreateInstanceConfigurationRequest struct { + + // Instance configuration creation details + CreateInstanceConfiguration CreateInstanceConfigurationBase `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateInstanceConfigurationRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateInstanceConfigurationRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateInstanceConfigurationRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateInstanceConfigurationRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateInstanceConfigurationResponse wrapper for the CreateInstanceConfiguration operation +type CreateInstanceConfigurationResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstanceConfiguration instance + InstanceConfiguration `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateInstanceConfigurationResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateInstanceConfigurationResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_console_connection_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_console_connection_details.go new file mode 100644 index 000000000..c32714513 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_console_connection_details.go @@ -0,0 +1,43 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateInstanceConsoleConnectionDetails The details for creating a instance console connection. +// The instance console connection is created in the same compartment as the instance. +type CreateInstanceConsoleConnectionDetails struct { + + // The OCID of the instance to create the console connection to. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // The SSH public key used to authenticate the console connection. + PublicKey *string `mandatory:"true" json:"publicKey"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CreateInstanceConsoleConnectionDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_console_connection_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_console_connection_request_response.go new file mode 100644 index 000000000..19e734994 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_console_connection_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateInstanceConsoleConnectionRequest wrapper for the CreateInstanceConsoleConnection operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateInstanceConsoleConnection.go.html to see an example of how to use CreateInstanceConsoleConnectionRequest. +type CreateInstanceConsoleConnectionRequest struct { + + // Request object for creating an InstanceConsoleConnection + CreateInstanceConsoleConnectionDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateInstanceConsoleConnectionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateInstanceConsoleConnectionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateInstanceConsoleConnectionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateInstanceConsoleConnectionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateInstanceConsoleConnectionResponse wrapper for the CreateInstanceConsoleConnection operation +type CreateInstanceConsoleConnectionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstanceConsoleConnection instance + InstanceConsoleConnection `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateInstanceConsoleConnectionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateInstanceConsoleConnectionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_pool_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_pool_details.go new file mode 100644 index 000000000..e23dadaf9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_pool_details.go @@ -0,0 +1,60 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateInstancePoolDetails The data to create an instance pool. +type CreateInstancePoolDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the instance pool. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance configuration associated + // with the instance pool. + InstanceConfigurationId *string `mandatory:"true" json:"instanceConfigurationId"` + + // The placement configurations for the instance pool. Provide one placement configuration for + // each availability domain. + // To use the instance pool with a regional subnet, provide a placement configuration for + // each availability domain, and include the regional subnet in each placement + // configuration. + PlacementConfigurations []CreateInstancePoolPlacementConfigurationDetails `mandatory:"true" json:"placementConfigurations"` + + // The number of instances that should be in the instance pool. + Size *int `mandatory:"true" json:"size"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The load balancers to attach to the instance pool. + LoadBalancers []AttachLoadBalancerDetails `mandatory:"false" json:"loadBalancers"` +} + +func (m CreateInstancePoolDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_pool_placement_configuration_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_pool_placement_configuration_details.go new file mode 100644 index 000000000..5085beffe --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_pool_placement_configuration_details.go @@ -0,0 +1,48 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateInstancePoolPlacementConfigurationDetails The location for where an instance pool will place instances. +type CreateInstancePoolPlacementConfigurationDetails struct { + + // The availability domain to place instances. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the primary subnet to place instances. + PrimarySubnetId *string `mandatory:"true" json:"primarySubnetId"` + + // The fault domains to place instances. + // If you don't provide any values, the system makes a best effort to distribute + // instances across all fault domains based on capacity. + // To distribute the instances evenly across selected fault domains, provide a + // set of fault domains. For example, you might want instances to be evenly + // distributed if your applications require high availability. + // To get a list of fault domains, use the + // ListFaultDomains operation + // in the Identity and Access Management Service API. + // Example: `[FAULT-DOMAIN-1, FAULT-DOMAIN-2, FAULT-DOMAIN-3]` + FaultDomains []string `mandatory:"false" json:"faultDomains"` + + // The set of secondary VNIC data for instances in the pool. + SecondaryVnicSubnets []InstancePoolPlacementSecondaryVnicSubnet `mandatory:"false" json:"secondaryVnicSubnets"` +} + +func (m CreateInstancePoolPlacementConfigurationDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_pool_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_pool_request_response.go new file mode 100644 index 000000000..47edaa2c5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_instance_pool_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateInstancePoolRequest wrapper for the CreateInstancePool operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateInstancePool.go.html to see an example of how to use CreateInstancePoolRequest. +type CreateInstancePoolRequest struct { + + // Instance pool creation details + CreateInstancePoolDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateInstancePoolRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateInstancePoolRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateInstancePoolRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateInstancePoolRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateInstancePoolResponse wrapper for the CreateInstancePool operation +type CreateInstancePoolResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstancePool instance + InstancePool `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateInstancePoolResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateInstancePoolResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_internet_gateway_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_internet_gateway_details.go new file mode 100644 index 000000000..ba697ebd8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_internet_gateway_details.go @@ -0,0 +1,49 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateInternetGatewayDetails The representation of CreateInternetGatewayDetails +type CreateInternetGatewayDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the internet gateway. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // Whether the gateway is enabled upon creation. + IsEnabled *bool `mandatory:"true" json:"isEnabled"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN the internet gateway is attached to. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CreateInternetGatewayDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_internet_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_internet_gateway_request_response.go new file mode 100644 index 000000000..6c1b1855a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_internet_gateway_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateInternetGatewayRequest wrapper for the CreateInternetGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateInternetGateway.go.html to see an example of how to use CreateInternetGatewayRequest. +type CreateInternetGatewayRequest struct { + + // Details for creating a new internet gateway. + CreateInternetGatewayDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateInternetGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateInternetGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateInternetGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateInternetGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateInternetGatewayResponse wrapper for the CreateInternetGateway operation +type CreateInternetGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InternetGateway instance + InternetGateway `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateInternetGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateInternetGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_connection_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_connection_details.go new file mode 100644 index 000000000..43b5a604a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_connection_details.go @@ -0,0 +1,105 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateIpSecConnectionDetails The representation of CreateIpSecConnectionDetails +type CreateIpSecConnectionDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the IPSec connection. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the Cpe object. + CpeId *string `mandatory:"true" json:"cpeId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"true" json:"drgId"` + + // Static routes to the CPE. A static route's CIDR must not be a + // multicast address or class E address. + // Used for routing a given IPSec tunnel's traffic only if the tunnel + // is using static routing. If you configure at least one tunnel to use static routing, then + // you must provide at least one valid static route. If you configure both + // tunnels to use BGP dynamic routing, you can provide an empty list for the static routes. + // For more information, see the important note in IPSecConnection. + // The CIDR can be either IPv4 or IPv6. IPv6 addressing is supported for all commercial and government regions. + // See IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // Example: `10.0.1.0/24` + // Example: `2001:db8::/32` + StaticRoutes []string `mandatory:"true" json:"staticRoutes"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Your identifier for your CPE device. Can be either an IP address or a hostname (specifically, the + // fully qualified domain name (FQDN)). The type of identifier you provide here must correspond + // to the value for `cpeLocalIdentifierType`. + // If you don't provide a value, the `ipAddress` attribute for the Cpe + // object specified by `cpeId` is used as the `cpeLocalIdentifier`. + // For information about why you'd provide this value, see + // If Your CPE Is Behind a NAT Device (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/overviewIPsec.htm#nat). + // Example IP address: `10.0.3.3` + // Example hostname: `cpe.example.com` + CpeLocalIdentifier *string `mandatory:"false" json:"cpeLocalIdentifier"` + + // The type of identifier for your CPE device. The value you provide here must correspond to the value + // for `cpeLocalIdentifier`. + CpeLocalIdentifierType CreateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum `mandatory:"false" json:"cpeLocalIdentifierType,omitempty"` + + // Information for creating the individual tunnels in the IPSec connection. You can provide a + // maximum of 2 `tunnelConfiguration` objects in the array (one for each of the + // two tunnels). + TunnelConfiguration []CreateIpSecConnectionTunnelDetails `mandatory:"false" json:"tunnelConfiguration"` +} + +func (m CreateIpSecConnectionDetails) String() string { + return common.PointerString(m) +} + +// CreateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum Enum with underlying type: string +type CreateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum string + +// Set of constants representing the allowable values for CreateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum +const ( + CreateIpSecConnectionDetailsCpeLocalIdentifierTypeIpAddress CreateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum = "IP_ADDRESS" + CreateIpSecConnectionDetailsCpeLocalIdentifierTypeHostname CreateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum = "HOSTNAME" +) + +var mappingCreateIpSecConnectionDetailsCpeLocalIdentifierType = map[string]CreateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum{ + "IP_ADDRESS": CreateIpSecConnectionDetailsCpeLocalIdentifierTypeIpAddress, + "HOSTNAME": CreateIpSecConnectionDetailsCpeLocalIdentifierTypeHostname, +} + +// GetCreateIpSecConnectionDetailsCpeLocalIdentifierTypeEnumValues Enumerates the set of values for CreateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum +func GetCreateIpSecConnectionDetailsCpeLocalIdentifierTypeEnumValues() []CreateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum { + values := make([]CreateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum, 0) + for _, v := range mappingCreateIpSecConnectionDetailsCpeLocalIdentifierType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_connection_tunnel_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_connection_tunnel_details.go new file mode 100644 index 000000000..64423ade4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_connection_tunnel_details.go @@ -0,0 +1,154 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateIpSecConnectionTunnelDetails The representation of CreateIpSecConnectionTunnelDetails +type CreateIpSecConnectionTunnelDetails struct { + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The type of routing to use for this tunnel (either BGP dynamic routing or static routing). + Routing CreateIpSecConnectionTunnelDetailsRoutingEnum `mandatory:"false" json:"routing,omitempty"` + + // Internet Key Exchange protocol version. + IkeVersion CreateIpSecConnectionTunnelDetailsIkeVersionEnum `mandatory:"false" json:"ikeVersion,omitempty"` + + // The shared secret (pre-shared key) to use for the IPSec tunnel. Only numbers, letters, and + // spaces are allowed. If you don't provide a value, + // Oracle generates a value for you. You can specify your own shared secret later if + // you like with UpdateIPSecConnectionTunnelSharedSecret. + SharedSecret *string `mandatory:"false" json:"sharedSecret"` + + BgpSessionConfig *CreateIpSecTunnelBgpSessionDetails `mandatory:"false" json:"bgpSessionConfig"` + + // Whether Oracle side is the initiator for negotiation. + OracleInitiation CreateIpSecConnectionTunnelDetailsOracleInitiationEnum `mandatory:"false" json:"oracleInitiation,omitempty"` + + // Whether NAT-T Enabled on the tunnel + NatTranslationEnabled CreateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum `mandatory:"false" json:"natTranslationEnabled,omitempty"` + + PhaseOneConfig *PhaseOneConfigDetails `mandatory:"false" json:"phaseOneConfig"` + + PhaseTwoConfig *PhaseTwoConfigDetails `mandatory:"false" json:"phaseTwoConfig"` + + DpdConfig *DpdConfig `mandatory:"false" json:"dpdConfig"` + + EncryptionDomainConfig *CreateIpSecTunnelEncryptionDomainDetails `mandatory:"false" json:"encryptionDomainConfig"` +} + +func (m CreateIpSecConnectionTunnelDetails) String() string { + return common.PointerString(m) +} + +// CreateIpSecConnectionTunnelDetailsRoutingEnum Enum with underlying type: string +type CreateIpSecConnectionTunnelDetailsRoutingEnum string + +// Set of constants representing the allowable values for CreateIpSecConnectionTunnelDetailsRoutingEnum +const ( + CreateIpSecConnectionTunnelDetailsRoutingBgp CreateIpSecConnectionTunnelDetailsRoutingEnum = "BGP" + CreateIpSecConnectionTunnelDetailsRoutingStatic CreateIpSecConnectionTunnelDetailsRoutingEnum = "STATIC" + CreateIpSecConnectionTunnelDetailsRoutingPolicy CreateIpSecConnectionTunnelDetailsRoutingEnum = "POLICY" +) + +var mappingCreateIpSecConnectionTunnelDetailsRouting = map[string]CreateIpSecConnectionTunnelDetailsRoutingEnum{ + "BGP": CreateIpSecConnectionTunnelDetailsRoutingBgp, + "STATIC": CreateIpSecConnectionTunnelDetailsRoutingStatic, + "POLICY": CreateIpSecConnectionTunnelDetailsRoutingPolicy, +} + +// GetCreateIpSecConnectionTunnelDetailsRoutingEnumValues Enumerates the set of values for CreateIpSecConnectionTunnelDetailsRoutingEnum +func GetCreateIpSecConnectionTunnelDetailsRoutingEnumValues() []CreateIpSecConnectionTunnelDetailsRoutingEnum { + values := make([]CreateIpSecConnectionTunnelDetailsRoutingEnum, 0) + for _, v := range mappingCreateIpSecConnectionTunnelDetailsRouting { + values = append(values, v) + } + return values +} + +// CreateIpSecConnectionTunnelDetailsIkeVersionEnum Enum with underlying type: string +type CreateIpSecConnectionTunnelDetailsIkeVersionEnum string + +// Set of constants representing the allowable values for CreateIpSecConnectionTunnelDetailsIkeVersionEnum +const ( + CreateIpSecConnectionTunnelDetailsIkeVersionV1 CreateIpSecConnectionTunnelDetailsIkeVersionEnum = "V1" + CreateIpSecConnectionTunnelDetailsIkeVersionV2 CreateIpSecConnectionTunnelDetailsIkeVersionEnum = "V2" +) + +var mappingCreateIpSecConnectionTunnelDetailsIkeVersion = map[string]CreateIpSecConnectionTunnelDetailsIkeVersionEnum{ + "V1": CreateIpSecConnectionTunnelDetailsIkeVersionV1, + "V2": CreateIpSecConnectionTunnelDetailsIkeVersionV2, +} + +// GetCreateIpSecConnectionTunnelDetailsIkeVersionEnumValues Enumerates the set of values for CreateIpSecConnectionTunnelDetailsIkeVersionEnum +func GetCreateIpSecConnectionTunnelDetailsIkeVersionEnumValues() []CreateIpSecConnectionTunnelDetailsIkeVersionEnum { + values := make([]CreateIpSecConnectionTunnelDetailsIkeVersionEnum, 0) + for _, v := range mappingCreateIpSecConnectionTunnelDetailsIkeVersion { + values = append(values, v) + } + return values +} + +// CreateIpSecConnectionTunnelDetailsOracleInitiationEnum Enum with underlying type: string +type CreateIpSecConnectionTunnelDetailsOracleInitiationEnum string + +// Set of constants representing the allowable values for CreateIpSecConnectionTunnelDetailsOracleInitiationEnum +const ( + CreateIpSecConnectionTunnelDetailsOracleInitiationInitiatorOrResponder CreateIpSecConnectionTunnelDetailsOracleInitiationEnum = "INITIATOR_OR_RESPONDER" + CreateIpSecConnectionTunnelDetailsOracleInitiationResponderOnly CreateIpSecConnectionTunnelDetailsOracleInitiationEnum = "RESPONDER_ONLY" +) + +var mappingCreateIpSecConnectionTunnelDetailsOracleInitiation = map[string]CreateIpSecConnectionTunnelDetailsOracleInitiationEnum{ + "INITIATOR_OR_RESPONDER": CreateIpSecConnectionTunnelDetailsOracleInitiationInitiatorOrResponder, + "RESPONDER_ONLY": CreateIpSecConnectionTunnelDetailsOracleInitiationResponderOnly, +} + +// GetCreateIpSecConnectionTunnelDetailsOracleInitiationEnumValues Enumerates the set of values for CreateIpSecConnectionTunnelDetailsOracleInitiationEnum +func GetCreateIpSecConnectionTunnelDetailsOracleInitiationEnumValues() []CreateIpSecConnectionTunnelDetailsOracleInitiationEnum { + values := make([]CreateIpSecConnectionTunnelDetailsOracleInitiationEnum, 0) + for _, v := range mappingCreateIpSecConnectionTunnelDetailsOracleInitiation { + values = append(values, v) + } + return values +} + +// CreateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum Enum with underlying type: string +type CreateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum string + +// Set of constants representing the allowable values for CreateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum +const ( + CreateIpSecConnectionTunnelDetailsNatTranslationEnabledEnabled CreateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum = "ENABLED" + CreateIpSecConnectionTunnelDetailsNatTranslationEnabledDisabled CreateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum = "DISABLED" + CreateIpSecConnectionTunnelDetailsNatTranslationEnabledAuto CreateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum = "AUTO" +) + +var mappingCreateIpSecConnectionTunnelDetailsNatTranslationEnabled = map[string]CreateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum{ + "ENABLED": CreateIpSecConnectionTunnelDetailsNatTranslationEnabledEnabled, + "DISABLED": CreateIpSecConnectionTunnelDetailsNatTranslationEnabledDisabled, + "AUTO": CreateIpSecConnectionTunnelDetailsNatTranslationEnabledAuto, +} + +// GetCreateIpSecConnectionTunnelDetailsNatTranslationEnabledEnumValues Enumerates the set of values for CreateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum +func GetCreateIpSecConnectionTunnelDetailsNatTranslationEnabledEnumValues() []CreateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum { + values := make([]CreateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum, 0) + for _, v := range mappingCreateIpSecConnectionTunnelDetailsNatTranslationEnabled { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_tunnel_bgp_session_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_tunnel_bgp_session_details.go new file mode 100644 index 000000000..db6fc7bb7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_tunnel_bgp_session_details.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateIpSecTunnelBgpSessionDetails The representation of CreateIpSecTunnelBgpSessionDetails +type CreateIpSecTunnelBgpSessionDetails struct { + + // The IP address for the Oracle end of the inside tunnel interface. + // If the tunnel's `routing` attribute is set to `BGP` + // (see IPSecConnectionTunnel), this IP address + // is required and used for the tunnel's BGP session. + // If `routing` is instead set to `STATIC`, this IP address is optional. You can set this IP + // address to troubleshoot or monitor the tunnel. + // The value must be a /30 or /31. + // Example: `10.0.0.4/31` + OracleInterfaceIp *string `mandatory:"false" json:"oracleInterfaceIp"` + + // The IP address for the CPE end of the inside tunnel interface. + // If the tunnel's `routing` attribute is set to `BGP` + // (see IPSecConnectionTunnel), this IP address + // is required and used for the tunnel's BGP session. + // If `routing` is instead set to `STATIC`, this IP address is optional. You can set this IP + // address to troubleshoot or monitor the tunnel. + // The value must be a /30 or /31. + // Example: `10.0.0.5/31` + CustomerInterfaceIp *string `mandatory:"false" json:"customerInterfaceIp"` + + // The IPv6 address for the Oracle end of the inside tunnel interface. This IP address is optional. + // If the tunnel's `routing` attribute is set to `BGP` + // (see IPSecConnectionTunnel), this IP address + // is used for the tunnel's BGP session. + // If `routing` is instead set to `STATIC`, you can set this IP + // address to troubleshoot or monitor the tunnel. + // Only subnet masks from /64 up to /127 are allowed. + // Example: `2001:db8::1/64` + OracleInterfaceIpv6 *string `mandatory:"false" json:"oracleInterfaceIpv6"` + + // The IPv6 address for the CPE end of the inside tunnel interface. This IP address is optional. + // If the tunnel's `routing` attribute is set to `BGP` + // (see IPSecConnectionTunnel), this IP address + // is used for the tunnel's BGP session. + // If `routing` is instead set to `STATIC`, you can set this IP + // address to troubleshoot or monitor the tunnel. + // Only subnet masks from /64 up to /127 are allowed. + // Example: `2001:db8::1/64` + CustomerInterfaceIpv6 *string `mandatory:"false" json:"customerInterfaceIpv6"` + + // If the tunnel's `routing` attribute is set to `BGP` + // (see IPSecConnectionTunnel), this ASN + // is required and used for the tunnel's BGP session. This is the ASN of the network on the + // CPE end of the BGP session. Can be a 2-byte or 4-byte ASN. Uses "asplain" format. + // If the tunnel's `routing` attribute is set to `STATIC`, the `customerBgpAsn` must be null. + // Example: `12345` (2-byte) or `1587232876` (4-byte) + CustomerBgpAsn *string `mandatory:"false" json:"customerBgpAsn"` +} + +func (m CreateIpSecTunnelBgpSessionDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_tunnel_encryption_domain_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_tunnel_encryption_domain_details.go new file mode 100644 index 000000000..ab26712c1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ip_sec_tunnel_encryption_domain_details.go @@ -0,0 +1,34 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateIpSecTunnelEncryptionDomainDetails Request to enable a multi-encryption domain policy on the IPSec tunnel. +// There can't be more than 50 security associations in use at one time. See Encryption domain for policy-based +// tunnels (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/ipsecencryptiondomains.htm#spi_policy_based_tunnel) for more. +type CreateIpSecTunnelEncryptionDomainDetails struct { + + // Lists IPv4 or IPv6-enabled subnets in your Oracle tenancy. + OracleTrafficSelector []string `mandatory:"false" json:"oracleTrafficSelector"` + + // Lists IPv4 or IPv6-enabled subnets in your on-premises network. + CpeTrafficSelector []string `mandatory:"false" json:"cpeTrafficSelector"` +} + +func (m CreateIpSecTunnelEncryptionDomainDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ipv6_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ipv6_details.go new file mode 100644 index 000000000..75e067887 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ipv6_details.go @@ -0,0 +1,51 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateIpv6Details The representation of CreateIpv6Details +type CreateIpv6Details struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VNIC to assign the IPv6 to. The + // IPv6 will be in the VNIC's subnet. + VnicId *string `mandatory:"true" json:"vnicId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // An IPv6 address of your choice. Must be an available IP address within + // the subnet's CIDR. If you don't specify a value, Oracle automatically + // assigns an IPv6 address from the subnet. The subnet is the one that + // contains the VNIC you specify in `vnicId`. + // Example: `2001:DB8::` + IpAddress *string `mandatory:"false" json:"ipAddress"` +} + +func (m CreateIpv6Details) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ipv6_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ipv6_request_response.go new file mode 100644 index 000000000..08446ab3f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_ipv6_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateIpv6Request wrapper for the CreateIpv6 operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateIpv6.go.html to see an example of how to use CreateIpv6Request. +type CreateIpv6Request struct { + + // Create IPv6 details. + CreateIpv6Details `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateIpv6Request) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateIpv6Request) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateIpv6Request) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateIpv6Request) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateIpv6Response wrapper for the CreateIpv6 operation +type CreateIpv6Response struct { + + // The underlying http response + RawResponse *http.Response + + // The Ipv6 instance + Ipv6 `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateIpv6Response) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateIpv6Response) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_local_peering_gateway_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_local_peering_gateway_details.go new file mode 100644 index 000000000..f8caab9b4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_local_peering_gateway_details.go @@ -0,0 +1,54 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateLocalPeeringGatewayDetails The representation of CreateLocalPeeringGatewayDetails +type CreateLocalPeeringGatewayDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the local peering gateway (LPG). + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN the LPG belongs to. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route table the LPG will use. + // If you don't specify a route table here, the LPG is created without an associated route + // table. The Networking service does NOT automatically associate the attached VCN's default route table + // with the LPG. + // For information about why you would associate a route table with an LPG, see + // Transit Routing: Access to Multiple VCNs in Same Region (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitrouting.htm). + RouteTableId *string `mandatory:"false" json:"routeTableId"` +} + +func (m CreateLocalPeeringGatewayDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_local_peering_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_local_peering_gateway_request_response.go new file mode 100644 index 000000000..715052ddf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_local_peering_gateway_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateLocalPeeringGatewayRequest wrapper for the CreateLocalPeeringGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateLocalPeeringGateway.go.html to see an example of how to use CreateLocalPeeringGatewayRequest. +type CreateLocalPeeringGatewayRequest struct { + + // Details for creating a new local peering gateway. + CreateLocalPeeringGatewayDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateLocalPeeringGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateLocalPeeringGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateLocalPeeringGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateLocalPeeringGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateLocalPeeringGatewayResponse wrapper for the CreateLocalPeeringGateway operation +type CreateLocalPeeringGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The LocalPeeringGateway instance + LocalPeeringGateway `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateLocalPeeringGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateLocalPeeringGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_macsec_key.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_macsec_key.go new file mode 100644 index 000000000..2f5433d36 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_macsec_key.go @@ -0,0 +1,34 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateMacsecKey Defines the secret OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)s held in Vault that represent the MACsec key. +type CreateMacsecKey struct { + + // Secret OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) containing the Connectivity association Key Name (CKN) of this MACsec key. + // NOTE: Only the latest secret version will be used. + ConnectivityAssociationNameSecretId *string `mandatory:"true" json:"connectivityAssociationNameSecretId"` + + // Secret OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) containing the Connectivity Association Key (CAK) of this MACsec key. + // NOTE: Only the latest secret version will be used. + ConnectivityAssociationKeySecretId *string `mandatory:"true" json:"connectivityAssociationKeySecretId"` +} + +func (m CreateMacsecKey) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_macsec_properties.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_macsec_properties.go new file mode 100644 index 000000000..0037672dd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_macsec_properties.go @@ -0,0 +1,34 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateMacsecProperties Properties used to configure MACsec (if capable). +type CreateMacsecProperties struct { + + // Indicates whether or not MACsec is enabled. + State MacsecStateEnum `mandatory:"true" json:"state"` + + PrimaryKey *CreateMacsecKey `mandatory:"false" json:"primaryKey"` + + // Type of encryption cipher suite to use for the MACsec connection. + EncryptionCipher MacsecEncryptionCipherEnum `mandatory:"false" json:"encryptionCipher,omitempty"` +} + +func (m CreateMacsecProperties) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_nat_gateway_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_nat_gateway_details.go new file mode 100644 index 000000000..579892152 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_nat_gateway_details.go @@ -0,0 +1,54 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateNatGatewayDetails The representation of CreateNatGatewayDetails +type CreateNatGatewayDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the + // NAT gateway. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN the gateway belongs to. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Whether the NAT gateway blocks traffic through it. The default is `false`. + // Example: `true` + BlockTraffic *bool `mandatory:"false" json:"blockTraffic"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the public IP address associated with the NAT gateway. + PublicIpId *string `mandatory:"false" json:"publicIpId"` +} + +func (m CreateNatGatewayDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_nat_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_nat_gateway_request_response.go new file mode 100644 index 000000000..8c5338094 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_nat_gateway_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateNatGatewayRequest wrapper for the CreateNatGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateNatGateway.go.html to see an example of how to use CreateNatGatewayRequest. +type CreateNatGatewayRequest struct { + + // Details for creating a NAT gateway. + CreateNatGatewayDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateNatGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateNatGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateNatGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateNatGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateNatGatewayResponse wrapper for the CreateNatGateway operation +type CreateNatGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The NatGateway instance + NatGateway `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateNatGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateNatGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_network_security_group_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_network_security_group_details.go new file mode 100644 index 000000000..a941abe7b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_network_security_group_details.go @@ -0,0 +1,48 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateNetworkSecurityGroupDetails The representation of CreateNetworkSecurityGroupDetails +type CreateNetworkSecurityGroupDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the + // network security group. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN to create the network + // security group in. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CreateNetworkSecurityGroupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_network_security_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_network_security_group_request_response.go new file mode 100644 index 000000000..601f1857d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_network_security_group_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateNetworkSecurityGroupRequest wrapper for the CreateNetworkSecurityGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateNetworkSecurityGroup.go.html to see an example of how to use CreateNetworkSecurityGroupRequest. +type CreateNetworkSecurityGroupRequest struct { + + // Details for creating a network security group. + CreateNetworkSecurityGroupDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateNetworkSecurityGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateNetworkSecurityGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateNetworkSecurityGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateNetworkSecurityGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateNetworkSecurityGroupResponse wrapper for the CreateNetworkSecurityGroup operation +type CreateNetworkSecurityGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The NetworkSecurityGroup instance + NetworkSecurityGroup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateNetworkSecurityGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateNetworkSecurityGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_private_ip_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_private_ip_details.go new file mode 100644 index 000000000..1ea6cf707 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_private_ip_details.go @@ -0,0 +1,66 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreatePrivateIpDetails The representation of CreatePrivateIpDetails +type CreatePrivateIpDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The hostname for the private IP. Used for DNS. The value + // is the hostname portion of the private IP's fully qualified domain name (FQDN) + // (for example, `bminstance-1` in FQDN `bminstance-1.subnet123.vcn1.oraclevcn.com`). + // Must be unique across all VNICs in the subnet and comply with + // RFC 952 (https://tools.ietf.org/html/rfc952) and + // RFC 1123 (https://tools.ietf.org/html/rfc1123). + // For more information, see + // DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). + // Example: `bminstance-1` + HostnameLabel *string `mandatory:"false" json:"hostnameLabel"` + + // A private IP address of your choice. Must be an available IP address within + // the subnet's CIDR. If you don't specify a value, Oracle automatically + // assigns a private IP address from the subnet. + // Example: `10.0.3.3` + IpAddress *string `mandatory:"false" json:"ipAddress"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VNIC to assign the private IP to. The VNIC and private IP + // must be in the same subnet. + VnicId *string `mandatory:"false" json:"vnicId"` + + // Use this attribute only with the Oracle Cloud VMware Solution. + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VLAN from which the private IP is to be drawn. The IP address, + // *if supplied*, must be valid for the given VLAN. See Vlan. + VlanId *string `mandatory:"false" json:"vlanId"` +} + +func (m CreatePrivateIpDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_private_ip_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_private_ip_request_response.go new file mode 100644 index 000000000..82bf82ee1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_private_ip_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreatePrivateIpRequest wrapper for the CreatePrivateIp operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreatePrivateIp.go.html to see an example of how to use CreatePrivateIpRequest. +type CreatePrivateIpRequest struct { + + // Create private IP details. + CreatePrivateIpDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreatePrivateIpRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreatePrivateIpRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreatePrivateIpRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreatePrivateIpRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreatePrivateIpResponse wrapper for the CreatePrivateIp operation +type CreatePrivateIpResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The PrivateIp instance + PrivateIp `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreatePrivateIpResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreatePrivateIpResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_details.go new file mode 100644 index 000000000..e3f8e5261 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_details.go @@ -0,0 +1,83 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreatePublicIpDetails The representation of CreatePublicIpDetails +type CreatePublicIpDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the public IP. For ephemeral public IPs, + // you must set this to the private IP's compartment OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // Defines when the public IP is deleted and released back to the Oracle Cloud + // Infrastructure public IP pool. For more information, see + // Public IP Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingpublicIPs.htm). + Lifetime CreatePublicIpDetailsLifetimeEnum `mandatory:"true" json:"lifetime"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the private IP to assign the public IP to. + // Required for an ephemeral public IP because it must always be assigned to a private IP + // (specifically a *primary* private IP). + // Optional for a reserved public IP. If you don't provide it, the public IP is created but not + // assigned to a private IP. You can later assign the public IP with + // UpdatePublicIp. + PrivateIpId *string `mandatory:"false" json:"privateIpId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the public IP pool. + PublicIpPoolId *string `mandatory:"false" json:"publicIpPoolId"` +} + +func (m CreatePublicIpDetails) String() string { + return common.PointerString(m) +} + +// CreatePublicIpDetailsLifetimeEnum Enum with underlying type: string +type CreatePublicIpDetailsLifetimeEnum string + +// Set of constants representing the allowable values for CreatePublicIpDetailsLifetimeEnum +const ( + CreatePublicIpDetailsLifetimeEphemeral CreatePublicIpDetailsLifetimeEnum = "EPHEMERAL" + CreatePublicIpDetailsLifetimeReserved CreatePublicIpDetailsLifetimeEnum = "RESERVED" +) + +var mappingCreatePublicIpDetailsLifetime = map[string]CreatePublicIpDetailsLifetimeEnum{ + "EPHEMERAL": CreatePublicIpDetailsLifetimeEphemeral, + "RESERVED": CreatePublicIpDetailsLifetimeReserved, +} + +// GetCreatePublicIpDetailsLifetimeEnumValues Enumerates the set of values for CreatePublicIpDetailsLifetimeEnum +func GetCreatePublicIpDetailsLifetimeEnumValues() []CreatePublicIpDetailsLifetimeEnum { + values := make([]CreatePublicIpDetailsLifetimeEnum, 0) + for _, v := range mappingCreatePublicIpDetailsLifetime { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_pool_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_pool_details.go new file mode 100644 index 000000000..1abead763 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_pool_details.go @@ -0,0 +1,43 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreatePublicIpPoolDetails The information used to create a public IP pool. +type CreatePublicIpPoolDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the public IP pool. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CreatePublicIpPoolDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_pool_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_pool_request_response.go new file mode 100644 index 000000000..ef1538366 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_pool_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreatePublicIpPoolRequest wrapper for the CreatePublicIpPool operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreatePublicIpPool.go.html to see an example of how to use CreatePublicIpPoolRequest. +type CreatePublicIpPoolRequest struct { + + // Create Public Ip Pool details + CreatePublicIpPoolDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreatePublicIpPoolRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreatePublicIpPoolRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreatePublicIpPoolRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreatePublicIpPoolRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreatePublicIpPoolResponse wrapper for the CreatePublicIpPool operation +type CreatePublicIpPoolResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The PublicIpPool instance + PublicIpPool `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreatePublicIpPoolResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreatePublicIpPoolResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_request_response.go new file mode 100644 index 000000000..f6ca72547 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_public_ip_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreatePublicIpRequest wrapper for the CreatePublicIp operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreatePublicIp.go.html to see an example of how to use CreatePublicIpRequest. +type CreatePublicIpRequest struct { + + // Create public IP details. + CreatePublicIpDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreatePublicIpRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreatePublicIpRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreatePublicIpRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreatePublicIpRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreatePublicIpResponse wrapper for the CreatePublicIp operation +type CreatePublicIpResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The PublicIp instance + PublicIp `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreatePublicIpResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreatePublicIpResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_remote_peering_connection_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_remote_peering_connection_details.go new file mode 100644 index 000000000..99cfc35eb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_remote_peering_connection_details.go @@ -0,0 +1,46 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateRemotePeeringConnectionDetails The representation of CreateRemotePeeringConnectionDetails +type CreateRemotePeeringConnectionDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the RPC. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG the RPC belongs to. + DrgId *string `mandatory:"true" json:"drgId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CreateRemotePeeringConnectionDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_remote_peering_connection_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_remote_peering_connection_request_response.go new file mode 100644 index 000000000..e58a6cbec --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_remote_peering_connection_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateRemotePeeringConnectionRequest wrapper for the CreateRemotePeeringConnection operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateRemotePeeringConnection.go.html to see an example of how to use CreateRemotePeeringConnectionRequest. +type CreateRemotePeeringConnectionRequest struct { + + // Request to create peering connection to remote region + CreateRemotePeeringConnectionDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateRemotePeeringConnectionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateRemotePeeringConnectionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateRemotePeeringConnectionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateRemotePeeringConnectionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateRemotePeeringConnectionResponse wrapper for the CreateRemotePeeringConnection operation +type CreateRemotePeeringConnectionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The RemotePeeringConnection instance + RemotePeeringConnection `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateRemotePeeringConnectionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateRemotePeeringConnectionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_route_table_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_route_table_details.go new file mode 100644 index 000000000..55d5915df --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_route_table_details.go @@ -0,0 +1,49 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateRouteTableDetails The representation of CreateRouteTableDetails +type CreateRouteTableDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the route table. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The collection of rules used for routing destination IPs to network devices. + RouteRules []RouteRule `mandatory:"true" json:"routeRules"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN the route table belongs to. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CreateRouteTableDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_route_table_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_route_table_request_response.go new file mode 100644 index 000000000..85f81f1ba --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_route_table_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateRouteTableRequest wrapper for the CreateRouteTable operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateRouteTable.go.html to see an example of how to use CreateRouteTableRequest. +type CreateRouteTableRequest struct { + + // Details for creating a new route table. + CreateRouteTableDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateRouteTableRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateRouteTableRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateRouteTableRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateRouteTableRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateRouteTableResponse wrapper for the CreateRouteTable operation +type CreateRouteTableResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The RouteTable instance + RouteTable `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateRouteTableResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateRouteTableResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_security_list_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_security_list_details.go new file mode 100644 index 000000000..9d824a4fe --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_security_list_details.go @@ -0,0 +1,52 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateSecurityListDetails The representation of CreateSecurityListDetails +type CreateSecurityListDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the security list. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // Rules for allowing egress IP packets. + EgressSecurityRules []EgressSecurityRule `mandatory:"true" json:"egressSecurityRules"` + + // Rules for allowing ingress IP packets. + IngressSecurityRules []IngressSecurityRule `mandatory:"true" json:"ingressSecurityRules"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN the security list belongs to. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CreateSecurityListDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_security_list_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_security_list_request_response.go new file mode 100644 index 000000000..0c6562e2c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_security_list_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateSecurityListRequest wrapper for the CreateSecurityList operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateSecurityList.go.html to see an example of how to use CreateSecurityListRequest. +type CreateSecurityListRequest struct { + + // Details regarding the security list to create. + CreateSecurityListDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateSecurityListRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateSecurityListRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateSecurityListRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateSecurityListRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateSecurityListResponse wrapper for the CreateSecurityList operation +type CreateSecurityListResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The SecurityList instance + SecurityList `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateSecurityListResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateSecurityListResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_service_gateway_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_service_gateway_details.go new file mode 100644 index 000000000..304d1a79d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_service_gateway_details.go @@ -0,0 +1,64 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateServiceGatewayDetails The representation of CreateServiceGatewayDetails +type CreateServiceGatewayDetails struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the compartment to contain the service gateway. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // List of the OCIDs of the Service objects to + // enable for the service gateway. This list can be empty if you don't want to enable any + // `Service` objects when you create the gateway. You can enable a `Service` + // object later by using either AttachServiceId + // or UpdateServiceGateway. + // For each enabled `Service`, make sure there's a route rule with the `Service` object's `cidrBlock` + // as the rule's destination and the service gateway as the rule's target. See + // RouteTable. + Services []ServiceIdRequestDetails `mandatory:"true" json:"services"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route table the service gateway will use. + // If you don't specify a route table here, the service gateway is created without an associated route + // table. The Networking service does NOT automatically associate the attached VCN's default route table + // with the service gateway. + // For information about why you would associate a route table with a service gateway, see + // Transit Routing: Private Access to Oracle Services (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitroutingoracleservices.htm). + RouteTableId *string `mandatory:"false" json:"routeTableId"` +} + +func (m CreateServiceGatewayDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_service_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_service_gateway_request_response.go new file mode 100644 index 000000000..5b35c0e2b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_service_gateway_request_response.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateServiceGatewayRequest wrapper for the CreateServiceGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateServiceGateway.go.html to see an example of how to use CreateServiceGatewayRequest. +type CreateServiceGatewayRequest struct { + + // Details for creating a service gateway. + CreateServiceGatewayDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateServiceGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateServiceGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateServiceGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateServiceGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateServiceGatewayResponse wrapper for the CreateServiceGateway operation +type CreateServiceGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ServiceGateway instance + ServiceGateway `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateServiceGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateServiceGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_subnet_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_subnet_details.go new file mode 100644 index 000000000..842660e0f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_subnet_details.go @@ -0,0 +1,119 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateSubnetDetails The representation of CreateSubnetDetails +type CreateSubnetDetails struct { + + // The CIDR IP address range of the subnet. The CIDR must maintain the following rules - + // a. The CIDR block is valid and correctly formatted. + // b. The new range is within one of the parent VCN ranges. + // Example: `10.0.1.0/24` + CidrBlock *string `mandatory:"true" json:"cidrBlock"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the subnet. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN to contain the subnet. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Controls whether the subnet is regional or specific to an availability domain. Oracle + // recommends creating regional subnets because they're more flexible and make it easier to + // implement failover across availability domains. Originally, AD-specific subnets were the + // only kind available to use. + // To create a regional subnet, omit this attribute. Then any resources later created in this + // subnet (such as a Compute instance) can be created in any availability domain in the region. + // To instead create an AD-specific subnet, set this attribute to the availability domain you + // want this subnet to be in. Then any resources later created in this subnet can only be + // created in that availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" json:"availabilityDomain"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the set of DHCP options the subnet will use. If you don't + // provide a value, the subnet uses the VCN's default set of DHCP options. + DhcpOptionsId *string `mandatory:"false" json:"dhcpOptionsId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // A DNS label for the subnet, used in conjunction with the VNIC's hostname and + // VCN's DNS label to form a fully qualified domain name (FQDN) for each VNIC + // within this subnet (for example, `bminstance-1.subnet123.vcn1.oraclevcn.com`). + // Must be an alphanumeric string that begins with a letter and is unique within the VCN. + // The value cannot be changed. + // This value must be set if you want to use the Internet and VCN Resolver to resolve the + // hostnames of instances in the subnet. It can only be set if the VCN itself + // was created with a DNS label. + // For more information, see + // DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). + // Example: `subnet123` + DnsLabel *string `mandatory:"false" json:"dnsLabel"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Use this to enable IPv6 addressing for this subnet. The VCN must be enabled for IPv6. + // You can't change this subnet characteristic later. All subnets are /64 in size. The subnet + // portion of the IPv6 address is the fourth hextet from the left (1111 in the following example). + // For important details about IPv6 addressing in a VCN, see IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // Example: `2001:0db8:0123:1111::/64` + Ipv6CidrBlock *string `mandatory:"false" json:"ipv6CidrBlock"` + + // Whether to disallow ingress internet traffic to VNICs within this subnet. Defaults to false. + // For IPv6, if `prohibitInternetIngress` is set to `true`, internet access is not allowed for any + // IPv6s assigned to VNICs in the subnet. Otherwise, ingress internet traffic is allowed by default. + // `prohibitPublicIpOnVnic` will be set to the value of `prohibitInternetIngress` to dictate IPv4 + // behavior in this subnet. Only one or the other flag should be specified. + // Example: `true` + ProhibitInternetIngress *bool `mandatory:"false" json:"prohibitInternetIngress"` + + // Whether VNICs within this subnet can have public IP addresses. + // Defaults to false, which means VNICs created in this subnet will + // automatically be assigned public IP addresses unless specified + // otherwise during instance launch or VNIC creation (with the + // `assignPublicIp` flag in CreateVnicDetails). + // If `prohibitPublicIpOnVnic` is set to true, VNICs created in this + // subnet cannot have public IP addresses (that is, it's a private + // subnet). + // If you intend to use an IPv6 CIDR block, you should use the flag `prohibitInternetIngress` to + // specify ingress internet traffic behavior of the subnet. + // Example: `true` + ProhibitPublicIpOnVnic *bool `mandatory:"false" json:"prohibitPublicIpOnVnic"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route table the subnet will use. If you don't provide a value, + // the subnet uses the VCN's default route table. + RouteTableId *string `mandatory:"false" json:"routeTableId"` + + // The OCIDs of the security list or lists the subnet will use. If you don't + // provide a value, the subnet uses the VCN's default security list. + // Remember that security lists are associated *with the subnet*, but the + // rules are applied to the individual VNICs in the subnet. + SecurityListIds []string `mandatory:"false" json:"securityListIds"` +} + +func (m CreateSubnetDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_subnet_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_subnet_request_response.go new file mode 100644 index 000000000..290950c18 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_subnet_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateSubnetRequest wrapper for the CreateSubnet operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateSubnet.go.html to see an example of how to use CreateSubnetRequest. +type CreateSubnetRequest struct { + + // Details for creating a subnet. + CreateSubnetDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateSubnetRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateSubnetRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateSubnetRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateSubnetRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateSubnetResponse wrapper for the CreateSubnet operation +type CreateSubnetResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Subnet instance + Subnet `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateSubnetResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateSubnetResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_vcn_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_vcn_details.go new file mode 100644 index 000000000..1ebd99892 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_vcn_details.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateVcnDetails The representation of CreateVcnDetails +type CreateVcnDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the VCN. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // **Deprecated.** Do *not* set this value. Use `cidrBlocks` instead. + // Example: `10.0.0.0/16` + CidrBlock *string `mandatory:"false" json:"cidrBlock"` + + // The list of one or more IPv4 CIDR blocks for the VCN that meet the following criteria: + // - The CIDR blocks must be valid. + // - They must not overlap with each other or with the on-premises network CIDR block. + // - The number of CIDR blocks must not exceed the limit of CIDR blocks allowed per VCN. + // **Important:** Do *not* specify a value for `cidrBlock`. Use this parameter instead. + CidrBlocks []string `mandatory:"false" json:"cidrBlocks"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // A DNS label for the VCN, used in conjunction with the VNIC's hostname and + // subnet's DNS label to form a fully qualified domain name (FQDN) for each VNIC + // within this subnet (for example, `bminstance-1.subnet123.vcn1.oraclevcn.com`). + // Not required to be unique, but it's a best practice to set unique DNS labels + // for VCNs in your tenancy. Must be an alphanumeric string that begins with a letter. + // The value cannot be changed. + // You must set this value if you want instances to be able to use hostnames to + // resolve other instances in the VCN. Otherwise the Internet and VCN Resolver + // will not work. + // For more information, see + // DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). + // Example: `vcn1` + DnsLabel *string `mandatory:"false" json:"dnsLabel"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Whether IPv6 is enabled for the VCN. Default is `false`. + // If enabled, Oracle will assign the VCN a IPv6 /56 CIDR block. + // For important details about IPv6 addressing in a VCN, see IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // Example: `true` + IsIpv6Enabled *bool `mandatory:"false" json:"isIpv6Enabled"` +} + +func (m CreateVcnDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_vcn_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_vcn_request_response.go new file mode 100644 index 000000000..d3f66e0a4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_vcn_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateVcnRequest wrapper for the CreateVcn operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVcn.go.html to see an example of how to use CreateVcnRequest. +type CreateVcnRequest struct { + + // Details for creating a new VCN. + CreateVcnDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateVcnRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateVcnRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateVcnRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateVcnRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateVcnResponse wrapper for the CreateVcn operation +type CreateVcnResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Vcn instance + Vcn `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateVcnResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateVcnResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_virtual_circuit_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_virtual_circuit_details.go new file mode 100644 index 000000000..a38c1e7e7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_virtual_circuit_details.go @@ -0,0 +1,159 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateVirtualCircuitDetails The representation of CreateVirtualCircuitDetails +type CreateVirtualCircuitDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the virtual circuit. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The type of IP addresses used in this virtual circuit. PRIVATE + // means RFC 1918 (https://tools.ietf.org/html/rfc1918) addresses + // (10.0.0.0/8, 172.16/12, and 192.168/16). + Type CreateVirtualCircuitDetailsTypeEnum `mandatory:"true" json:"type"` + + // The provisioned data rate of the connection. To get a list of the + // available bandwidth levels (that is, shapes), see + // ListFastConnectProviderVirtualCircuitBandwidthShapes. + // Example: `10 Gbps` + BandwidthShapeName *string `mandatory:"false" json:"bandwidthShapeName"` + + // Create a `CrossConnectMapping` for each cross-connect or cross-connect + // group this virtual circuit will run on. + CrossConnectMappings []CrossConnectMapping `mandatory:"false" json:"crossConnectMappings"` + + // The routing policy sets how routing information about the Oracle cloud is shared over a public virtual circuit. + // Policies available are: `ORACLE_SERVICE_NETWORK`, `REGIONAL`, `MARKET_LEVEL`, and `GLOBAL`. + // See Route Filtering (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/routingonprem.htm#route_filtering) for details. + // By default, routing information is shared for all routes in the same market. + RoutingPolicy []CreateVirtualCircuitDetailsRoutingPolicyEnum `mandatory:"false" json:"routingPolicy,omitempty"` + + // Deprecated. Instead use `customerAsn`. + // If you specify values for both, the request will be rejected. + CustomerBgpAsn *int `mandatory:"false" json:"customerBgpAsn"` + + // Your BGP ASN (either public or private). Provide this value only if + // there's a BGP session that goes from your edge router to Oracle. + // Otherwise, leave this empty or null. + // Can be a 2-byte or 4-byte ASN. Uses "asplain" format. + // Example: `12345` (2-byte) or `1587232876` (4-byte) + CustomerAsn *int64 `mandatory:"false" json:"customerAsn"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // For private virtual circuits only. The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the Drg + // that this virtual circuit uses. + GatewayId *string `mandatory:"false" json:"gatewayId"` + + // Deprecated. Instead use `providerServiceId`. + // To get a list of the provider names, see + // ListFastConnectProviderServices. + ProviderName *string `mandatory:"false" json:"providerName"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the service offered by the provider (if you're connecting + // via a provider). To get a list of the available service offerings, see + // ListFastConnectProviderServices. + ProviderServiceId *string `mandatory:"false" json:"providerServiceId"` + + // The service key name offered by the provider (if the customer is connecting via a provider). + ProviderServiceKeyName *string `mandatory:"false" json:"providerServiceKeyName"` + + // Deprecated. Instead use `providerServiceId`. + // To get a list of the provider names, see + // ListFastConnectProviderServices. + ProviderServiceName *string `mandatory:"false" json:"providerServiceName"` + + // For a public virtual circuit. The public IP prefixes (CIDRs) the customer wants to + // advertise across the connection. + PublicPrefixes []CreateVirtualCircuitPublicPrefixDetails `mandatory:"false" json:"publicPrefixes"` + + // The Oracle Cloud Infrastructure region where this virtual + // circuit is located. + // Example: `phx` + Region *string `mandatory:"false" json:"region"` + + // The layer 3 IP MTU to use with this virtual circuit. + IpMtu VirtualCircuitIpMtuEnum `mandatory:"false" json:"ipMtu,omitempty"` +} + +func (m CreateVirtualCircuitDetails) String() string { + return common.PointerString(m) +} + +// CreateVirtualCircuitDetailsRoutingPolicyEnum Enum with underlying type: string +type CreateVirtualCircuitDetailsRoutingPolicyEnum string + +// Set of constants representing the allowable values for CreateVirtualCircuitDetailsRoutingPolicyEnum +const ( + CreateVirtualCircuitDetailsRoutingPolicyOracleServiceNetwork CreateVirtualCircuitDetailsRoutingPolicyEnum = "ORACLE_SERVICE_NETWORK" + CreateVirtualCircuitDetailsRoutingPolicyRegional CreateVirtualCircuitDetailsRoutingPolicyEnum = "REGIONAL" + CreateVirtualCircuitDetailsRoutingPolicyMarketLevel CreateVirtualCircuitDetailsRoutingPolicyEnum = "MARKET_LEVEL" + CreateVirtualCircuitDetailsRoutingPolicyGlobal CreateVirtualCircuitDetailsRoutingPolicyEnum = "GLOBAL" +) + +var mappingCreateVirtualCircuitDetailsRoutingPolicy = map[string]CreateVirtualCircuitDetailsRoutingPolicyEnum{ + "ORACLE_SERVICE_NETWORK": CreateVirtualCircuitDetailsRoutingPolicyOracleServiceNetwork, + "REGIONAL": CreateVirtualCircuitDetailsRoutingPolicyRegional, + "MARKET_LEVEL": CreateVirtualCircuitDetailsRoutingPolicyMarketLevel, + "GLOBAL": CreateVirtualCircuitDetailsRoutingPolicyGlobal, +} + +// GetCreateVirtualCircuitDetailsRoutingPolicyEnumValues Enumerates the set of values for CreateVirtualCircuitDetailsRoutingPolicyEnum +func GetCreateVirtualCircuitDetailsRoutingPolicyEnumValues() []CreateVirtualCircuitDetailsRoutingPolicyEnum { + values := make([]CreateVirtualCircuitDetailsRoutingPolicyEnum, 0) + for _, v := range mappingCreateVirtualCircuitDetailsRoutingPolicy { + values = append(values, v) + } + return values +} + +// CreateVirtualCircuitDetailsTypeEnum Enum with underlying type: string +type CreateVirtualCircuitDetailsTypeEnum string + +// Set of constants representing the allowable values for CreateVirtualCircuitDetailsTypeEnum +const ( + CreateVirtualCircuitDetailsTypePublic CreateVirtualCircuitDetailsTypeEnum = "PUBLIC" + CreateVirtualCircuitDetailsTypePrivate CreateVirtualCircuitDetailsTypeEnum = "PRIVATE" +) + +var mappingCreateVirtualCircuitDetailsType = map[string]CreateVirtualCircuitDetailsTypeEnum{ + "PUBLIC": CreateVirtualCircuitDetailsTypePublic, + "PRIVATE": CreateVirtualCircuitDetailsTypePrivate, +} + +// GetCreateVirtualCircuitDetailsTypeEnumValues Enumerates the set of values for CreateVirtualCircuitDetailsTypeEnum +func GetCreateVirtualCircuitDetailsTypeEnumValues() []CreateVirtualCircuitDetailsTypeEnum { + values := make([]CreateVirtualCircuitDetailsTypeEnum, 0) + for _, v := range mappingCreateVirtualCircuitDetailsType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_virtual_circuit_public_prefix_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_virtual_circuit_public_prefix_details.go new file mode 100644 index 000000000..579208061 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_virtual_circuit_public_prefix_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateVirtualCircuitPublicPrefixDetails The representation of CreateVirtualCircuitPublicPrefixDetails +type CreateVirtualCircuitPublicPrefixDetails struct { + + // An individual public IP prefix (CIDR) to add to the public virtual circuit. + // All prefix sizes are allowed. + CidrBlock *string `mandatory:"true" json:"cidrBlock"` +} + +func (m CreateVirtualCircuitPublicPrefixDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_virtual_circuit_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_virtual_circuit_request_response.go new file mode 100644 index 000000000..c32dddc0f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_virtual_circuit_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateVirtualCircuitRequest wrapper for the CreateVirtualCircuit operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVirtualCircuit.go.html to see an example of how to use CreateVirtualCircuitRequest. +type CreateVirtualCircuitRequest struct { + + // Details to create a VirtualCircuit. + CreateVirtualCircuitDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateVirtualCircuitRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateVirtualCircuitRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateVirtualCircuitRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateVirtualCircuitRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateVirtualCircuitResponse wrapper for the CreateVirtualCircuit operation +type CreateVirtualCircuitResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VirtualCircuit instance + VirtualCircuit `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateVirtualCircuitResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateVirtualCircuitResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_vlan_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_vlan_details.go new file mode 100644 index 000000000..6bdee1e1c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_vlan_details.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateVlanDetails The representation of CreateVlanDetails +type CreateVlanDetails struct { + + // The range of IPv4 addresses that will be used for layer 3 communication with + // hosts outside the VLAN. The CIDR must maintain the following rules - + // 1. The CIDR block is valid and correctly formatted. + // 2. The new range is within one of the parent VCN ranges. + // Example: `192.0.2.0/24` + CidrBlock *string `mandatory:"true" json:"cidrBlock"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment to contain the VLAN. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN to contain the VLAN. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Controls whether the VLAN is regional or specific to an availability domain. + // A regional VLAN has the flexibility to implement failover across availability domains. + // Previously, all VLANs were AD-specific. + // To create a regional VLAN, omit this attribute. Resources created subsequently in this + // VLAN (such as a Compute instance) can be created in any availability domain in the region. + // To create an AD-specific VLAN, use this attribute to specify the availability domain. + // Resources created in this VLAN must be in that availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" json:"availabilityDomain"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // A list of the OCIDs of the network security groups (NSGs) to add all VNICs in the VLAN to. For more + // information about NSGs, see + // NetworkSecurityGroup. + NsgIds []string `mandatory:"false" json:"nsgIds"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route table the VLAN will use. If you don't provide a value, + // the VLAN uses the VCN's default route table. + RouteTableId *string `mandatory:"false" json:"routeTableId"` + + // The IEEE 802.1Q VLAN tag for this VLAN. The value must be unique across all + // VLANs in the VCN. If you don't provide a value, Oracle assigns one. + // You cannot change the value later. VLAN tag 0 is reserved for use by Oracle. + VlanTag *int `mandatory:"false" json:"vlanTag"` +} + +func (m CreateVlanDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_vlan_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_vlan_request_response.go new file mode 100644 index 000000000..6158bace9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_vlan_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateVlanRequest wrapper for the CreateVlan operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVlan.go.html to see an example of how to use CreateVlanRequest. +type CreateVlanRequest struct { + + // Details for creating a VLAN + CreateVlanDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateVlanRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateVlanRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateVlanRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateVlanRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateVlanResponse wrapper for the CreateVlan operation +type CreateVlanResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Vlan instance + Vlan `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateVlanResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateVlanResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_vnic_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_vnic_details.go new file mode 100644 index 000000000..f8e640e4a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_vnic_details.go @@ -0,0 +1,141 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateVnicDetails Contains properties for a VNIC. You use this object when creating the +// primary VNIC during instance launch or when creating a secondary VNIC. +// For more information about VNICs, see +// Virtual Network Interface Cards (VNICs) (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingVNICs.htm). +type CreateVnicDetails struct { + + // Whether the VNIC should be assigned a public IP address. Defaults to whether + // the subnet is public or private. If not set and the VNIC is being created + // in a private subnet (that is, where `prohibitPublicIpOnVnic` = true in the + // Subnet), then no public IP address is assigned. + // If not set and the subnet is public (`prohibitPublicIpOnVnic` = false), then + // a public IP address is assigned. If set to true and + // `prohibitPublicIpOnVnic` = true, an error is returned. + // **Note:** This public IP address is associated with the primary private IP + // on the VNIC. For more information, see + // IP Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingIPaddresses.htm). + // **Note:** There's a limit to the number of PublicIp + // a VNIC or instance can have. If you try to create a secondary VNIC + // with an assigned public IP for an instance that has already + // reached its public IP limit, an error is returned. For information + // about the public IP limits, see + // Public IP Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingpublicIPs.htm). + // Example: `false` + // If you specify a `vlanId`, then `assignPublicIp` must be set to false. See + // Vlan. + AssignPublicIp *bool `mandatory:"false" json:"assignPublicIp"` + + // Whether the VNIC should be assigned a DNS record. If set to false, there will be no DNS record + // registration for the VNIC. If set to true, the DNS record will be registered. The default + // value is true. + // If you specify a `hostnameLabel`, then `assignPrivateDnsRecord` must be set to true. + AssignPrivateDnsRecord *bool `mandatory:"false" json:"assignPrivateDnsRecord"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The hostname for the VNIC's primary private IP. Used for DNS. The value is the hostname + // portion of the primary private IP's fully qualified domain name (FQDN) + // (for example, `bminstance-1` in FQDN `bminstance-1.subnet123.vcn1.oraclevcn.com`). + // Must be unique across all VNICs in the subnet and comply with + // RFC 952 (https://tools.ietf.org/html/rfc952) and + // RFC 1123 (https://tools.ietf.org/html/rfc1123). + // The value appears in the Vnic object and also the + // PrivateIp object returned by + // ListPrivateIps and + // GetPrivateIp. + // For more information, see + // DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). + // When launching an instance, use this `hostnameLabel` instead + // of the deprecated `hostnameLabel` in + // LaunchInstanceDetails. + // If you provide both, the values must match. + // Example: `bminstance-1` + // If you specify a `vlanId`, the `hostnameLabel` cannot be specified. VNICs on a VLAN + // can not be assigned a hostname. See Vlan. + HostnameLabel *string `mandatory:"false" json:"hostnameLabel"` + + // A list of the OCIDs of the network security groups (NSGs) to add the VNIC to. For more + // information about NSGs, see + // NetworkSecurityGroup. + // If a `vlanId` is specified, the `nsgIds` cannot be specified. The `vlanId` + // indicates that the VNIC will belong to a VLAN instead of a subnet. With VLANs, + // all VNICs in the VLAN belong to the NSGs that are associated with the VLAN. + // See Vlan. + NsgIds []string `mandatory:"false" json:"nsgIds"` + + // A private IP address of your choice to assign to the VNIC. Must be an + // available IP address within the subnet's CIDR. If you don't specify a + // value, Oracle automatically assigns a private IP address from the subnet. + // This is the VNIC's *primary* private IP address. The value appears in + // the Vnic object and also the + // PrivateIp object returned by + // ListPrivateIps and + // GetPrivateIp. + // + // If you specify a `vlanId`, the `privateIp` cannot be specified. + // See Vlan. + // Example: `10.0.3.3` + PrivateIp *string `mandatory:"false" json:"privateIp"` + + // Whether the source/destination check is disabled on the VNIC. + // Defaults to `false`, which means the check is performed. For information + // about why you would skip the source/destination check, see + // Using a Private IP as a Route Target (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingroutetables.htm#privateip). + // + // If you specify a `vlanId`, the `skipSourceDestCheck` cannot be specified because the + // source/destination check is always disabled for VNICs in a VLAN. See + // Vlan. + // Example: `true` + SkipSourceDestCheck *bool `mandatory:"false" json:"skipSourceDestCheck"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the subnet to create the VNIC in. When launching an instance, + // use this `subnetId` instead of the deprecated `subnetId` in + // LaunchInstanceDetails. + // At least one of them is required; if you provide both, the values must match. + // If you are an Oracle Cloud VMware Solution customer and creating a secondary + // VNIC in a VLAN instead of a subnet, provide a `vlanId` instead of a `subnetId`. + // If you provide both a `vlanId` and `subnetId`, the request fails. + SubnetId *string `mandatory:"false" json:"subnetId"` + + // Provide this attribute only if you are an Oracle Cloud VMware Solution + // customer and creating a secondary VNIC in a VLAN. The value is the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VLAN. + // See Vlan. + // Provide a `vlanId` instead of a `subnetId`. If you provide both a + // `vlanId` and `subnetId`, the request fails. + VlanId *string `mandatory:"false" json:"vlanId"` +} + +func (m CreateVnicDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_details.go new file mode 100644 index 000000000..c912a6ab3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_details.go @@ -0,0 +1,69 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateVolumeBackupDetails The representation of CreateVolumeBackupDetails +type CreateVolumeBackupDetails struct { + + // The OCID of the volume that needs to be backed up. + VolumeId *string `mandatory:"true" json:"volumeId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The type of backup to create. If omitted, defaults to INCREMENTAL. + Type CreateVolumeBackupDetailsTypeEnum `mandatory:"false" json:"type,omitempty"` +} + +func (m CreateVolumeBackupDetails) String() string { + return common.PointerString(m) +} + +// CreateVolumeBackupDetailsTypeEnum Enum with underlying type: string +type CreateVolumeBackupDetailsTypeEnum string + +// Set of constants representing the allowable values for CreateVolumeBackupDetailsTypeEnum +const ( + CreateVolumeBackupDetailsTypeFull CreateVolumeBackupDetailsTypeEnum = "FULL" + CreateVolumeBackupDetailsTypeIncremental CreateVolumeBackupDetailsTypeEnum = "INCREMENTAL" +) + +var mappingCreateVolumeBackupDetailsType = map[string]CreateVolumeBackupDetailsTypeEnum{ + "FULL": CreateVolumeBackupDetailsTypeFull, + "INCREMENTAL": CreateVolumeBackupDetailsTypeIncremental, +} + +// GetCreateVolumeBackupDetailsTypeEnumValues Enumerates the set of values for CreateVolumeBackupDetailsTypeEnum +func GetCreateVolumeBackupDetailsTypeEnumValues() []CreateVolumeBackupDetailsTypeEnum { + values := make([]CreateVolumeBackupDetailsTypeEnum, 0) + for _, v := range mappingCreateVolumeBackupDetailsType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_assignment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_assignment_details.go new file mode 100644 index 000000000..b4f22c1a2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_assignment_details.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateVolumeBackupPolicyAssignmentDetails The representation of CreateVolumeBackupPolicyAssignmentDetails +type CreateVolumeBackupPolicyAssignmentDetails struct { + + // The OCID of the volume to assign the policy to. + AssetId *string `mandatory:"true" json:"assetId"` + + // The OCID of the volume backup policy to assign to the volume. + PolicyId *string `mandatory:"true" json:"policyId"` +} + +func (m CreateVolumeBackupPolicyAssignmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_assignment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_assignment_request_response.go new file mode 100644 index 000000000..a3752c53b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_assignment_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateVolumeBackupPolicyAssignmentRequest wrapper for the CreateVolumeBackupPolicyAssignment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVolumeBackupPolicyAssignment.go.html to see an example of how to use CreateVolumeBackupPolicyAssignmentRequest. +type CreateVolumeBackupPolicyAssignmentRequest struct { + + // Request to assign a specified policy to a particular volume. + CreateVolumeBackupPolicyAssignmentDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateVolumeBackupPolicyAssignmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateVolumeBackupPolicyAssignmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateVolumeBackupPolicyAssignmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateVolumeBackupPolicyAssignmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateVolumeBackupPolicyAssignmentResponse wrapper for the CreateVolumeBackupPolicyAssignment operation +type CreateVolumeBackupPolicyAssignmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeBackupPolicyAssignment instance + VolumeBackupPolicyAssignment `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateVolumeBackupPolicyAssignmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateVolumeBackupPolicyAssignmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_details.go new file mode 100644 index 000000000..259549dbe --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_details.go @@ -0,0 +1,55 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateVolumeBackupPolicyDetails Specifies the properties for creating user defined backup policy. +// For more information about user defined backup policies, +// see User Defined Policies (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm#UserDefinedBackupPolicies) in +// Policy-Based Backups (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm). +type CreateVolumeBackupPolicyDetails struct { + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The paired destination region for copying scheduled backups to. Example: `us-ashburn-1`. + // See Region Pairs (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm#RegionPairs) for details about paired regions. + DestinationRegion *string `mandatory:"false" json:"destinationRegion"` + + // The collection of schedules for the volume backup policy. See + // see Schedules (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm#schedules) in + // Policy-Based Backups (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm) for more information. + Schedules []VolumeBackupSchedule `mandatory:"false" json:"schedules"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CreateVolumeBackupPolicyDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_request_response.go new file mode 100644 index 000000000..b1b02c77e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_policy_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateVolumeBackupPolicyRequest wrapper for the CreateVolumeBackupPolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVolumeBackupPolicy.go.html to see an example of how to use CreateVolumeBackupPolicyRequest. +type CreateVolumeBackupPolicyRequest struct { + + // Request to create a new scheduled backup policy. + CreateVolumeBackupPolicyDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateVolumeBackupPolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateVolumeBackupPolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateVolumeBackupPolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateVolumeBackupPolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateVolumeBackupPolicyResponse wrapper for the CreateVolumeBackupPolicy operation +type CreateVolumeBackupPolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeBackupPolicy instance + VolumeBackupPolicy `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateVolumeBackupPolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateVolumeBackupPolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_request_response.go new file mode 100644 index 000000000..bfe29bc76 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_backup_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateVolumeBackupRequest wrapper for the CreateVolumeBackup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVolumeBackup.go.html to see an example of how to use CreateVolumeBackupRequest. +type CreateVolumeBackupRequest struct { + + // Request to create a new backup of given volume. + CreateVolumeBackupDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateVolumeBackupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateVolumeBackupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateVolumeBackupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateVolumeBackupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateVolumeBackupResponse wrapper for the CreateVolumeBackup operation +type CreateVolumeBackupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeBackup instance + VolumeBackup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateVolumeBackupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateVolumeBackupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_details.go new file mode 100644 index 000000000..e4c0f6716 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_details.go @@ -0,0 +1,153 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateVolumeDetails The details of the volume to create. For CreateVolume operation, this field is required in the request, +// see CreateVolume. +type CreateVolumeDetails struct { + + // The OCID of the compartment that contains the volume. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The availability domain of the volume. Omissible for cloning a volume. The new volume will be created in the availability domain of the source volume. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" json:"availabilityDomain"` + + // If provided, specifies the ID of the volume backup policy to assign to the newly + // created volume. If omitted, no policy will be assigned. + BackupPolicyId *string `mandatory:"false" json:"backupPolicyId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID of the Key Management key to assign as the master encryption key + // for the volume. + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` + + // The number of volume performance units (VPUs) that will be applied to this volume per GB, + // representing the Block Volume service's elastic performance options. + // See Block Volume Elastic Performance (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/blockvolumeelasticperformance.htm) for more information. + // Allowed values: + // * `0`: Represents Lower Cost option. + // * `10`: Represents Balanced option. + // * `20`: Represents Higher Performance option. + VpusPerGB *int64 `mandatory:"false" json:"vpusPerGB"` + + // The size of the volume in GBs. + SizeInGBs *int64 `mandatory:"false" json:"sizeInGBs"` + + // The size of the volume in MBs. The value must be a multiple of 1024. + // This field is deprecated. Use sizeInGBs instead. + SizeInMBs *int64 `mandatory:"false" json:"sizeInMBs"` + + SourceDetails VolumeSourceDetails `mandatory:"false" json:"sourceDetails"` + + // The OCID of the volume backup from which the data should be restored on the newly created volume. + // This field is deprecated. Use the sourceDetails field instead to specify the + // backup for the volume. + VolumeBackupId *string `mandatory:"false" json:"volumeBackupId"` + + // Specifies whether the auto-tune performance is enabled for this volume. + IsAutoTuneEnabled *bool `mandatory:"false" json:"isAutoTuneEnabled"` + + // The list of block volume replicas to be enabled for this volume + // in the specified destination availability domains. + BlockVolumeReplicas []BlockVolumeReplicaDetails `mandatory:"false" json:"blockVolumeReplicas"` +} + +func (m CreateVolumeDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *CreateVolumeDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + AvailabilityDomain *string `json:"availabilityDomain"` + BackupPolicyId *string `json:"backupPolicyId"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + DisplayName *string `json:"displayName"` + FreeformTags map[string]string `json:"freeformTags"` + KmsKeyId *string `json:"kmsKeyId"` + VpusPerGB *int64 `json:"vpusPerGB"` + SizeInGBs *int64 `json:"sizeInGBs"` + SizeInMBs *int64 `json:"sizeInMBs"` + SourceDetails volumesourcedetails `json:"sourceDetails"` + VolumeBackupId *string `json:"volumeBackupId"` + IsAutoTuneEnabled *bool `json:"isAutoTuneEnabled"` + BlockVolumeReplicas []BlockVolumeReplicaDetails `json:"blockVolumeReplicas"` + CompartmentId *string `json:"compartmentId"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.AvailabilityDomain = model.AvailabilityDomain + + m.BackupPolicyId = model.BackupPolicyId + + m.DefinedTags = model.DefinedTags + + m.DisplayName = model.DisplayName + + m.FreeformTags = model.FreeformTags + + m.KmsKeyId = model.KmsKeyId + + m.VpusPerGB = model.VpusPerGB + + m.SizeInGBs = model.SizeInGBs + + m.SizeInMBs = model.SizeInMBs + + nn, e = model.SourceDetails.UnmarshalPolymorphicJSON(model.SourceDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.SourceDetails = nn.(VolumeSourceDetails) + } else { + m.SourceDetails = nil + } + + m.VolumeBackupId = model.VolumeBackupId + + m.IsAutoTuneEnabled = model.IsAutoTuneEnabled + + m.BlockVolumeReplicas = make([]BlockVolumeReplicaDetails, len(model.BlockVolumeReplicas)) + for i, n := range model.BlockVolumeReplicas { + m.BlockVolumeReplicas[i] = n + } + + m.CompartmentId = model.CompartmentId + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_backup_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_backup_details.go new file mode 100644 index 000000000..a918d75c3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_backup_details.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateVolumeGroupBackupDetails The representation of CreateVolumeGroupBackupDetails +type CreateVolumeGroupBackupDetails struct { + + // The OCID of the volume group that needs to be backed up. + VolumeGroupId *string `mandatory:"true" json:"volumeGroupId"` + + // The OCID of the compartment that will contain the volume group + // backup. This parameter is optional, by default backup will be created in + // the same compartment and source volume group. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The type of backup to create. If omitted, defaults to incremental. + Type CreateVolumeGroupBackupDetailsTypeEnum `mandatory:"false" json:"type,omitempty"` +} + +func (m CreateVolumeGroupBackupDetails) String() string { + return common.PointerString(m) +} + +// CreateVolumeGroupBackupDetailsTypeEnum Enum with underlying type: string +type CreateVolumeGroupBackupDetailsTypeEnum string + +// Set of constants representing the allowable values for CreateVolumeGroupBackupDetailsTypeEnum +const ( + CreateVolumeGroupBackupDetailsTypeFull CreateVolumeGroupBackupDetailsTypeEnum = "FULL" + CreateVolumeGroupBackupDetailsTypeIncremental CreateVolumeGroupBackupDetailsTypeEnum = "INCREMENTAL" +) + +var mappingCreateVolumeGroupBackupDetailsType = map[string]CreateVolumeGroupBackupDetailsTypeEnum{ + "FULL": CreateVolumeGroupBackupDetailsTypeFull, + "INCREMENTAL": CreateVolumeGroupBackupDetailsTypeIncremental, +} + +// GetCreateVolumeGroupBackupDetailsTypeEnumValues Enumerates the set of values for CreateVolumeGroupBackupDetailsTypeEnum +func GetCreateVolumeGroupBackupDetailsTypeEnumValues() []CreateVolumeGroupBackupDetailsTypeEnum { + values := make([]CreateVolumeGroupBackupDetailsTypeEnum, 0) + for _, v := range mappingCreateVolumeGroupBackupDetailsType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_backup_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_backup_request_response.go new file mode 100644 index 000000000..d1935751c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_backup_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateVolumeGroupBackupRequest wrapper for the CreateVolumeGroupBackup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVolumeGroupBackup.go.html to see an example of how to use CreateVolumeGroupBackupRequest. +type CreateVolumeGroupBackupRequest struct { + + // Request to create a new backup group of given volume group. + CreateVolumeGroupBackupDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateVolumeGroupBackupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateVolumeGroupBackupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateVolumeGroupBackupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateVolumeGroupBackupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateVolumeGroupBackupResponse wrapper for the CreateVolumeGroupBackup operation +type CreateVolumeGroupBackupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeGroupBackup instance + VolumeGroupBackup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateVolumeGroupBackupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateVolumeGroupBackupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_details.go new file mode 100644 index 000000000..88c70af24 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_details.go @@ -0,0 +1,95 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateVolumeGroupDetails The representation of CreateVolumeGroupDetails +type CreateVolumeGroupDetails struct { + + // The availability domain of the volume group. + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment that contains the volume group. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + SourceDetails VolumeGroupSourceDetails `mandatory:"true" json:"sourceDetails"` + + // If provided, specifies the ID of the volume backup policy to assign to the newly + // created volume group. If omitted, no policy will be assigned. + BackupPolicyId *string `mandatory:"false" json:"backupPolicyId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m CreateVolumeGroupDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *CreateVolumeGroupDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + BackupPolicyId *string `json:"backupPolicyId"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + DisplayName *string `json:"displayName"` + FreeformTags map[string]string `json:"freeformTags"` + AvailabilityDomain *string `json:"availabilityDomain"` + CompartmentId *string `json:"compartmentId"` + SourceDetails volumegroupsourcedetails `json:"sourceDetails"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.BackupPolicyId = model.BackupPolicyId + + m.DefinedTags = model.DefinedTags + + m.DisplayName = model.DisplayName + + m.FreeformTags = model.FreeformTags + + m.AvailabilityDomain = model.AvailabilityDomain + + m.CompartmentId = model.CompartmentId + + nn, e = model.SourceDetails.UnmarshalPolymorphicJSON(model.SourceDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.SourceDetails = nn.(VolumeGroupSourceDetails) + } else { + m.SourceDetails = nil + } + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_request_response.go new file mode 100644 index 000000000..edb080839 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_group_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateVolumeGroupRequest wrapper for the CreateVolumeGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVolumeGroup.go.html to see an example of how to use CreateVolumeGroupRequest. +type CreateVolumeGroupRequest struct { + + // Request to create a new volume group. + CreateVolumeGroupDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateVolumeGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateVolumeGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateVolumeGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateVolumeGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateVolumeGroupResponse wrapper for the CreateVolumeGroup operation +type CreateVolumeGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeGroup instance + VolumeGroup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateVolumeGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateVolumeGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_request_response.go new file mode 100644 index 000000000..a5cce1f1e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/create_volume_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateVolumeRequest wrapper for the CreateVolume operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/CreateVolume.go.html to see an example of how to use CreateVolumeRequest. +type CreateVolumeRequest struct { + + // Request to create a new volume. + CreateVolumeDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateVolumeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateVolumeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateVolumeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateVolumeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateVolumeResponse wrapper for the CreateVolume operation +type CreateVolumeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Volume instance + Volume `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateVolumeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateVolumeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect.go new file mode 100644 index 000000000..fdec4e1dd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect.go @@ -0,0 +1,115 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CrossConnect For use with Oracle Cloud Infrastructure FastConnect. A cross-connect represents a +// physical connection between an existing network and Oracle. Customers who are colocated +// with Oracle in a FastConnect location create and use cross-connects. For more +// information, see FastConnect Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/fastconnect.htm). +// Oracle recommends you create each cross-connect in a +// CrossConnectGroup so you can use link aggregation +// with the connection. +// **Note:** If you're a provider who is setting up a physical connection to Oracle so customers +// can use FastConnect over the connection, be aware that your connection is modeled the +// same way as a colocated customer's (with `CrossConnect` and `CrossConnectGroup` objects, and so on). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type CrossConnect struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the cross-connect group. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the cross-connect group this cross-connect belongs to (if any). + CrossConnectGroupId *string `mandatory:"false" json:"crossConnectGroupId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The cross-connect's Oracle ID (OCID). + Id *string `mandatory:"false" json:"id"` + + // The cross-connect's current state. + LifecycleState CrossConnectLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The name of the FastConnect location where this cross-connect is installed. + LocationName *string `mandatory:"false" json:"locationName"` + + // A string identifying the meet-me room port for this cross-connect. + PortName *string `mandatory:"false" json:"portName"` + + // The port speed for this cross-connect. + // Example: `10 Gbps` + PortSpeedShapeName *string `mandatory:"false" json:"portSpeedShapeName"` + + // A reference name or identifier for the physical fiber connection that this cross-connect + // uses. + CustomerReferenceName *string `mandatory:"false" json:"customerReferenceName"` + + // The date and time the cross-connect was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + MacsecProperties *MacsecProperties `mandatory:"false" json:"macsecProperties"` +} + +func (m CrossConnect) String() string { + return common.PointerString(m) +} + +// CrossConnectLifecycleStateEnum Enum with underlying type: string +type CrossConnectLifecycleStateEnum string + +// Set of constants representing the allowable values for CrossConnectLifecycleStateEnum +const ( + CrossConnectLifecycleStatePendingCustomer CrossConnectLifecycleStateEnum = "PENDING_CUSTOMER" + CrossConnectLifecycleStateProvisioning CrossConnectLifecycleStateEnum = "PROVISIONING" + CrossConnectLifecycleStateProvisioned CrossConnectLifecycleStateEnum = "PROVISIONED" + CrossConnectLifecycleStateInactive CrossConnectLifecycleStateEnum = "INACTIVE" + CrossConnectLifecycleStateTerminating CrossConnectLifecycleStateEnum = "TERMINATING" + CrossConnectLifecycleStateTerminated CrossConnectLifecycleStateEnum = "TERMINATED" +) + +var mappingCrossConnectLifecycleState = map[string]CrossConnectLifecycleStateEnum{ + "PENDING_CUSTOMER": CrossConnectLifecycleStatePendingCustomer, + "PROVISIONING": CrossConnectLifecycleStateProvisioning, + "PROVISIONED": CrossConnectLifecycleStateProvisioned, + "INACTIVE": CrossConnectLifecycleStateInactive, + "TERMINATING": CrossConnectLifecycleStateTerminating, + "TERMINATED": CrossConnectLifecycleStateTerminated, +} + +// GetCrossConnectLifecycleStateEnumValues Enumerates the set of values for CrossConnectLifecycleStateEnum +func GetCrossConnectLifecycleStateEnumValues() []CrossConnectLifecycleStateEnum { + values := make([]CrossConnectLifecycleStateEnum, 0) + for _, v := range mappingCrossConnectLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_group.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_group.go new file mode 100644 index 000000000..fa7cf2c81 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_group.go @@ -0,0 +1,98 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CrossConnectGroup For use with Oracle Cloud Infrastructure FastConnect. A cross-connect group +// is a link aggregation group (LAG), which can contain one or more +// CrossConnect. Customers who are colocated with +// Oracle in a FastConnect location create and use cross-connect groups. For more +// information, see FastConnect Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/fastconnect.htm). +// **Note:** If you're a provider who is setting up a physical connection to Oracle so customers +// can use FastConnect over the connection, be aware that your connection is modeled the +// same way as a colocated customer's (with `CrossConnect` and `CrossConnectGroup` objects, and so on). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type CrossConnectGroup struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the cross-connect group. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The cross-connect group's Oracle ID (OCID). + Id *string `mandatory:"false" json:"id"` + + // The cross-connect group's current state. + LifecycleState CrossConnectGroupLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // A reference name or identifier for the physical fiber connection that this cross-connect + // group uses. + CustomerReferenceName *string `mandatory:"false" json:"customerReferenceName"` + + // The date and time the cross-connect group was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + MacsecProperties *MacsecProperties `mandatory:"false" json:"macsecProperties"` +} + +func (m CrossConnectGroup) String() string { + return common.PointerString(m) +} + +// CrossConnectGroupLifecycleStateEnum Enum with underlying type: string +type CrossConnectGroupLifecycleStateEnum string + +// Set of constants representing the allowable values for CrossConnectGroupLifecycleStateEnum +const ( + CrossConnectGroupLifecycleStateProvisioning CrossConnectGroupLifecycleStateEnum = "PROVISIONING" + CrossConnectGroupLifecycleStateProvisioned CrossConnectGroupLifecycleStateEnum = "PROVISIONED" + CrossConnectGroupLifecycleStateInactive CrossConnectGroupLifecycleStateEnum = "INACTIVE" + CrossConnectGroupLifecycleStateTerminating CrossConnectGroupLifecycleStateEnum = "TERMINATING" + CrossConnectGroupLifecycleStateTerminated CrossConnectGroupLifecycleStateEnum = "TERMINATED" +) + +var mappingCrossConnectGroupLifecycleState = map[string]CrossConnectGroupLifecycleStateEnum{ + "PROVISIONING": CrossConnectGroupLifecycleStateProvisioning, + "PROVISIONED": CrossConnectGroupLifecycleStateProvisioned, + "INACTIVE": CrossConnectGroupLifecycleStateInactive, + "TERMINATING": CrossConnectGroupLifecycleStateTerminating, + "TERMINATED": CrossConnectGroupLifecycleStateTerminated, +} + +// GetCrossConnectGroupLifecycleStateEnumValues Enumerates the set of values for CrossConnectGroupLifecycleStateEnum +func GetCrossConnectGroupLifecycleStateEnumValues() []CrossConnectGroupLifecycleStateEnum { + values := make([]CrossConnectGroupLifecycleStateEnum, 0) + for _, v := range mappingCrossConnectGroupLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_location.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_location.go new file mode 100644 index 000000000..42670172b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_location.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CrossConnectLocation An individual FastConnect location. +type CrossConnectLocation struct { + + // A description of the location. + Description *string `mandatory:"true" json:"description"` + + // The name of the location. + // Example: `CyrusOne, Chandler, AZ` + Name *string `mandatory:"true" json:"name"` +} + +func (m CrossConnectLocation) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_mapping.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_mapping.go new file mode 100644 index 000000000..e516b8b54 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_mapping.go @@ -0,0 +1,105 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CrossConnectMapping For use with Oracle Cloud Infrastructure FastConnect. Each +// VirtualCircuit runs on one or +// more cross-connects or cross-connect groups. A `CrossConnectMapping` +// contains the properties for an individual cross-connect or cross-connect group +// associated with a given virtual circuit. +// The mapping includes information about the cross-connect or +// cross-connect group, the VLAN, and the BGP peering session. +// If you're a customer who is colocated with Oracle, that means you own both +// the virtual circuit and the physical connection it runs on (cross-connect or +// cross-connect group), so you specify all the information in the mapping. There's +// one exception: for a public virtual circuit, Oracle specifies the BGP IPv4 +// addresses. +// If you're a provider, then you own the physical connection that the customer's +// virtual circuit runs on, so you contribute information about the cross-connect +// or cross-connect group and VLAN. +// Who specifies the BGP peering information in the case of customer connection via +// provider? If the BGP session goes from Oracle to the provider's edge router, then +// the provider also specifies the BGP peering information. If the BGP session instead +// goes from Oracle to the customer's edge router, then the customer specifies the BGP +// peering information. There's one exception: for a public virtual circuit, Oracle +// specifies the BGP IPv4 addresses. +// Every `CrossConnectMapping` must have BGP IPv4 peering addresses. BGP IPv6 peering +// addresses are optional. If BGP IPv6 addresses are provided, the customer can +// exchange IPv6 routes with Oracle. +type CrossConnectMapping struct { + + // The key for BGP MD5 authentication. Only applicable if your system + // requires MD5 authentication. If empty or not set (null), that + // means you don't use BGP MD5 authentication. + BgpMd5AuthKey *string `mandatory:"false" json:"bgpMd5AuthKey"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the cross-connect or cross-connect group for this mapping. + // Specified by the owner of the cross-connect or cross-connect group (the + // customer if the customer is colocated with Oracle, or the provider if the + // customer is connecting via provider). + CrossConnectOrCrossConnectGroupId *string `mandatory:"false" json:"crossConnectOrCrossConnectGroupId"` + + // The BGP IPv4 address for the router on the other end of the BGP session from + // Oracle. Specified by the owner of that router. If the session goes from Oracle + // to a customer, this is the BGP IPv4 address of the customer's edge router. If the + // session goes from Oracle to a provider, this is the BGP IPv4 address of the + // provider's edge router. Must use a /30 or /31 subnet mask. + // There's one exception: for a public virtual circuit, Oracle specifies the BGP IPv4 addresses. + // Example: `10.0.0.18/31` + CustomerBgpPeeringIp *string `mandatory:"false" json:"customerBgpPeeringIp"` + + // The IPv4 address for Oracle's end of the BGP session. Must use a /30 or /31 + // subnet mask. If the session goes from Oracle to a customer's edge router, + // the customer specifies this information. If the session goes from Oracle to + // a provider's edge router, the provider specifies this. + // There's one exception: for a public virtual circuit, Oracle specifies the BGP IPv4 addresses. + // Example: `10.0.0.19/31` + OracleBgpPeeringIp *string `mandatory:"false" json:"oracleBgpPeeringIp"` + + // The BGP IPv6 address for the router on the other end of the BGP session from + // Oracle. Specified by the owner of that router. If the session goes from Oracle + // to a customer, this is the BGP IPv6 address of the customer's edge router. If the + // session goes from Oracle to a provider, this is the BGP IPv6 address of the + // provider's edge router. Only subnet masks from /64 up to /127 are allowed. + // There's one exception: for a public virtual circuit, Oracle specifies the BGP IPv6 addresses. + // IPv6 addressing is supported for all commercial and government regions. See + // IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // Example: `2001:db8::1/64` + CustomerBgpPeeringIpv6 *string `mandatory:"false" json:"customerBgpPeeringIpv6"` + + // The IPv6 address for Oracle's end of the BGP session. Only subnet masks from /64 up to /127 are allowed. + // If the session goes from Oracle to a customer's edge router, + // the customer specifies this information. If the session goes from Oracle to + // a provider's edge router, the provider specifies this. + // There's one exception: for a public virtual circuit, Oracle specifies the BGP IPv6 addresses. + // Note that IPv6 addressing is currently supported only in certain regions. See + // IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // Example: `2001:db8::2/64` + OracleBgpPeeringIpv6 *string `mandatory:"false" json:"oracleBgpPeeringIpv6"` + + // The number of the specific VLAN (on the cross-connect or cross-connect group) + // that is assigned to this virtual circuit. Specified by the owner of the cross-connect + // or cross-connect group (the customer if the customer is colocated with Oracle, or + // the provider if the customer is connecting via provider). + // Example: `200` + Vlan *int `mandatory:"false" json:"vlan"` +} + +func (m CrossConnectMapping) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_mapping_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_mapping_details.go new file mode 100644 index 000000000..6b1f6719b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_mapping_details.go @@ -0,0 +1,136 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CrossConnectMappingDetails For use with Oracle Cloud Infrastructure FastConnect. Each +// VirtualCircuit runs on one or +// more cross-connects or cross-connect groups. A `CrossConnectMappingDetails` +// contains the properties for an individual cross-connect or cross-connect group +// associated with a given virtual circuit. +// The details includes information about the cross-connect or +// cross-connect group, the VLAN, and the BGP peering session. +type CrossConnectMappingDetails struct { + + // The key for BGP MD5 authentication. Only applicable if your system + // requires MD5 authentication. If empty or not set (null), that + // means you don't use BGP MD5 authentication. + BgpMd5AuthKey *string `mandatory:"false" json:"bgpMd5AuthKey"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the cross-connect or cross-connect group for this mapping. + // Specified by the owner of the cross-connect or cross-connect group (the + // customer if the customer is colocated with Oracle, or the provider if the + // customer is connecting via provider). + CrossConnectOrCrossConnectGroupId *string `mandatory:"false" json:"crossConnectOrCrossConnectGroupId"` + + // The BGP IPv4 address for the router on the other end of the BGP session from + // Oracle. Specified by the owner of that router. If the session goes from Oracle + // to a customer, this is the BGP IPv4 address of the customer's edge router. If the + // session goes from Oracle to a provider, this is the BGP IPv4 address of the + // provider's edge router. Must use a /30 or /31 subnet mask. + // There's one exception: for a public virtual circuit, Oracle specifies the BGP IPv4 addresses. + // Example: `10.0.0.18/31` + CustomerBgpPeeringIp *string `mandatory:"false" json:"customerBgpPeeringIp"` + + // The IPv4 address for Oracle's end of the BGP session. Must use a /30 or /31 + // subnet mask. If the session goes from Oracle to a customer's edge router, + // the customer specifies this information. If the session goes from Oracle to + // a provider's edge router, the provider specifies this. + // There's one exception: for a public virtual circuit, Oracle specifies the BGP IPv4 addresses. + // Example: `10.0.0.19/31` + OracleBgpPeeringIp *string `mandatory:"false" json:"oracleBgpPeeringIp"` + + // The BGP IPv6 address for the router on the other end of the BGP session from + // Oracle. Specified by the owner of that router. If the session goes from Oracle + // to a customer, this is the BGP IPv6 address of the customer's edge router. If the + // session goes from Oracle to a provider, this is the BGP IPv6 address of the + // provider's edge router. Only subnet masks from /64 up to /127 are allowed. + // There's one exception: for a public virtual circuit, Oracle specifies the BGP IPv6 addresses. + // Example: `2001:db8::1/64` + CustomerBgpPeeringIpv6 *string `mandatory:"false" json:"customerBgpPeeringIpv6"` + + // The IPv6 address for Oracle's end of the BGP session. Only subnet masks from /64 up to /127 are allowed. + // If the session goes from Oracle to a customer's edge router, + // the customer specifies this information. If the session goes from Oracle to + // a provider's edge router, the provider specifies this. + // There's one exception: for a public virtual circuit, Oracle specifies the BGP IPv6 addresses. + // Example: `2001:db8::2/64` + OracleBgpPeeringIpv6 *string `mandatory:"false" json:"oracleBgpPeeringIpv6"` + + // The number of the specific VLAN (on the cross-connect or cross-connect group) + // that is assigned to this virtual circuit. Specified by the owner of the cross-connect + // or cross-connect group (the customer if the customer is colocated with Oracle, or + // the provider if the customer is connecting via provider). + // Example: `200` + Vlan *int `mandatory:"false" json:"vlan"` + + // The state of the Ipv4 BGP session. + Ipv4BgpStatus CrossConnectMappingDetailsIpv4BgpStatusEnum `mandatory:"false" json:"ipv4BgpStatus,omitempty"` + + // The state of the Ipv6 BGP session. + Ipv6BgpStatus CrossConnectMappingDetailsIpv6BgpStatusEnum `mandatory:"false" json:"ipv6BgpStatus,omitempty"` +} + +func (m CrossConnectMappingDetails) String() string { + return common.PointerString(m) +} + +// CrossConnectMappingDetailsIpv4BgpStatusEnum Enum with underlying type: string +type CrossConnectMappingDetailsIpv4BgpStatusEnum string + +// Set of constants representing the allowable values for CrossConnectMappingDetailsIpv4BgpStatusEnum +const ( + CrossConnectMappingDetailsIpv4BgpStatusUp CrossConnectMappingDetailsIpv4BgpStatusEnum = "UP" + CrossConnectMappingDetailsIpv4BgpStatusDown CrossConnectMappingDetailsIpv4BgpStatusEnum = "DOWN" +) + +var mappingCrossConnectMappingDetailsIpv4BgpStatus = map[string]CrossConnectMappingDetailsIpv4BgpStatusEnum{ + "UP": CrossConnectMappingDetailsIpv4BgpStatusUp, + "DOWN": CrossConnectMappingDetailsIpv4BgpStatusDown, +} + +// GetCrossConnectMappingDetailsIpv4BgpStatusEnumValues Enumerates the set of values for CrossConnectMappingDetailsIpv4BgpStatusEnum +func GetCrossConnectMappingDetailsIpv4BgpStatusEnumValues() []CrossConnectMappingDetailsIpv4BgpStatusEnum { + values := make([]CrossConnectMappingDetailsIpv4BgpStatusEnum, 0) + for _, v := range mappingCrossConnectMappingDetailsIpv4BgpStatus { + values = append(values, v) + } + return values +} + +// CrossConnectMappingDetailsIpv6BgpStatusEnum Enum with underlying type: string +type CrossConnectMappingDetailsIpv6BgpStatusEnum string + +// Set of constants representing the allowable values for CrossConnectMappingDetailsIpv6BgpStatusEnum +const ( + CrossConnectMappingDetailsIpv6BgpStatusUp CrossConnectMappingDetailsIpv6BgpStatusEnum = "UP" + CrossConnectMappingDetailsIpv6BgpStatusDown CrossConnectMappingDetailsIpv6BgpStatusEnum = "DOWN" +) + +var mappingCrossConnectMappingDetailsIpv6BgpStatus = map[string]CrossConnectMappingDetailsIpv6BgpStatusEnum{ + "UP": CrossConnectMappingDetailsIpv6BgpStatusUp, + "DOWN": CrossConnectMappingDetailsIpv6BgpStatusDown, +} + +// GetCrossConnectMappingDetailsIpv6BgpStatusEnumValues Enumerates the set of values for CrossConnectMappingDetailsIpv6BgpStatusEnum +func GetCrossConnectMappingDetailsIpv6BgpStatusEnumValues() []CrossConnectMappingDetailsIpv6BgpStatusEnum { + values := make([]CrossConnectMappingDetailsIpv6BgpStatusEnum, 0) + for _, v := range mappingCrossConnectMappingDetailsIpv6BgpStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_mapping_details_collection.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_mapping_details_collection.go new file mode 100644 index 000000000..04ca54f44 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_mapping_details_collection.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CrossConnectMappingDetailsCollection An array of CrossConnectMappingDetails +type CrossConnectMappingDetailsCollection struct { + + // CrossConnectMappingDetails items + Items []CrossConnectMappingDetails `mandatory:"true" json:"items"` +} + +func (m CrossConnectMappingDetailsCollection) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_port_speed_shape.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_port_speed_shape.go new file mode 100644 index 000000000..105bd8d58 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_port_speed_shape.go @@ -0,0 +1,34 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CrossConnectPortSpeedShape An individual port speed level for cross-connects. +type CrossConnectPortSpeedShape struct { + + // The name of the port speed shape. + // Example: `10 Gbps` + Name *string `mandatory:"true" json:"name"` + + // The port speed in Gbps. + // Example: `10` + PortSpeedInGbps *int `mandatory:"true" json:"portSpeedInGbps"` +} + +func (m CrossConnectPortSpeedShape) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_status.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_status.go new file mode 100644 index 000000000..9a0a92184 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/cross_connect_status.go @@ -0,0 +1,138 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CrossConnectStatus The status of the cross-connect. +type CrossConnectStatus struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the cross-connect. + CrossConnectId *string `mandatory:"true" json:"crossConnectId"` + + // Indicates whether Oracle's side of the interface is up or down. + InterfaceState CrossConnectStatusInterfaceStateEnum `mandatory:"false" json:"interfaceState,omitempty"` + + // The light level of the cross-connect (in dBm). + // Example: `14.0` + LightLevelIndBm *float32 `mandatory:"false" json:"lightLevelIndBm"` + + // Status indicator corresponding to the light level. + // * **NO_LIGHT:** No measurable light + // * **LOW_WARN:** There's measurable light but it's too low + // * **HIGH_WARN:** Light level is too high + // * **BAD:** There's measurable light but the signal-to-noise ratio is bad + // * **GOOD:** Good light level + LightLevelIndicator CrossConnectStatusLightLevelIndicatorEnum `mandatory:"false" json:"lightLevelIndicator,omitempty"` + + // Encryption status of this cross connect. + // Possible values: + // * **UP:** Traffic is encrypted over this cross-connect + // * **DOWN:** Traffic is not encrypted over this cross-connect + // * **CIPHER_MISMATCH:** The MACsec encryption cipher doesn't match the cipher on the CPE + // * **CKN_MISMATCH:** The MACsec Connectivity association Key Name (CKN) doesn't match the CKN on the CPE + // * **CAK_MISMATCH:** The MACsec Connectivity Association Key (CAK) doesn't match the CAK on the CPE + EncryptionStatus CrossConnectStatusEncryptionStatusEnum `mandatory:"false" json:"encryptionStatus,omitempty"` + + // The light levels of the cross-connect (in dBm). + // Example: `[14.0, -14.0, 2.1, -10.1]` + LightLevelsInDBm []float32 `mandatory:"false" json:"lightLevelsInDBm"` +} + +func (m CrossConnectStatus) String() string { + return common.PointerString(m) +} + +// CrossConnectStatusInterfaceStateEnum Enum with underlying type: string +type CrossConnectStatusInterfaceStateEnum string + +// Set of constants representing the allowable values for CrossConnectStatusInterfaceStateEnum +const ( + CrossConnectStatusInterfaceStateUp CrossConnectStatusInterfaceStateEnum = "UP" + CrossConnectStatusInterfaceStateDown CrossConnectStatusInterfaceStateEnum = "DOWN" +) + +var mappingCrossConnectStatusInterfaceState = map[string]CrossConnectStatusInterfaceStateEnum{ + "UP": CrossConnectStatusInterfaceStateUp, + "DOWN": CrossConnectStatusInterfaceStateDown, +} + +// GetCrossConnectStatusInterfaceStateEnumValues Enumerates the set of values for CrossConnectStatusInterfaceStateEnum +func GetCrossConnectStatusInterfaceStateEnumValues() []CrossConnectStatusInterfaceStateEnum { + values := make([]CrossConnectStatusInterfaceStateEnum, 0) + for _, v := range mappingCrossConnectStatusInterfaceState { + values = append(values, v) + } + return values +} + +// CrossConnectStatusLightLevelIndicatorEnum Enum with underlying type: string +type CrossConnectStatusLightLevelIndicatorEnum string + +// Set of constants representing the allowable values for CrossConnectStatusLightLevelIndicatorEnum +const ( + CrossConnectStatusLightLevelIndicatorNoLight CrossConnectStatusLightLevelIndicatorEnum = "NO_LIGHT" + CrossConnectStatusLightLevelIndicatorLowWarn CrossConnectStatusLightLevelIndicatorEnum = "LOW_WARN" + CrossConnectStatusLightLevelIndicatorHighWarn CrossConnectStatusLightLevelIndicatorEnum = "HIGH_WARN" + CrossConnectStatusLightLevelIndicatorBad CrossConnectStatusLightLevelIndicatorEnum = "BAD" + CrossConnectStatusLightLevelIndicatorGood CrossConnectStatusLightLevelIndicatorEnum = "GOOD" +) + +var mappingCrossConnectStatusLightLevelIndicator = map[string]CrossConnectStatusLightLevelIndicatorEnum{ + "NO_LIGHT": CrossConnectStatusLightLevelIndicatorNoLight, + "LOW_WARN": CrossConnectStatusLightLevelIndicatorLowWarn, + "HIGH_WARN": CrossConnectStatusLightLevelIndicatorHighWarn, + "BAD": CrossConnectStatusLightLevelIndicatorBad, + "GOOD": CrossConnectStatusLightLevelIndicatorGood, +} + +// GetCrossConnectStatusLightLevelIndicatorEnumValues Enumerates the set of values for CrossConnectStatusLightLevelIndicatorEnum +func GetCrossConnectStatusLightLevelIndicatorEnumValues() []CrossConnectStatusLightLevelIndicatorEnum { + values := make([]CrossConnectStatusLightLevelIndicatorEnum, 0) + for _, v := range mappingCrossConnectStatusLightLevelIndicator { + values = append(values, v) + } + return values +} + +// CrossConnectStatusEncryptionStatusEnum Enum with underlying type: string +type CrossConnectStatusEncryptionStatusEnum string + +// Set of constants representing the allowable values for CrossConnectStatusEncryptionStatusEnum +const ( + CrossConnectStatusEncryptionStatusUp CrossConnectStatusEncryptionStatusEnum = "UP" + CrossConnectStatusEncryptionStatusDown CrossConnectStatusEncryptionStatusEnum = "DOWN" + CrossConnectStatusEncryptionStatusCipherMismatch CrossConnectStatusEncryptionStatusEnum = "CIPHER_MISMATCH" + CrossConnectStatusEncryptionStatusCknMismatch CrossConnectStatusEncryptionStatusEnum = "CKN_MISMATCH" + CrossConnectStatusEncryptionStatusCakMismatch CrossConnectStatusEncryptionStatusEnum = "CAK_MISMATCH" +) + +var mappingCrossConnectStatusEncryptionStatus = map[string]CrossConnectStatusEncryptionStatusEnum{ + "UP": CrossConnectStatusEncryptionStatusUp, + "DOWN": CrossConnectStatusEncryptionStatusDown, + "CIPHER_MISMATCH": CrossConnectStatusEncryptionStatusCipherMismatch, + "CKN_MISMATCH": CrossConnectStatusEncryptionStatusCknMismatch, + "CAK_MISMATCH": CrossConnectStatusEncryptionStatusCakMismatch, +} + +// GetCrossConnectStatusEncryptionStatusEnumValues Enumerates the set of values for CrossConnectStatusEncryptionStatusEnum +func GetCrossConnectStatusEncryptionStatusEnumValues() []CrossConnectStatusEncryptionStatusEnum { + values := make([]CrossConnectStatusEncryptionStatusEnum, 0) + for _, v := range mappingCrossConnectStatusEncryptionStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host.go new file mode 100644 index 000000000..fcc2608da --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host.go @@ -0,0 +1,113 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DedicatedVmHost A dedicated virtual machine host lets you host multiple VM instances +// on a dedicated server that is not shared with other tenancies. +type DedicatedVmHost struct { + + // The availability domain the dedicated virtual machine host is running in. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment that contains the dedicated virtual machine host. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The dedicated virtual machine host shape. The shape determines the number of CPUs and + // other resources available for VMs. + DedicatedVmHostShape *string `mandatory:"true" json:"dedicatedVmHostShape"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the dedicated VM host. + Id *string `mandatory:"true" json:"id"` + + // The current state of the dedicated VM host. + LifecycleState DedicatedVmHostLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the dedicated VM host was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The total OCPUs of the dedicated VM host. + TotalOcpus *float32 `mandatory:"true" json:"totalOcpus"` + + // The available OCPUs of the dedicated VM host. + RemainingOcpus *float32 `mandatory:"true" json:"remainingOcpus"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // The fault domain for the dedicated virtual machine host's assigned instances. + // For more information, see Fault Domains (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/regions.htm#fault). + // If you do not specify the fault domain, the system selects one for you. To change the fault domain for a dedicated virtual machine host, + // delete it, and then create a new dedicated virtual machine host in the preferred fault domain. + // To get a list of fault domains, use the `ListFaultDomains` operation in the Identity and Access Management Service API (https://docs.cloud.oracle.com/iaas/api/#/en/identity/20160918/). + // Example: `FAULT-DOMAIN-1` + FaultDomain *string `mandatory:"false" json:"faultDomain"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The total memory of the dedicated VM host, in GBs. + TotalMemoryInGBs *float32 `mandatory:"false" json:"totalMemoryInGBs"` + + // The remaining memory of the dedicated VM host, in GBs. + RemainingMemoryInGBs *float32 `mandatory:"false" json:"remainingMemoryInGBs"` +} + +func (m DedicatedVmHost) String() string { + return common.PointerString(m) +} + +// DedicatedVmHostLifecycleStateEnum Enum with underlying type: string +type DedicatedVmHostLifecycleStateEnum string + +// Set of constants representing the allowable values for DedicatedVmHostLifecycleStateEnum +const ( + DedicatedVmHostLifecycleStateCreating DedicatedVmHostLifecycleStateEnum = "CREATING" + DedicatedVmHostLifecycleStateActive DedicatedVmHostLifecycleStateEnum = "ACTIVE" + DedicatedVmHostLifecycleStateUpdating DedicatedVmHostLifecycleStateEnum = "UPDATING" + DedicatedVmHostLifecycleStateDeleting DedicatedVmHostLifecycleStateEnum = "DELETING" + DedicatedVmHostLifecycleStateDeleted DedicatedVmHostLifecycleStateEnum = "DELETED" + DedicatedVmHostLifecycleStateFailed DedicatedVmHostLifecycleStateEnum = "FAILED" +) + +var mappingDedicatedVmHostLifecycleState = map[string]DedicatedVmHostLifecycleStateEnum{ + "CREATING": DedicatedVmHostLifecycleStateCreating, + "ACTIVE": DedicatedVmHostLifecycleStateActive, + "UPDATING": DedicatedVmHostLifecycleStateUpdating, + "DELETING": DedicatedVmHostLifecycleStateDeleting, + "DELETED": DedicatedVmHostLifecycleStateDeleted, + "FAILED": DedicatedVmHostLifecycleStateFailed, +} + +// GetDedicatedVmHostLifecycleStateEnumValues Enumerates the set of values for DedicatedVmHostLifecycleStateEnum +func GetDedicatedVmHostLifecycleStateEnumValues() []DedicatedVmHostLifecycleStateEnum { + values := make([]DedicatedVmHostLifecycleStateEnum, 0) + for _, v := range mappingDedicatedVmHostLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_instance_shape_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_instance_shape_summary.go new file mode 100644 index 000000000..9ac0518e9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_instance_shape_summary.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DedicatedVmHostInstanceShapeSummary The shape used to launch instances associated with the dedicated VM host. +type DedicatedVmHostInstanceShapeSummary struct { + + // The name of the virtual machine instance shapes that can be launched on a dedicated VM host. + InstanceShapeName *string `mandatory:"true" json:"instanceShapeName"` + + // The shape's availability domain. + AvailabilityDomain *string `mandatory:"false" json:"availabilityDomain"` +} + +func (m DedicatedVmHostInstanceShapeSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_instance_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_instance_summary.go new file mode 100644 index 000000000..75be70f08 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_instance_summary.go @@ -0,0 +1,43 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DedicatedVmHostInstanceSummary Condensed instance data when listing instances on a dedicated VM host. +type DedicatedVmHostInstanceSummary struct { + + // The availability domain the virtual machine instance is running in. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment that contains the virtual machine instance. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the virtual machine instance. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // The shape of the VM instance. + Shape *string `mandatory:"true" json:"shape"` + + // The date and time the virtual machine instance was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` +} + +func (m DedicatedVmHostInstanceSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_shape_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_shape_summary.go new file mode 100644 index 000000000..7447f1d57 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_shape_summary.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DedicatedVmHostShapeSummary The shape used to launch the dedicated virtual machine (VM) host. +type DedicatedVmHostShapeSummary struct { + + // The name of the dedicated VM host shape. You can enumerate all available shapes by calling + // dedicatedVmHostShapes. + DedicatedVmHostShape *string `mandatory:"true" json:"dedicatedVmHostShape"` + + // The shape's availability domain. + AvailabilityDomain *string `mandatory:"false" json:"availabilityDomain"` +} + +func (m DedicatedVmHostShapeSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_summary.go new file mode 100644 index 000000000..2ee9430de --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/dedicated_vm_host_summary.go @@ -0,0 +1,101 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DedicatedVmHostSummary A dedicated virtual machine (VM) host lets you host multiple instances on a dedicated server that is not shared with other tenancies. +type DedicatedVmHostSummary struct { + + // The availability domain the dedicated VM host is running in. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment that contains the dedicated VM host. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The shape of the dedicated VM host. The shape determines the number of CPUs and + // other resources available for VMs. + DedicatedVmHostShape *string `mandatory:"true" json:"dedicatedVmHostShape"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the dedicated VM host. + Id *string `mandatory:"true" json:"id"` + + // The current state of the dedicated VM host. + LifecycleState DedicatedVmHostSummaryLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the dedicated VM host was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The current available OCPUs of the dedicated VM host. + RemainingOcpus *float32 `mandatory:"true" json:"remainingOcpus"` + + // The current total OCPUs of the dedicated VM host. + TotalOcpus *float32 `mandatory:"true" json:"totalOcpus"` + + // The fault domain for the dedicated VM host's assigned instances. For more information, see Fault Domains. + // If you do not specify the fault domain, the system selects one for you. To change the fault domain for a dedicated VM host, + // delete it and create a new dedicated VM host in the preferred fault domain. + // To get a list of fault domains, use the ListFaultDomains operation in the Identity and Access Management Service API. + // Example: `FAULT-DOMAIN-1` + FaultDomain *string `mandatory:"false" json:"faultDomain"` + + // The current total memory of the dedicated VM host, in GBs. + TotalMemoryInGBs *float32 `mandatory:"false" json:"totalMemoryInGBs"` + + // The current available memory of the dedicated VM host, in GBs. + RemainingMemoryInGBs *float32 `mandatory:"false" json:"remainingMemoryInGBs"` +} + +func (m DedicatedVmHostSummary) String() string { + return common.PointerString(m) +} + +// DedicatedVmHostSummaryLifecycleStateEnum Enum with underlying type: string +type DedicatedVmHostSummaryLifecycleStateEnum string + +// Set of constants representing the allowable values for DedicatedVmHostSummaryLifecycleStateEnum +const ( + DedicatedVmHostSummaryLifecycleStateCreating DedicatedVmHostSummaryLifecycleStateEnum = "CREATING" + DedicatedVmHostSummaryLifecycleStateActive DedicatedVmHostSummaryLifecycleStateEnum = "ACTIVE" + DedicatedVmHostSummaryLifecycleStateUpdating DedicatedVmHostSummaryLifecycleStateEnum = "UPDATING" + DedicatedVmHostSummaryLifecycleStateDeleting DedicatedVmHostSummaryLifecycleStateEnum = "DELETING" + DedicatedVmHostSummaryLifecycleStateDeleted DedicatedVmHostSummaryLifecycleStateEnum = "DELETED" + DedicatedVmHostSummaryLifecycleStateFailed DedicatedVmHostSummaryLifecycleStateEnum = "FAILED" +) + +var mappingDedicatedVmHostSummaryLifecycleState = map[string]DedicatedVmHostSummaryLifecycleStateEnum{ + "CREATING": DedicatedVmHostSummaryLifecycleStateCreating, + "ACTIVE": DedicatedVmHostSummaryLifecycleStateActive, + "UPDATING": DedicatedVmHostSummaryLifecycleStateUpdating, + "DELETING": DedicatedVmHostSummaryLifecycleStateDeleting, + "DELETED": DedicatedVmHostSummaryLifecycleStateDeleted, + "FAILED": DedicatedVmHostSummaryLifecycleStateFailed, +} + +// GetDedicatedVmHostSummaryLifecycleStateEnumValues Enumerates the set of values for DedicatedVmHostSummaryLifecycleStateEnum +func GetDedicatedVmHostSummaryLifecycleStateEnumValues() []DedicatedVmHostSummaryLifecycleStateEnum { + values := make([]DedicatedVmHostSummaryLifecycleStateEnum, 0) + for _, v := range mappingDedicatedVmHostSummaryLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/default_drg_route_tables.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/default_drg_route_tables.go new file mode 100644 index 000000000..1198b3a38 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/default_drg_route_tables.go @@ -0,0 +1,46 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DefaultDrgRouteTables The default DRG route table for this DRG. Each network type +// has a default DRG route table. +// You can update a network type to use a different DRG route table, but +// each network type must have a default DRG route table. You cannot delete +// a default DRG route table. +type DefaultDrgRouteTables struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the default DRG route table to be assigned to DRG attachments + // of type VCN on creation. + Vcn *string `mandatory:"false" json:"vcn"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the default DRG route table assigned to DRG attachments + // of type IPSEC_TUNNEL on creation. + IpsecTunnel *string `mandatory:"false" json:"ipsecTunnel"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the default DRG route table to be assigned to DRG attachments + // of type VIRTUAL_CIRCUIT on creation. + VirtualCircuit *string `mandatory:"false" json:"virtualCircuit"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the default DRG route table to be assigned to DRG attachments + // of type REMOTE_PEERING_CONNECTION on creation. + RemotePeeringConnection *string `mandatory:"false" json:"remotePeeringConnection"` +} + +func (m DefaultDrgRouteTables) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/default_phase_one_parameters.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/default_phase_one_parameters.go new file mode 100644 index 000000000..b15162349 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/default_phase_one_parameters.go @@ -0,0 +1,35 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DefaultPhaseOneParameters Phase One Parameters +type DefaultPhaseOneParameters struct { + + // Default Phase One Encryption Algorithms + DefaultEncryptionAlgorithms []string `mandatory:"false" json:"defaultEncryptionAlgorithms"` + + // Default Phase One Authentication Algorithms + DefaultAuthenticationAlgorithms []string `mandatory:"false" json:"defaultAuthenticationAlgorithms"` + + // Default DH Groups + DefaultDhGroups []string `mandatory:"false" json:"defaultDhGroups"` +} + +func (m DefaultPhaseOneParameters) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/default_phase_two_parameters.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/default_phase_two_parameters.go new file mode 100644 index 000000000..5b633596b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/default_phase_two_parameters.go @@ -0,0 +1,35 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DefaultPhaseTwoParameters Phase Two Parameters +type DefaultPhaseTwoParameters struct { + + // Default Phase Two Encryption Algorithms + DefaultEncryptionAlgorithms []string `mandatory:"false" json:"defaultEncryptionAlgorithms"` + + // Default Phase Two Authentication Algorithms + DefaultAuthenticationAlgorithms []string `mandatory:"false" json:"defaultAuthenticationAlgorithms"` + + // Default PFS DH Group + DefaultPfsDhGroup *string `mandatory:"false" json:"defaultPfsDhGroup"` +} + +func (m DefaultPhaseTwoParameters) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_app_catalog_subscription_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_app_catalog_subscription_request_response.go new file mode 100644 index 000000000..ae56a0071 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_app_catalog_subscription_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteAppCatalogSubscriptionRequest wrapper for the DeleteAppCatalogSubscription operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteAppCatalogSubscription.go.html to see an example of how to use DeleteAppCatalogSubscriptionRequest. +type DeleteAppCatalogSubscriptionRequest struct { + + // The OCID of the listing. + ListingId *string `mandatory:"true" contributesTo:"query" name:"listingId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // Listing Resource Version. + ResourceVersion *string `mandatory:"true" contributesTo:"query" name:"resourceVersion"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteAppCatalogSubscriptionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteAppCatalogSubscriptionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteAppCatalogSubscriptionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteAppCatalogSubscriptionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteAppCatalogSubscriptionResponse wrapper for the DeleteAppCatalogSubscription operation +type DeleteAppCatalogSubscriptionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteAppCatalogSubscriptionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteAppCatalogSubscriptionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_boot_volume_backup_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_boot_volume_backup_request_response.go new file mode 100644 index 000000000..cac1b0fe7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_boot_volume_backup_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteBootVolumeBackupRequest wrapper for the DeleteBootVolumeBackup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteBootVolumeBackup.go.html to see an example of how to use DeleteBootVolumeBackupRequest. +type DeleteBootVolumeBackupRequest struct { + + // The OCID of the boot volume backup. + BootVolumeBackupId *string `mandatory:"true" contributesTo:"path" name:"bootVolumeBackupId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteBootVolumeBackupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteBootVolumeBackupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteBootVolumeBackupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteBootVolumeBackupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteBootVolumeBackupResponse wrapper for the DeleteBootVolumeBackup operation +type DeleteBootVolumeBackupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteBootVolumeBackupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteBootVolumeBackupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_boot_volume_kms_key_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_boot_volume_kms_key_request_response.go new file mode 100644 index 000000000..6ea6da74e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_boot_volume_kms_key_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteBootVolumeKmsKeyRequest wrapper for the DeleteBootVolumeKmsKey operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteBootVolumeKmsKey.go.html to see an example of how to use DeleteBootVolumeKmsKeyRequest. +type DeleteBootVolumeKmsKeyRequest struct { + + // The OCID of the boot volume. + BootVolumeId *string `mandatory:"true" contributesTo:"path" name:"bootVolumeId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteBootVolumeKmsKeyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteBootVolumeKmsKeyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteBootVolumeKmsKeyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteBootVolumeKmsKeyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteBootVolumeKmsKeyResponse wrapper for the DeleteBootVolumeKmsKey operation +type DeleteBootVolumeKmsKeyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteBootVolumeKmsKeyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteBootVolumeKmsKeyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_boot_volume_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_boot_volume_request_response.go new file mode 100644 index 000000000..4c478a5f3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_boot_volume_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteBootVolumeRequest wrapper for the DeleteBootVolume operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteBootVolume.go.html to see an example of how to use DeleteBootVolumeRequest. +type DeleteBootVolumeRequest struct { + + // The OCID of the boot volume. + BootVolumeId *string `mandatory:"true" contributesTo:"path" name:"bootVolumeId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteBootVolumeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteBootVolumeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteBootVolumeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteBootVolumeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteBootVolumeResponse wrapper for the DeleteBootVolume operation +type DeleteBootVolumeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteBootVolumeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteBootVolumeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_byoip_range_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_byoip_range_request_response.go new file mode 100644 index 000000000..6335f7d40 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_byoip_range_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteByoipRangeRequest wrapper for the DeleteByoipRange operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteByoipRange.go.html to see an example of how to use DeleteByoipRangeRequest. +type DeleteByoipRangeRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the `ByoipRange` resource containing the BYOIP CIDR block. + ByoipRangeId *string `mandatory:"true" contributesTo:"path" name:"byoipRangeId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteByoipRangeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteByoipRangeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteByoipRangeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteByoipRangeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteByoipRangeResponse wrapper for the DeleteByoipRange operation +type DeleteByoipRangeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response DeleteByoipRangeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteByoipRangeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_compute_capacity_reservation_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_compute_capacity_reservation_request_response.go new file mode 100644 index 000000000..e78a475f6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_compute_capacity_reservation_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteComputeCapacityReservationRequest wrapper for the DeleteComputeCapacityReservation operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteComputeCapacityReservation.go.html to see an example of how to use DeleteComputeCapacityReservationRequest. +type DeleteComputeCapacityReservationRequest struct { + + // The OCID of the compute capacity reservation. + CapacityReservationId *string `mandatory:"true" contributesTo:"path" name:"capacityReservationId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteComputeCapacityReservationRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteComputeCapacityReservationRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteComputeCapacityReservationRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteComputeCapacityReservationRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteComputeCapacityReservationResponse wrapper for the DeleteComputeCapacityReservation operation +type DeleteComputeCapacityReservationResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response DeleteComputeCapacityReservationResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteComputeCapacityReservationResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_compute_image_capability_schema_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_compute_image_capability_schema_request_response.go new file mode 100644 index 000000000..e17eae8a3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_compute_image_capability_schema_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteComputeImageCapabilitySchemaRequest wrapper for the DeleteComputeImageCapabilitySchema operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteComputeImageCapabilitySchema.go.html to see an example of how to use DeleteComputeImageCapabilitySchemaRequest. +type DeleteComputeImageCapabilitySchemaRequest struct { + + // The id of the compute image capability schema or the image ocid + ComputeImageCapabilitySchemaId *string `mandatory:"true" contributesTo:"path" name:"computeImageCapabilitySchemaId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteComputeImageCapabilitySchemaRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteComputeImageCapabilitySchemaRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteComputeImageCapabilitySchemaRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteComputeImageCapabilitySchemaRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteComputeImageCapabilitySchemaResponse wrapper for the DeleteComputeImageCapabilitySchema operation +type DeleteComputeImageCapabilitySchemaResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteComputeImageCapabilitySchemaResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteComputeImageCapabilitySchemaResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_console_history_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_console_history_request_response.go new file mode 100644 index 000000000..059988e52 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_console_history_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteConsoleHistoryRequest wrapper for the DeleteConsoleHistory operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteConsoleHistory.go.html to see an example of how to use DeleteConsoleHistoryRequest. +type DeleteConsoleHistoryRequest struct { + + // The OCID of the console history. + InstanceConsoleHistoryId *string `mandatory:"true" contributesTo:"path" name:"instanceConsoleHistoryId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteConsoleHistoryRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteConsoleHistoryRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteConsoleHistoryRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteConsoleHistoryRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteConsoleHistoryResponse wrapper for the DeleteConsoleHistory operation +type DeleteConsoleHistoryResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteConsoleHistoryResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteConsoleHistoryResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_cpe_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_cpe_request_response.go new file mode 100644 index 000000000..1b5017fc4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_cpe_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteCpeRequest wrapper for the DeleteCpe operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteCpe.go.html to see an example of how to use DeleteCpeRequest. +type DeleteCpeRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the CPE. + CpeId *string `mandatory:"true" contributesTo:"path" name:"cpeId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteCpeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteCpeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteCpeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteCpeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteCpeResponse wrapper for the DeleteCpe operation +type DeleteCpeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteCpeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteCpeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_cross_connect_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_cross_connect_group_request_response.go new file mode 100644 index 000000000..6fd822e76 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_cross_connect_group_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteCrossConnectGroupRequest wrapper for the DeleteCrossConnectGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteCrossConnectGroup.go.html to see an example of how to use DeleteCrossConnectGroupRequest. +type DeleteCrossConnectGroupRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the cross-connect group. + CrossConnectGroupId *string `mandatory:"true" contributesTo:"path" name:"crossConnectGroupId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteCrossConnectGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteCrossConnectGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteCrossConnectGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteCrossConnectGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteCrossConnectGroupResponse wrapper for the DeleteCrossConnectGroup operation +type DeleteCrossConnectGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteCrossConnectGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteCrossConnectGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_cross_connect_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_cross_connect_request_response.go new file mode 100644 index 000000000..cc594ab9e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_cross_connect_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteCrossConnectRequest wrapper for the DeleteCrossConnect operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteCrossConnect.go.html to see an example of how to use DeleteCrossConnectRequest. +type DeleteCrossConnectRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the cross-connect. + CrossConnectId *string `mandatory:"true" contributesTo:"path" name:"crossConnectId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteCrossConnectRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteCrossConnectRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteCrossConnectRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteCrossConnectRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteCrossConnectResponse wrapper for the DeleteCrossConnect operation +type DeleteCrossConnectResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteCrossConnectResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteCrossConnectResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_dedicated_vm_host_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_dedicated_vm_host_request_response.go new file mode 100644 index 000000000..a10328977 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_dedicated_vm_host_request_response.go @@ -0,0 +1,75 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteDedicatedVmHostRequest wrapper for the DeleteDedicatedVmHost operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteDedicatedVmHost.go.html to see an example of how to use DeleteDedicatedVmHostRequest. +type DeleteDedicatedVmHostRequest struct { + + // The OCID of the dedicated VM host. + DedicatedVmHostId *string `mandatory:"true" contributesTo:"path" name:"dedicatedVmHostId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteDedicatedVmHostRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteDedicatedVmHostRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteDedicatedVmHostRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteDedicatedVmHostRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteDedicatedVmHostResponse wrapper for the DeleteDedicatedVmHost operation +type DeleteDedicatedVmHostResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response DeleteDedicatedVmHostResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteDedicatedVmHostResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_dhcp_options_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_dhcp_options_request_response.go new file mode 100644 index 000000000..ad1675a67 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_dhcp_options_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteDhcpOptionsRequest wrapper for the DeleteDhcpOptions operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteDhcpOptions.go.html to see an example of how to use DeleteDhcpOptionsRequest. +type DeleteDhcpOptionsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) for the set of DHCP options. + DhcpId *string `mandatory:"true" contributesTo:"path" name:"dhcpId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteDhcpOptionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteDhcpOptionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteDhcpOptionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteDhcpOptionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteDhcpOptionsResponse wrapper for the DeleteDhcpOptions operation +type DeleteDhcpOptionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteDhcpOptionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteDhcpOptionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_attachment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_attachment_request_response.go new file mode 100644 index 000000000..64a6879fc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_attachment_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteDrgAttachmentRequest wrapper for the DeleteDrgAttachment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteDrgAttachment.go.html to see an example of how to use DeleteDrgAttachmentRequest. +type DeleteDrgAttachmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG attachment. + DrgAttachmentId *string `mandatory:"true" contributesTo:"path" name:"drgAttachmentId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteDrgAttachmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteDrgAttachmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteDrgAttachmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteDrgAttachmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteDrgAttachmentResponse wrapper for the DeleteDrgAttachment operation +type DeleteDrgAttachmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteDrgAttachmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteDrgAttachmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_request_response.go new file mode 100644 index 000000000..fc0b5fa56 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteDrgRequest wrapper for the DeleteDrg operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteDrg.go.html to see an example of how to use DeleteDrgRequest. +type DeleteDrgRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"true" contributesTo:"path" name:"drgId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteDrgRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteDrgRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteDrgRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteDrgRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteDrgResponse wrapper for the DeleteDrg operation +type DeleteDrgResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteDrgResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteDrgResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_route_distribution_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_route_distribution_request_response.go new file mode 100644 index 000000000..7c92f05e0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_route_distribution_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteDrgRouteDistributionRequest wrapper for the DeleteDrgRouteDistribution operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteDrgRouteDistribution.go.html to see an example of how to use DeleteDrgRouteDistributionRequest. +type DeleteDrgRouteDistributionRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route distribution. + DrgRouteDistributionId *string `mandatory:"true" contributesTo:"path" name:"drgRouteDistributionId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteDrgRouteDistributionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteDrgRouteDistributionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteDrgRouteDistributionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteDrgRouteDistributionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteDrgRouteDistributionResponse wrapper for the DeleteDrgRouteDistribution operation +type DeleteDrgRouteDistributionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteDrgRouteDistributionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteDrgRouteDistributionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_route_table_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_route_table_request_response.go new file mode 100644 index 000000000..024e3f709 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_drg_route_table_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteDrgRouteTableRequest wrapper for the DeleteDrgRouteTable operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteDrgRouteTable.go.html to see an example of how to use DeleteDrgRouteTableRequest. +type DeleteDrgRouteTableRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG route table. + DrgRouteTableId *string `mandatory:"true" contributesTo:"path" name:"drgRouteTableId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteDrgRouteTableRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteDrgRouteTableRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteDrgRouteTableRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteDrgRouteTableRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteDrgRouteTableResponse wrapper for the DeleteDrgRouteTable operation +type DeleteDrgRouteTableResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteDrgRouteTableResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteDrgRouteTableResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_i_p_sec_connection_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_i_p_sec_connection_request_response.go new file mode 100644 index 000000000..7ef591caf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_i_p_sec_connection_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteIPSecConnectionRequest wrapper for the DeleteIPSecConnection operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteIPSecConnection.go.html to see an example of how to use DeleteIPSecConnectionRequest. +type DeleteIPSecConnectionRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteIPSecConnectionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteIPSecConnectionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteIPSecConnectionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteIPSecConnectionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteIPSecConnectionResponse wrapper for the DeleteIPSecConnection operation +type DeleteIPSecConnectionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteIPSecConnectionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteIPSecConnectionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_image_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_image_request_response.go new file mode 100644 index 000000000..3afffd734 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_image_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteImageRequest wrapper for the DeleteImage operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteImage.go.html to see an example of how to use DeleteImageRequest. +type DeleteImageRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the image. + ImageId *string `mandatory:"true" contributesTo:"path" name:"imageId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteImageRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteImageRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteImageRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteImageRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteImageResponse wrapper for the DeleteImage operation +type DeleteImageResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteImageResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteImageResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_instance_configuration_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_instance_configuration_request_response.go new file mode 100644 index 000000000..3f4e9f844 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_instance_configuration_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteInstanceConfigurationRequest wrapper for the DeleteInstanceConfiguration operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteInstanceConfiguration.go.html to see an example of how to use DeleteInstanceConfigurationRequest. +type DeleteInstanceConfigurationRequest struct { + + // The OCID of the instance configuration. + InstanceConfigurationId *string `mandatory:"true" contributesTo:"path" name:"instanceConfigurationId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteInstanceConfigurationRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteInstanceConfigurationRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteInstanceConfigurationRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteInstanceConfigurationRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteInstanceConfigurationResponse wrapper for the DeleteInstanceConfiguration operation +type DeleteInstanceConfigurationResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteInstanceConfigurationResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteInstanceConfigurationResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_instance_console_connection_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_instance_console_connection_request_response.go new file mode 100644 index 000000000..9f9a4be51 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_instance_console_connection_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteInstanceConsoleConnectionRequest wrapper for the DeleteInstanceConsoleConnection operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteInstanceConsoleConnection.go.html to see an example of how to use DeleteInstanceConsoleConnectionRequest. +type DeleteInstanceConsoleConnectionRequest struct { + + // The OCID of the instance console connection. + InstanceConsoleConnectionId *string `mandatory:"true" contributesTo:"path" name:"instanceConsoleConnectionId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteInstanceConsoleConnectionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteInstanceConsoleConnectionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteInstanceConsoleConnectionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteInstanceConsoleConnectionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteInstanceConsoleConnectionResponse wrapper for the DeleteInstanceConsoleConnection operation +type DeleteInstanceConsoleConnectionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteInstanceConsoleConnectionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteInstanceConsoleConnectionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_internet_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_internet_gateway_request_response.go new file mode 100644 index 000000000..53bded8f4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_internet_gateway_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteInternetGatewayRequest wrapper for the DeleteInternetGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteInternetGateway.go.html to see an example of how to use DeleteInternetGatewayRequest. +type DeleteInternetGatewayRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the internet gateway. + IgId *string `mandatory:"true" contributesTo:"path" name:"igId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteInternetGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteInternetGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteInternetGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteInternetGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteInternetGatewayResponse wrapper for the DeleteInternetGateway operation +type DeleteInternetGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteInternetGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteInternetGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_ipv6_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_ipv6_request_response.go new file mode 100644 index 000000000..3c5d37f66 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_ipv6_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteIpv6Request wrapper for the DeleteIpv6 operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteIpv6.go.html to see an example of how to use DeleteIpv6Request. +type DeleteIpv6Request struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the IPv6. + Ipv6Id *string `mandatory:"true" contributesTo:"path" name:"ipv6Id"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteIpv6Request) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteIpv6Request) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteIpv6Request) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteIpv6Request) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteIpv6Response wrapper for the DeleteIpv6 operation +type DeleteIpv6Response struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteIpv6Response) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteIpv6Response) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_local_peering_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_local_peering_gateway_request_response.go new file mode 100644 index 000000000..7fdbf3532 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_local_peering_gateway_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteLocalPeeringGatewayRequest wrapper for the DeleteLocalPeeringGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteLocalPeeringGateway.go.html to see an example of how to use DeleteLocalPeeringGatewayRequest. +type DeleteLocalPeeringGatewayRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the local peering gateway. + LocalPeeringGatewayId *string `mandatory:"true" contributesTo:"path" name:"localPeeringGatewayId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteLocalPeeringGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteLocalPeeringGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteLocalPeeringGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteLocalPeeringGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteLocalPeeringGatewayResponse wrapper for the DeleteLocalPeeringGateway operation +type DeleteLocalPeeringGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteLocalPeeringGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteLocalPeeringGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_nat_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_nat_gateway_request_response.go new file mode 100644 index 000000000..333a9e4e8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_nat_gateway_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteNatGatewayRequest wrapper for the DeleteNatGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteNatGateway.go.html to see an example of how to use DeleteNatGatewayRequest. +type DeleteNatGatewayRequest struct { + + // The NAT gateway's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + NatGatewayId *string `mandatory:"true" contributesTo:"path" name:"natGatewayId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteNatGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteNatGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteNatGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteNatGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteNatGatewayResponse wrapper for the DeleteNatGateway operation +type DeleteNatGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteNatGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteNatGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_network_security_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_network_security_group_request_response.go new file mode 100644 index 000000000..299fd2610 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_network_security_group_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteNetworkSecurityGroupRequest wrapper for the DeleteNetworkSecurityGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteNetworkSecurityGroup.go.html to see an example of how to use DeleteNetworkSecurityGroupRequest. +type DeleteNetworkSecurityGroupRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network security group. + NetworkSecurityGroupId *string `mandatory:"true" contributesTo:"path" name:"networkSecurityGroupId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteNetworkSecurityGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteNetworkSecurityGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteNetworkSecurityGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteNetworkSecurityGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteNetworkSecurityGroupResponse wrapper for the DeleteNetworkSecurityGroup operation +type DeleteNetworkSecurityGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteNetworkSecurityGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteNetworkSecurityGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_private_ip_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_private_ip_request_response.go new file mode 100644 index 000000000..807894c93 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_private_ip_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeletePrivateIpRequest wrapper for the DeletePrivateIp operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeletePrivateIp.go.html to see an example of how to use DeletePrivateIpRequest. +type DeletePrivateIpRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the private IP. + PrivateIpId *string `mandatory:"true" contributesTo:"path" name:"privateIpId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeletePrivateIpRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeletePrivateIpRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeletePrivateIpRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeletePrivateIpRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeletePrivateIpResponse wrapper for the DeletePrivateIp operation +type DeletePrivateIpResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeletePrivateIpResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeletePrivateIpResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_public_ip_pool_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_public_ip_pool_request_response.go new file mode 100644 index 000000000..9719cd39a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_public_ip_pool_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeletePublicIpPoolRequest wrapper for the DeletePublicIpPool operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeletePublicIpPool.go.html to see an example of how to use DeletePublicIpPoolRequest. +type DeletePublicIpPoolRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the public IP pool. + PublicIpPoolId *string `mandatory:"true" contributesTo:"path" name:"publicIpPoolId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeletePublicIpPoolRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeletePublicIpPoolRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeletePublicIpPoolRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeletePublicIpPoolRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeletePublicIpPoolResponse wrapper for the DeletePublicIpPool operation +type DeletePublicIpPoolResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeletePublicIpPoolResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeletePublicIpPoolResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_public_ip_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_public_ip_request_response.go new file mode 100644 index 000000000..05b81f895 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_public_ip_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeletePublicIpRequest wrapper for the DeletePublicIp operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeletePublicIp.go.html to see an example of how to use DeletePublicIpRequest. +type DeletePublicIpRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the public IP. + PublicIpId *string `mandatory:"true" contributesTo:"path" name:"publicIpId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeletePublicIpRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeletePublicIpRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeletePublicIpRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeletePublicIpRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeletePublicIpResponse wrapper for the DeletePublicIp operation +type DeletePublicIpResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeletePublicIpResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeletePublicIpResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_remote_peering_connection_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_remote_peering_connection_request_response.go new file mode 100644 index 000000000..a41a718c8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_remote_peering_connection_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteRemotePeeringConnectionRequest wrapper for the DeleteRemotePeeringConnection operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteRemotePeeringConnection.go.html to see an example of how to use DeleteRemotePeeringConnectionRequest. +type DeleteRemotePeeringConnectionRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the remote peering connection (RPC). + RemotePeeringConnectionId *string `mandatory:"true" contributesTo:"path" name:"remotePeeringConnectionId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteRemotePeeringConnectionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteRemotePeeringConnectionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteRemotePeeringConnectionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteRemotePeeringConnectionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteRemotePeeringConnectionResponse wrapper for the DeleteRemotePeeringConnection operation +type DeleteRemotePeeringConnectionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteRemotePeeringConnectionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteRemotePeeringConnectionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_route_table_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_route_table_request_response.go new file mode 100644 index 000000000..f28c13905 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_route_table_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteRouteTableRequest wrapper for the DeleteRouteTable operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteRouteTable.go.html to see an example of how to use DeleteRouteTableRequest. +type DeleteRouteTableRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the route table. + RtId *string `mandatory:"true" contributesTo:"path" name:"rtId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteRouteTableRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteRouteTableRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteRouteTableRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteRouteTableRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteRouteTableResponse wrapper for the DeleteRouteTable operation +type DeleteRouteTableResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteRouteTableResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteRouteTableResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_security_list_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_security_list_request_response.go new file mode 100644 index 000000000..5f55b9b69 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_security_list_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteSecurityListRequest wrapper for the DeleteSecurityList operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteSecurityList.go.html to see an example of how to use DeleteSecurityListRequest. +type DeleteSecurityListRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the security list. + SecurityListId *string `mandatory:"true" contributesTo:"path" name:"securityListId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteSecurityListRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteSecurityListRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteSecurityListRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteSecurityListRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteSecurityListResponse wrapper for the DeleteSecurityList operation +type DeleteSecurityListResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteSecurityListResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteSecurityListResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_service_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_service_gateway_request_response.go new file mode 100644 index 000000000..e698d2896 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_service_gateway_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteServiceGatewayRequest wrapper for the DeleteServiceGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteServiceGateway.go.html to see an example of how to use DeleteServiceGatewayRequest. +type DeleteServiceGatewayRequest struct { + + // The service gateway's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + ServiceGatewayId *string `mandatory:"true" contributesTo:"path" name:"serviceGatewayId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteServiceGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteServiceGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteServiceGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteServiceGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteServiceGatewayResponse wrapper for the DeleteServiceGateway operation +type DeleteServiceGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteServiceGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteServiceGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_subnet_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_subnet_request_response.go new file mode 100644 index 000000000..07f65043e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_subnet_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteSubnetRequest wrapper for the DeleteSubnet operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteSubnet.go.html to see an example of how to use DeleteSubnetRequest. +type DeleteSubnetRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the subnet. + SubnetId *string `mandatory:"true" contributesTo:"path" name:"subnetId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteSubnetRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteSubnetRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteSubnetRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteSubnetRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteSubnetResponse wrapper for the DeleteSubnet operation +type DeleteSubnetResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteSubnetResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteSubnetResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_vcn_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_vcn_request_response.go new file mode 100644 index 000000000..38e8c5dfd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_vcn_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteVcnRequest wrapper for the DeleteVcn operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVcn.go.html to see an example of how to use DeleteVcnRequest. +type DeleteVcnRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"true" contributesTo:"path" name:"vcnId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteVcnRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteVcnRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteVcnRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteVcnRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteVcnResponse wrapper for the DeleteVcn operation +type DeleteVcnResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteVcnResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteVcnResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_virtual_circuit_public_prefix_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_virtual_circuit_public_prefix_details.go new file mode 100644 index 000000000..56b9bd9f8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_virtual_circuit_public_prefix_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DeleteVirtualCircuitPublicPrefixDetails The representation of DeleteVirtualCircuitPublicPrefixDetails +type DeleteVirtualCircuitPublicPrefixDetails struct { + + // An individual public IP prefix (CIDR) to remove from the public virtual circuit. + CidrBlock *string `mandatory:"true" json:"cidrBlock"` +} + +func (m DeleteVirtualCircuitPublicPrefixDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_virtual_circuit_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_virtual_circuit_request_response.go new file mode 100644 index 000000000..1929ffb07 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_virtual_circuit_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteVirtualCircuitRequest wrapper for the DeleteVirtualCircuit operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVirtualCircuit.go.html to see an example of how to use DeleteVirtualCircuitRequest. +type DeleteVirtualCircuitRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the virtual circuit. + VirtualCircuitId *string `mandatory:"true" contributesTo:"path" name:"virtualCircuitId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteVirtualCircuitRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteVirtualCircuitRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteVirtualCircuitRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteVirtualCircuitRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteVirtualCircuitResponse wrapper for the DeleteVirtualCircuit operation +type DeleteVirtualCircuitResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteVirtualCircuitResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteVirtualCircuitResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_vlan_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_vlan_request_response.go new file mode 100644 index 000000000..08fc10705 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_vlan_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteVlanRequest wrapper for the DeleteVlan operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVlan.go.html to see an example of how to use DeleteVlanRequest. +type DeleteVlanRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VLAN. + VlanId *string `mandatory:"true" contributesTo:"path" name:"vlanId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteVlanRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteVlanRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteVlanRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteVlanRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteVlanResponse wrapper for the DeleteVlan operation +type DeleteVlanResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteVlanResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteVlanResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_backup_policy_assignment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_backup_policy_assignment_request_response.go new file mode 100644 index 000000000..17f35d6a2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_backup_policy_assignment_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteVolumeBackupPolicyAssignmentRequest wrapper for the DeleteVolumeBackupPolicyAssignment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVolumeBackupPolicyAssignment.go.html to see an example of how to use DeleteVolumeBackupPolicyAssignmentRequest. +type DeleteVolumeBackupPolicyAssignmentRequest struct { + + // The OCID of the volume backup policy assignment. + PolicyAssignmentId *string `mandatory:"true" contributesTo:"path" name:"policyAssignmentId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteVolumeBackupPolicyAssignmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteVolumeBackupPolicyAssignmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteVolumeBackupPolicyAssignmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteVolumeBackupPolicyAssignmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteVolumeBackupPolicyAssignmentResponse wrapper for the DeleteVolumeBackupPolicyAssignment operation +type DeleteVolumeBackupPolicyAssignmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteVolumeBackupPolicyAssignmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteVolumeBackupPolicyAssignmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_backup_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_backup_policy_request_response.go new file mode 100644 index 000000000..fa6e8d4e8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_backup_policy_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteVolumeBackupPolicyRequest wrapper for the DeleteVolumeBackupPolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVolumeBackupPolicy.go.html to see an example of how to use DeleteVolumeBackupPolicyRequest. +type DeleteVolumeBackupPolicyRequest struct { + + // The OCID of the volume backup policy. + PolicyId *string `mandatory:"true" contributesTo:"path" name:"policyId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteVolumeBackupPolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteVolumeBackupPolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteVolumeBackupPolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteVolumeBackupPolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteVolumeBackupPolicyResponse wrapper for the DeleteVolumeBackupPolicy operation +type DeleteVolumeBackupPolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteVolumeBackupPolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteVolumeBackupPolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_backup_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_backup_request_response.go new file mode 100644 index 000000000..c97658c9d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_backup_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteVolumeBackupRequest wrapper for the DeleteVolumeBackup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVolumeBackup.go.html to see an example of how to use DeleteVolumeBackupRequest. +type DeleteVolumeBackupRequest struct { + + // The OCID of the volume backup. + VolumeBackupId *string `mandatory:"true" contributesTo:"path" name:"volumeBackupId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteVolumeBackupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteVolumeBackupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteVolumeBackupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteVolumeBackupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteVolumeBackupResponse wrapper for the DeleteVolumeBackup operation +type DeleteVolumeBackupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteVolumeBackupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteVolumeBackupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_group_backup_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_group_backup_request_response.go new file mode 100644 index 000000000..8a69fa12d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_group_backup_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteVolumeGroupBackupRequest wrapper for the DeleteVolumeGroupBackup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVolumeGroupBackup.go.html to see an example of how to use DeleteVolumeGroupBackupRequest. +type DeleteVolumeGroupBackupRequest struct { + + // The Oracle Cloud ID (OCID) that uniquely identifies the volume group backup. + VolumeGroupBackupId *string `mandatory:"true" contributesTo:"path" name:"volumeGroupBackupId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteVolumeGroupBackupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteVolumeGroupBackupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteVolumeGroupBackupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteVolumeGroupBackupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteVolumeGroupBackupResponse wrapper for the DeleteVolumeGroupBackup operation +type DeleteVolumeGroupBackupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteVolumeGroupBackupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteVolumeGroupBackupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_group_request_response.go new file mode 100644 index 000000000..e850c5407 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_group_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteVolumeGroupRequest wrapper for the DeleteVolumeGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVolumeGroup.go.html to see an example of how to use DeleteVolumeGroupRequest. +type DeleteVolumeGroupRequest struct { + + // The Oracle Cloud ID (OCID) that uniquely identifies the volume group. + VolumeGroupId *string `mandatory:"true" contributesTo:"path" name:"volumeGroupId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteVolumeGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteVolumeGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteVolumeGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteVolumeGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteVolumeGroupResponse wrapper for the DeleteVolumeGroup operation +type DeleteVolumeGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteVolumeGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteVolumeGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_kms_key_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_kms_key_request_response.go new file mode 100644 index 000000000..b9978568d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_kms_key_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteVolumeKmsKeyRequest wrapper for the DeleteVolumeKmsKey operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVolumeKmsKey.go.html to see an example of how to use DeleteVolumeKmsKeyRequest. +type DeleteVolumeKmsKeyRequest struct { + + // The OCID of the volume. + VolumeId *string `mandatory:"true" contributesTo:"path" name:"volumeId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteVolumeKmsKeyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteVolumeKmsKeyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteVolumeKmsKeyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteVolumeKmsKeyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteVolumeKmsKeyResponse wrapper for the DeleteVolumeKmsKey operation +type DeleteVolumeKmsKeyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteVolumeKmsKeyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteVolumeKmsKeyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_request_response.go new file mode 100644 index 000000000..93ad0834d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/delete_volume_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteVolumeRequest wrapper for the DeleteVolume operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DeleteVolume.go.html to see an example of how to use DeleteVolumeRequest. +type DeleteVolumeRequest struct { + + // The OCID of the volume. + VolumeId *string `mandatory:"true" contributesTo:"path" name:"volumeId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteVolumeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteVolumeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteVolumeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteVolumeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteVolumeResponse wrapper for the DeleteVolume operation +type DeleteVolumeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteVolumeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteVolumeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_boot_volume_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_boot_volume_request_response.go new file mode 100644 index 000000000..b654dc55e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_boot_volume_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DetachBootVolumeRequest wrapper for the DetachBootVolume operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DetachBootVolume.go.html to see an example of how to use DetachBootVolumeRequest. +type DetachBootVolumeRequest struct { + + // The OCID of the boot volume attachment. + BootVolumeAttachmentId *string `mandatory:"true" contributesTo:"path" name:"bootVolumeAttachmentId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DetachBootVolumeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DetachBootVolumeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DetachBootVolumeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DetachBootVolumeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DetachBootVolumeResponse wrapper for the DetachBootVolume operation +type DetachBootVolumeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DetachBootVolumeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DetachBootVolumeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_instance_pool_instance_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_instance_pool_instance_details.go new file mode 100644 index 000000000..c7ce2d93e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_instance_pool_instance_details.go @@ -0,0 +1,38 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DetachInstancePoolInstanceDetails An instance that is to be detached from an instance pool. +type DetachInstancePoolInstanceDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // Whether to decrease the size of the instance pool when the instance is detached. If `true`, the + // pool size is decreased. If `false`, the pool will provision a new, replacement instance + // using the pool's instance configuration as a template. Default is `true`. + IsDecrementSize *bool `mandatory:"false" json:"isDecrementSize"` + + // Whether to permanently terminate (delete) the instance and its attached boot volume + // when detaching it from the instance pool. Default is `false`. + IsAutoTerminate *bool `mandatory:"false" json:"isAutoTerminate"` +} + +func (m DetachInstancePoolInstanceDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_instance_pool_instance_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_instance_pool_instance_request_response.go new file mode 100644 index 000000000..5c48352a7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_instance_pool_instance_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DetachInstancePoolInstanceRequest wrapper for the DetachInstancePoolInstance operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DetachInstancePoolInstance.go.html to see an example of how to use DetachInstancePoolInstanceRequest. +type DetachInstancePoolInstanceRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" contributesTo:"path" name:"instancePoolId"` + + // Instance being detached + DetachInstancePoolInstanceDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DetachInstancePoolInstanceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DetachInstancePoolInstanceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DetachInstancePoolInstanceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DetachInstancePoolInstanceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DetachInstancePoolInstanceResponse wrapper for the DetachInstancePoolInstance operation +type DetachInstancePoolInstanceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response DetachInstancePoolInstanceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DetachInstancePoolInstanceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_load_balancer_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_load_balancer_details.go new file mode 100644 index 000000000..6cb387a43 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_load_balancer_details.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DetachLoadBalancerDetails Represents a load balancer that is to be detached from an instance pool. +type DetachLoadBalancerDetails struct { + + // The OCID of the load balancer to detach from the instance pool. + LoadBalancerId *string `mandatory:"true" json:"loadBalancerId"` + + // The name of the backend set on the load balancer to detach from the instance pool. + BackendSetName *string `mandatory:"true" json:"backendSetName"` +} + +func (m DetachLoadBalancerDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_load_balancer_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_load_balancer_request_response.go new file mode 100644 index 000000000..7bad2e252 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_load_balancer_request_response.go @@ -0,0 +1,92 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DetachLoadBalancerRequest wrapper for the DetachLoadBalancer operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DetachLoadBalancer.go.html to see an example of how to use DetachLoadBalancerRequest. +type DetachLoadBalancerRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" contributesTo:"path" name:"instancePoolId"` + + // Load balancer being detached + DetachLoadBalancerDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DetachLoadBalancerRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DetachLoadBalancerRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DetachLoadBalancerRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DetachLoadBalancerRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DetachLoadBalancerResponse wrapper for the DetachLoadBalancer operation +type DetachLoadBalancerResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstancePool instance + InstancePool `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DetachLoadBalancerResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DetachLoadBalancerResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_service_id_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_service_id_request_response.go new file mode 100644 index 000000000..243e79445 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_service_id_request_response.go @@ -0,0 +1,82 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DetachServiceIdRequest wrapper for the DetachServiceId operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DetachServiceId.go.html to see an example of how to use DetachServiceIdRequest. +type DetachServiceIdRequest struct { + + // The service gateway's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + ServiceGatewayId *string `mandatory:"true" contributesTo:"path" name:"serviceGatewayId"` + + // ServiceId of Service to be detached from a service gateway. + DetachServiceDetails ServiceIdRequestDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DetachServiceIdRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DetachServiceIdRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DetachServiceIdRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DetachServiceIdRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DetachServiceIdResponse wrapper for the DetachServiceId operation +type DetachServiceIdResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ServiceGateway instance + ServiceGateway `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DetachServiceIdResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DetachServiceIdResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_vnic_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_vnic_request_response.go new file mode 100644 index 000000000..9740c5f79 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_vnic_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DetachVnicRequest wrapper for the DetachVnic operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DetachVnic.go.html to see an example of how to use DetachVnicRequest. +type DetachVnicRequest struct { + + // The OCID of the VNIC attachment. + VnicAttachmentId *string `mandatory:"true" contributesTo:"path" name:"vnicAttachmentId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DetachVnicRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DetachVnicRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DetachVnicRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DetachVnicRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DetachVnicResponse wrapper for the DetachVnic operation +type DetachVnicResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DetachVnicResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DetachVnicResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_volume_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_volume_request_response.go new file mode 100644 index 000000000..21d7f017f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/detach_volume_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DetachVolumeRequest wrapper for the DetachVolume operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/DetachVolume.go.html to see an example of how to use DetachVolumeRequest. +type DetachVolumeRequest struct { + + // The OCID of the volume attachment. + VolumeAttachmentId *string `mandatory:"true" contributesTo:"path" name:"volumeAttachmentId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DetachVolumeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DetachVolumeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DetachVolumeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DetachVolumeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DetachVolumeResponse wrapper for the DetachVolume operation +type DetachVolumeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DetachVolumeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DetachVolumeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/device.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/device.go new file mode 100644 index 000000000..77ee6dd50 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/device.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Device Device Path corresponding to the block devices attached to instances having a name and isAvailable flag. +type Device struct { + + // The device name. + Name *string `mandatory:"true" json:"name"` + + // The flag denoting whether device is available. + IsAvailable *bool `mandatory:"true" json:"isAvailable"` +} + +func (m Device) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_dns_option.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_dns_option.go new file mode 100644 index 000000000..5660104d5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_dns_option.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DhcpDnsOption DHCP option for specifying how DNS (hostname resolution) is handled in the subnets in the VCN. +// For more information, see +// DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). +type DhcpDnsOption struct { + + // If you set `serverType` to `CustomDnsServer`, specify the + // IP address of at least one DNS server of your choice (three maximum). + CustomDnsServers []string `mandatory:"false" json:"customDnsServers"` + + // * **VcnLocal:** Reserved for future use. + // * **VcnLocalPlusInternet:** Also referred to as "Internet and VCN Resolver". + // Instances can resolve internet hostnames (no internet gateway is required), + // and can resolve hostnames of instances in the VCN. This is the default + // value in the default set of DHCP options in the VCN. For the Internet and + // VCN Resolver to work across the VCN, there must also be a DNS label set for + // the VCN, a DNS label set for each subnet, and a hostname for each instance. + // The Internet and VCN Resolver also enables reverse DNS lookup, which lets + // you determine the hostname corresponding to the private IP address. For more + // information, see + // DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). + // * **CustomDnsServer:** Instances use a DNS server of your choice (three + // maximum). + ServerType DhcpDnsOptionServerTypeEnum `mandatory:"true" json:"serverType"` +} + +func (m DhcpDnsOption) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m DhcpDnsOption) MarshalJSON() (buff []byte, e error) { + type MarshalTypeDhcpDnsOption DhcpDnsOption + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeDhcpDnsOption + }{ + "DomainNameServer", + (MarshalTypeDhcpDnsOption)(m), + } + + return json.Marshal(&s) +} + +// DhcpDnsOptionServerTypeEnum Enum with underlying type: string +type DhcpDnsOptionServerTypeEnum string + +// Set of constants representing the allowable values for DhcpDnsOptionServerTypeEnum +const ( + DhcpDnsOptionServerTypeVcnlocal DhcpDnsOptionServerTypeEnum = "VcnLocal" + DhcpDnsOptionServerTypeVcnlocalplusinternet DhcpDnsOptionServerTypeEnum = "VcnLocalPlusInternet" + DhcpDnsOptionServerTypeCustomdnsserver DhcpDnsOptionServerTypeEnum = "CustomDnsServer" +) + +var mappingDhcpDnsOptionServerType = map[string]DhcpDnsOptionServerTypeEnum{ + "VcnLocal": DhcpDnsOptionServerTypeVcnlocal, + "VcnLocalPlusInternet": DhcpDnsOptionServerTypeVcnlocalplusinternet, + "CustomDnsServer": DhcpDnsOptionServerTypeCustomdnsserver, +} + +// GetDhcpDnsOptionServerTypeEnumValues Enumerates the set of values for DhcpDnsOptionServerTypeEnum +func GetDhcpDnsOptionServerTypeEnumValues() []DhcpDnsOptionServerTypeEnum { + values := make([]DhcpDnsOptionServerTypeEnum, 0) + for _, v := range mappingDhcpDnsOptionServerType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_option.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_option.go new file mode 100644 index 000000000..684d846c9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_option.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DhcpOption A single DHCP option according to RFC 1533 (https://tools.ietf.org/html/rfc1533). +// The two options available to use are DhcpDnsOption +// and DhcpSearchDomainOption. For more +// information, see DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm) +// and DHCP Options (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingDHCP.htm). +type DhcpOption interface { +} + +type dhcpoption struct { + JsonData []byte + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *dhcpoption) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerdhcpoption dhcpoption + s := struct { + Model Unmarshalerdhcpoption + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *dhcpoption) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "DomainNameServer": + mm := DhcpDnsOption{} + err = json.Unmarshal(data, &mm) + return mm, err + case "SearchDomain": + mm := DhcpSearchDomainOption{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +func (m dhcpoption) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_options.go new file mode 100644 index 000000000..0d48af930 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_options.go @@ -0,0 +1,179 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DhcpOptions A set of DHCP options. Used by the VCN to automatically provide configuration +// information to the instances when they boot up. There are two options you can set: +// - DhcpDnsOption: Lets you specify how DNS (hostname resolution) is +// handled in the subnets in your VCN. +// - DhcpSearchDomainOption: Lets you specify +// a search domain name to use for DNS queries. +// For more information, see DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm) +// and DHCP Options (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingDHCP.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type DhcpOptions struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the set of DHCP options. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // Oracle ID (OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)) for the set of DHCP options. + Id *string `mandatory:"true" json:"id"` + + // The current state of the set of DHCP options. + LifecycleState DhcpOptionsLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The collection of individual DHCP options. + Options []DhcpOption `mandatory:"true" json:"options"` + + // Date and time the set of DHCP options was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN the set of DHCP options belongs to. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The search domain name type of DHCP options + DomainNameType DhcpOptionsDomainNameTypeEnum `mandatory:"false" json:"domainNameType,omitempty"` +} + +func (m DhcpOptions) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *DhcpOptions) UnmarshalJSON(data []byte) (e error) { + model := struct { + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + DisplayName *string `json:"displayName"` + FreeformTags map[string]string `json:"freeformTags"` + DomainNameType DhcpOptionsDomainNameTypeEnum `json:"domainNameType"` + CompartmentId *string `json:"compartmentId"` + Id *string `json:"id"` + LifecycleState DhcpOptionsLifecycleStateEnum `json:"lifecycleState"` + Options []dhcpoption `json:"options"` + TimeCreated *common.SDKTime `json:"timeCreated"` + VcnId *string `json:"vcnId"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.DefinedTags = model.DefinedTags + + m.DisplayName = model.DisplayName + + m.FreeformTags = model.FreeformTags + + m.DomainNameType = model.DomainNameType + + m.CompartmentId = model.CompartmentId + + m.Id = model.Id + + m.LifecycleState = model.LifecycleState + + m.Options = make([]DhcpOption, len(model.Options)) + for i, n := range model.Options { + nn, e = n.UnmarshalPolymorphicJSON(n.JsonData) + if e != nil { + return e + } + if nn != nil { + m.Options[i] = nn.(DhcpOption) + } else { + m.Options[i] = nil + } + } + + m.TimeCreated = model.TimeCreated + + m.VcnId = model.VcnId + + return +} + +// DhcpOptionsLifecycleStateEnum Enum with underlying type: string +type DhcpOptionsLifecycleStateEnum string + +// Set of constants representing the allowable values for DhcpOptionsLifecycleStateEnum +const ( + DhcpOptionsLifecycleStateProvisioning DhcpOptionsLifecycleStateEnum = "PROVISIONING" + DhcpOptionsLifecycleStateAvailable DhcpOptionsLifecycleStateEnum = "AVAILABLE" + DhcpOptionsLifecycleStateTerminating DhcpOptionsLifecycleStateEnum = "TERMINATING" + DhcpOptionsLifecycleStateTerminated DhcpOptionsLifecycleStateEnum = "TERMINATED" +) + +var mappingDhcpOptionsLifecycleState = map[string]DhcpOptionsLifecycleStateEnum{ + "PROVISIONING": DhcpOptionsLifecycleStateProvisioning, + "AVAILABLE": DhcpOptionsLifecycleStateAvailable, + "TERMINATING": DhcpOptionsLifecycleStateTerminating, + "TERMINATED": DhcpOptionsLifecycleStateTerminated, +} + +// GetDhcpOptionsLifecycleStateEnumValues Enumerates the set of values for DhcpOptionsLifecycleStateEnum +func GetDhcpOptionsLifecycleStateEnumValues() []DhcpOptionsLifecycleStateEnum { + values := make([]DhcpOptionsLifecycleStateEnum, 0) + for _, v := range mappingDhcpOptionsLifecycleState { + values = append(values, v) + } + return values +} + +// DhcpOptionsDomainNameTypeEnum Enum with underlying type: string +type DhcpOptionsDomainNameTypeEnum string + +// Set of constants representing the allowable values for DhcpOptionsDomainNameTypeEnum +const ( + DhcpOptionsDomainNameTypeSubnetDomain DhcpOptionsDomainNameTypeEnum = "SUBNET_DOMAIN" + DhcpOptionsDomainNameTypeVcnDomain DhcpOptionsDomainNameTypeEnum = "VCN_DOMAIN" + DhcpOptionsDomainNameTypeCustomDomain DhcpOptionsDomainNameTypeEnum = "CUSTOM_DOMAIN" +) + +var mappingDhcpOptionsDomainNameType = map[string]DhcpOptionsDomainNameTypeEnum{ + "SUBNET_DOMAIN": DhcpOptionsDomainNameTypeSubnetDomain, + "VCN_DOMAIN": DhcpOptionsDomainNameTypeVcnDomain, + "CUSTOM_DOMAIN": DhcpOptionsDomainNameTypeCustomDomain, +} + +// GetDhcpOptionsDomainNameTypeEnumValues Enumerates the set of values for DhcpOptionsDomainNameTypeEnum +func GetDhcpOptionsDomainNameTypeEnumValues() []DhcpOptionsDomainNameTypeEnum { + values := make([]DhcpOptionsDomainNameTypeEnum, 0) + for _, v := range mappingDhcpOptionsDomainNameType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_search_domain_option.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_search_domain_option.go new file mode 100644 index 000000000..e337b44ee --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/dhcp_search_domain_option.go @@ -0,0 +1,55 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DhcpSearchDomainOption DHCP option for specifying a search domain name for DNS queries. For more information, see +// DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). +type DhcpSearchDomainOption struct { + + // A single search domain name according to RFC 952 (https://tools.ietf.org/html/rfc952) + // and RFC 1123 (https://tools.ietf.org/html/rfc1123). During a DNS query, + // the OS will append this search domain name to the value being queried. + // If you set DhcpDnsOption to `VcnLocalPlusInternet`, + // and you assign a DNS label to the VCN during creation, the search domain name in the + // VCN's default set of DHCP options is automatically set to the VCN domain + // (for example, `vcn1.oraclevcn.com`). + // If you don't want to use a search domain name, omit this option from the + // set of DHCP options. Do not include this option with an empty list + // of search domain names, or with an empty string as the value for any search + // domain name. + SearchDomainNames []string `mandatory:"true" json:"searchDomainNames"` +} + +func (m DhcpSearchDomainOption) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m DhcpSearchDomainOption) MarshalJSON() (buff []byte, e error) { + type MarshalTypeDhcpSearchDomainOption DhcpSearchDomainOption + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeDhcpSearchDomainOption + }{ + "SearchDomain", + (MarshalTypeDhcpSearchDomainOption)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/dpd_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/dpd_config.go new file mode 100644 index 000000000..c7e14ca28 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/dpd_config.go @@ -0,0 +1,55 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DpdConfig DPD Configuration Details +type DpdConfig struct { + + // dpd mode + DpdMode DpdConfigDpdModeEnum `mandatory:"false" json:"dpdMode,omitempty"` + + // DPD Timeout in seconds. + DpdTimeoutInSec *int `mandatory:"false" json:"dpdTimeoutInSec"` +} + +func (m DpdConfig) String() string { + return common.PointerString(m) +} + +// DpdConfigDpdModeEnum Enum with underlying type: string +type DpdConfigDpdModeEnum string + +// Set of constants representing the allowable values for DpdConfigDpdModeEnum +const ( + DpdConfigDpdModeInitiateAndRespond DpdConfigDpdModeEnum = "INITIATE_AND_RESPOND" + DpdConfigDpdModeRespondOnly DpdConfigDpdModeEnum = "RESPOND_ONLY" +) + +var mappingDpdConfigDpdMode = map[string]DpdConfigDpdModeEnum{ + "INITIATE_AND_RESPOND": DpdConfigDpdModeInitiateAndRespond, + "RESPOND_ONLY": DpdConfigDpdModeRespondOnly, +} + +// GetDpdConfigDpdModeEnumValues Enumerates the set of values for DpdConfigDpdModeEnum +func GetDpdConfigDpdModeEnumValues() []DpdConfigDpdModeEnum { + values := make([]DpdConfigDpdModeEnum, 0) + for _, v := range mappingDpdConfigDpdMode { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/drg.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg.go new file mode 100644 index 000000000..47f04e1d0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg.go @@ -0,0 +1,92 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Drg A dynamic routing gateway (DRG) is a virtual router that provides a path for private +// network traffic between networks. You use it with other Networking +// Service components to create a connection to your on-premises network using Site-to-Site VPN (https://docs.cloud.oracle.com/Content/Network/Tasks/managingIPsec.htm) or a connection that uses +// FastConnect (https://docs.cloud.oracle.com/Content/Network/Concepts/fastconnect.htm). For more information, see +// Overview of the Networking Service (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type Drg struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the compartment containing the DRG. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The DRG's Oracle ID (OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"true" json:"id"` + + // The DRG's current state. + LifecycleState DrgLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The date and time the DRG was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + DefaultDrgRouteTables *DefaultDrgRouteTables `mandatory:"false" json:"defaultDrgRouteTables"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of this DRG's default export route distribution for the DRG attachments. + DefaultExportDrgRouteDistributionId *string `mandatory:"false" json:"defaultExportDrgRouteDistributionId"` +} + +func (m Drg) String() string { + return common.PointerString(m) +} + +// DrgLifecycleStateEnum Enum with underlying type: string +type DrgLifecycleStateEnum string + +// Set of constants representing the allowable values for DrgLifecycleStateEnum +const ( + DrgLifecycleStateProvisioning DrgLifecycleStateEnum = "PROVISIONING" + DrgLifecycleStateAvailable DrgLifecycleStateEnum = "AVAILABLE" + DrgLifecycleStateTerminating DrgLifecycleStateEnum = "TERMINATING" + DrgLifecycleStateTerminated DrgLifecycleStateEnum = "TERMINATED" +) + +var mappingDrgLifecycleState = map[string]DrgLifecycleStateEnum{ + "PROVISIONING": DrgLifecycleStateProvisioning, + "AVAILABLE": DrgLifecycleStateAvailable, + "TERMINATING": DrgLifecycleStateTerminating, + "TERMINATED": DrgLifecycleStateTerminated, +} + +// GetDrgLifecycleStateEnumValues Enumerates the set of values for DrgLifecycleStateEnum +func GetDrgLifecycleStateEnumValues() []DrgLifecycleStateEnum { + values := make([]DrgLifecycleStateEnum, 0) + for _, v := range mappingDrgLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment.go new file mode 100644 index 000000000..53ea0daf7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment.go @@ -0,0 +1,175 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DrgAttachment A DRG attachment serves as a link between a DRG and a network resource. A DRG can be attached to a VCN, +// IPSec tunnel, remote peering connection, or virtual circuit. +// For more information, see Overview of the Networking Service (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm). +type DrgAttachment struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the compartment containing the DRG attachment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"true" json:"drgId"` + + // The DRG attachment's Oracle ID (OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"true" json:"id"` + + // The DRG attachment's current state. + LifecycleState DrgAttachmentLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The date and time the DRG attachment was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG route table that is assigned to this attachment. + // The DRG route table manages traffic inside the DRG. + DrgRouteTableId *string `mandatory:"false" json:"drgRouteTableId"` + + NetworkDetails DrgAttachmentNetworkDetails `mandatory:"false" json:"networkDetails"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route table the DRG attachment is using. + // For information about why you would associate a route table with a DRG attachment, see: + // * Transit Routing: Access to Multiple VCNs in Same Region (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitrouting.htm) + // * Transit Routing: Private Access to Oracle Services (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitroutingoracleservices.htm) + // This field is deprecated. Instead, use the `networkDetails` field to view the OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the attached resource. + RouteTableId *string `mandatory:"false" json:"routeTableId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the VCN. + // This field is deprecated. Instead, use the `networkDetails` field to view the OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the attached resource. + VcnId *string `mandatory:"false" json:"vcnId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the export route distribution used to specify how routes in the assigned DRG route table + // are advertised to the attachment. + // If this value is null, no routes are advertised through this attachment. + ExportDrgRouteDistributionId *string `mandatory:"false" json:"exportDrgRouteDistributionId"` + + // Indicates whether the DRG attachment and attached network live in a different tenancy than the DRG. + // Example: `false` + IsCrossTenancy *bool `mandatory:"false" json:"isCrossTenancy"` +} + +func (m DrgAttachment) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *DrgAttachment) UnmarshalJSON(data []byte) (e error) { + model := struct { + DisplayName *string `json:"displayName"` + TimeCreated *common.SDKTime `json:"timeCreated"` + DrgRouteTableId *string `json:"drgRouteTableId"` + NetworkDetails drgattachmentnetworkdetails `json:"networkDetails"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + FreeformTags map[string]string `json:"freeformTags"` + RouteTableId *string `json:"routeTableId"` + VcnId *string `json:"vcnId"` + ExportDrgRouteDistributionId *string `json:"exportDrgRouteDistributionId"` + IsCrossTenancy *bool `json:"isCrossTenancy"` + CompartmentId *string `json:"compartmentId"` + DrgId *string `json:"drgId"` + Id *string `json:"id"` + LifecycleState DrgAttachmentLifecycleStateEnum `json:"lifecycleState"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.DisplayName = model.DisplayName + + m.TimeCreated = model.TimeCreated + + m.DrgRouteTableId = model.DrgRouteTableId + + nn, e = model.NetworkDetails.UnmarshalPolymorphicJSON(model.NetworkDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.NetworkDetails = nn.(DrgAttachmentNetworkDetails) + } else { + m.NetworkDetails = nil + } + + m.DefinedTags = model.DefinedTags + + m.FreeformTags = model.FreeformTags + + m.RouteTableId = model.RouteTableId + + m.VcnId = model.VcnId + + m.ExportDrgRouteDistributionId = model.ExportDrgRouteDistributionId + + m.IsCrossTenancy = model.IsCrossTenancy + + m.CompartmentId = model.CompartmentId + + m.DrgId = model.DrgId + + m.Id = model.Id + + m.LifecycleState = model.LifecycleState + + return +} + +// DrgAttachmentLifecycleStateEnum Enum with underlying type: string +type DrgAttachmentLifecycleStateEnum string + +// Set of constants representing the allowable values for DrgAttachmentLifecycleStateEnum +const ( + DrgAttachmentLifecycleStateAttaching DrgAttachmentLifecycleStateEnum = "ATTACHING" + DrgAttachmentLifecycleStateAttached DrgAttachmentLifecycleStateEnum = "ATTACHED" + DrgAttachmentLifecycleStateDetaching DrgAttachmentLifecycleStateEnum = "DETACHING" + DrgAttachmentLifecycleStateDetached DrgAttachmentLifecycleStateEnum = "DETACHED" +) + +var mappingDrgAttachmentLifecycleState = map[string]DrgAttachmentLifecycleStateEnum{ + "ATTACHING": DrgAttachmentLifecycleStateAttaching, + "ATTACHED": DrgAttachmentLifecycleStateAttached, + "DETACHING": DrgAttachmentLifecycleStateDetaching, + "DETACHED": DrgAttachmentLifecycleStateDetached, +} + +// GetDrgAttachmentLifecycleStateEnumValues Enumerates the set of values for DrgAttachmentLifecycleStateEnum +func GetDrgAttachmentLifecycleStateEnumValues() []DrgAttachmentLifecycleStateEnum { + values := make([]DrgAttachmentLifecycleStateEnum, 0) + for _, v := range mappingDrgAttachmentLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_id_drg_route_distribution_match_criteria.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_id_drg_route_distribution_match_criteria.go new file mode 100644 index 000000000..28fb077cb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_id_drg_route_distribution_match_criteria.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DrgAttachmentIdDrgRouteDistributionMatchCriteria The criteria by which a specific attachment will import routes to the DRG. +type DrgAttachmentIdDrgRouteDistributionMatchCriteria struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG attachment. + DrgAttachmentId *string `mandatory:"true" json:"drgAttachmentId"` +} + +func (m DrgAttachmentIdDrgRouteDistributionMatchCriteria) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m DrgAttachmentIdDrgRouteDistributionMatchCriteria) MarshalJSON() (buff []byte, e error) { + type MarshalTypeDrgAttachmentIdDrgRouteDistributionMatchCriteria DrgAttachmentIdDrgRouteDistributionMatchCriteria + s := struct { + DiscriminatorParam string `json:"matchType"` + MarshalTypeDrgAttachmentIdDrgRouteDistributionMatchCriteria + }{ + "DRG_ATTACHMENT_ID", + (MarshalTypeDrgAttachmentIdDrgRouteDistributionMatchCriteria)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_info.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_info.go new file mode 100644 index 000000000..142588f7a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_info.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DrgAttachmentInfo The `DrgAttachmentInfo` resource contains the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG attachment. +type DrgAttachmentInfo struct { + + // The Oracle-assigned ID of the DRG attachment + Id *string `mandatory:"true" json:"id"` +} + +func (m DrgAttachmentInfo) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_network_create_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_network_create_details.go new file mode 100644 index 000000000..18f2780ed --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_network_create_details.go @@ -0,0 +1,97 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DrgAttachmentNetworkCreateDetails The representation of DrgAttachmentNetworkCreateDetails +type DrgAttachmentNetworkCreateDetails interface { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the network attached to the DRG. + GetId() *string +} + +type drgattachmentnetworkcreatedetails struct { + JsonData []byte + Id *string `mandatory:"true" json:"id"` + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *drgattachmentnetworkcreatedetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerdrgattachmentnetworkcreatedetails drgattachmentnetworkcreatedetails + s := struct { + Model Unmarshalerdrgattachmentnetworkcreatedetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.Id = s.Model.Id + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *drgattachmentnetworkcreatedetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "VCN": + mm := VcnDrgAttachmentNetworkCreateDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetId returns Id +func (m drgattachmentnetworkcreatedetails) GetId() *string { + return m.Id +} + +func (m drgattachmentnetworkcreatedetails) String() string { + return common.PointerString(m) +} + +// DrgAttachmentNetworkCreateDetailsTypeEnum Enum with underlying type: string +type DrgAttachmentNetworkCreateDetailsTypeEnum string + +// Set of constants representing the allowable values for DrgAttachmentNetworkCreateDetailsTypeEnum +const ( + DrgAttachmentNetworkCreateDetailsTypeVcn DrgAttachmentNetworkCreateDetailsTypeEnum = "VCN" +) + +var mappingDrgAttachmentNetworkCreateDetailsType = map[string]DrgAttachmentNetworkCreateDetailsTypeEnum{ + "VCN": DrgAttachmentNetworkCreateDetailsTypeVcn, +} + +// GetDrgAttachmentNetworkCreateDetailsTypeEnumValues Enumerates the set of values for DrgAttachmentNetworkCreateDetailsTypeEnum +func GetDrgAttachmentNetworkCreateDetailsTypeEnumValues() []DrgAttachmentNetworkCreateDetailsTypeEnum { + values := make([]DrgAttachmentNetworkCreateDetailsTypeEnum, 0) + for _, v := range mappingDrgAttachmentNetworkCreateDetailsType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_network_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_network_details.go new file mode 100644 index 000000000..611576d6a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_network_details.go @@ -0,0 +1,115 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DrgAttachmentNetworkDetails The representation of DrgAttachmentNetworkDetails +type DrgAttachmentNetworkDetails interface { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network attached to the DRG. + GetId() *string +} + +type drgattachmentnetworkdetails struct { + JsonData []byte + Id *string `mandatory:"true" json:"id"` + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *drgattachmentnetworkdetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerdrgattachmentnetworkdetails drgattachmentnetworkdetails + s := struct { + Model Unmarshalerdrgattachmentnetworkdetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.Id = s.Model.Id + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *drgattachmentnetworkdetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "VCN": + mm := VcnDrgAttachmentNetworkDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "IPSEC_TUNNEL": + mm := IpsecTunnelDrgAttachmentNetworkDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "VIRTUAL_CIRCUIT": + mm := VirtualCircuitDrgAttachmentNetworkDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "REMOTE_PEERING_CONNECTION": + mm := RemotePeeringConnectionDrgAttachmentNetworkDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetId returns Id +func (m drgattachmentnetworkdetails) GetId() *string { + return m.Id +} + +func (m drgattachmentnetworkdetails) String() string { + return common.PointerString(m) +} + +// DrgAttachmentNetworkDetailsTypeEnum Enum with underlying type: string +type DrgAttachmentNetworkDetailsTypeEnum string + +// Set of constants representing the allowable values for DrgAttachmentNetworkDetailsTypeEnum +const ( + DrgAttachmentNetworkDetailsTypeVcn DrgAttachmentNetworkDetailsTypeEnum = "VCN" + DrgAttachmentNetworkDetailsTypeIpsecTunnel DrgAttachmentNetworkDetailsTypeEnum = "IPSEC_TUNNEL" + DrgAttachmentNetworkDetailsTypeVirtualCircuit DrgAttachmentNetworkDetailsTypeEnum = "VIRTUAL_CIRCUIT" + DrgAttachmentNetworkDetailsTypeRemotePeeringConnection DrgAttachmentNetworkDetailsTypeEnum = "REMOTE_PEERING_CONNECTION" +) + +var mappingDrgAttachmentNetworkDetailsType = map[string]DrgAttachmentNetworkDetailsTypeEnum{ + "VCN": DrgAttachmentNetworkDetailsTypeVcn, + "IPSEC_TUNNEL": DrgAttachmentNetworkDetailsTypeIpsecTunnel, + "VIRTUAL_CIRCUIT": DrgAttachmentNetworkDetailsTypeVirtualCircuit, + "REMOTE_PEERING_CONNECTION": DrgAttachmentNetworkDetailsTypeRemotePeeringConnection, +} + +// GetDrgAttachmentNetworkDetailsTypeEnumValues Enumerates the set of values for DrgAttachmentNetworkDetailsTypeEnum +func GetDrgAttachmentNetworkDetailsTypeEnumValues() []DrgAttachmentNetworkDetailsTypeEnum { + values := make([]DrgAttachmentNetworkDetailsTypeEnum, 0) + for _, v := range mappingDrgAttachmentNetworkDetailsType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_network_update_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_network_update_details.go new file mode 100644 index 000000000..059cbbe68 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_network_update_details.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DrgAttachmentNetworkUpdateDetails The representation of DrgAttachmentNetworkUpdateDetails +type DrgAttachmentNetworkUpdateDetails interface { +} + +type drgattachmentnetworkupdatedetails struct { + JsonData []byte + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *drgattachmentnetworkupdatedetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerdrgattachmentnetworkupdatedetails drgattachmentnetworkupdatedetails + s := struct { + Model Unmarshalerdrgattachmentnetworkupdatedetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *drgattachmentnetworkupdatedetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "VCN": + mm := VcnDrgAttachmentNetworkUpdateDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +func (m drgattachmentnetworkupdatedetails) String() string { + return common.PointerString(m) +} + +// DrgAttachmentNetworkUpdateDetailsTypeEnum Enum with underlying type: string +type DrgAttachmentNetworkUpdateDetailsTypeEnum string + +// Set of constants representing the allowable values for DrgAttachmentNetworkUpdateDetailsTypeEnum +const ( + DrgAttachmentNetworkUpdateDetailsTypeVcn DrgAttachmentNetworkUpdateDetailsTypeEnum = "VCN" +) + +var mappingDrgAttachmentNetworkUpdateDetailsType = map[string]DrgAttachmentNetworkUpdateDetailsTypeEnum{ + "VCN": DrgAttachmentNetworkUpdateDetailsTypeVcn, +} + +// GetDrgAttachmentNetworkUpdateDetailsTypeEnumValues Enumerates the set of values for DrgAttachmentNetworkUpdateDetailsTypeEnum +func GetDrgAttachmentNetworkUpdateDetailsTypeEnumValues() []DrgAttachmentNetworkUpdateDetailsTypeEnum { + values := make([]DrgAttachmentNetworkUpdateDetailsTypeEnum, 0) + for _, v := range mappingDrgAttachmentNetworkUpdateDetailsType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_type_drg_route_distribution_match_criteria.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_type_drg_route_distribution_match_criteria.go new file mode 100644 index 000000000..8ed68b298 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_attachment_type_drg_route_distribution_match_criteria.go @@ -0,0 +1,73 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DrgAttachmentTypeDrgRouteDistributionMatchCriteria The attachment type from which the DRG will import routes. Routes will be imported from +// all attachments of this type. +type DrgAttachmentTypeDrgRouteDistributionMatchCriteria struct { + + // The type of the network resource to be included in this match. A match for a network type implies that all + // DRG attachments of that type insert routes into the table. + AttachmentType DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeEnum `mandatory:"true" json:"attachmentType"` +} + +func (m DrgAttachmentTypeDrgRouteDistributionMatchCriteria) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m DrgAttachmentTypeDrgRouteDistributionMatchCriteria) MarshalJSON() (buff []byte, e error) { + type MarshalTypeDrgAttachmentTypeDrgRouteDistributionMatchCriteria DrgAttachmentTypeDrgRouteDistributionMatchCriteria + s := struct { + DiscriminatorParam string `json:"matchType"` + MarshalTypeDrgAttachmentTypeDrgRouteDistributionMatchCriteria + }{ + "DRG_ATTACHMENT_TYPE", + (MarshalTypeDrgAttachmentTypeDrgRouteDistributionMatchCriteria)(m), + } + + return json.Marshal(&s) +} + +// DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeEnum Enum with underlying type: string +type DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeEnum string + +// Set of constants representing the allowable values for DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeEnum +const ( + DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeVcn DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeEnum = "VCN" + DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeVirtualCircuit DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeEnum = "VIRTUAL_CIRCUIT" + DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeRemotePeeringConnection DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeEnum = "REMOTE_PEERING_CONNECTION" + DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeIpsecTunnel DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeEnum = "IPSEC_TUNNEL" +) + +var mappingDrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentType = map[string]DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeEnum{ + "VCN": DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeVcn, + "VIRTUAL_CIRCUIT": DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeVirtualCircuit, + "REMOTE_PEERING_CONNECTION": DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeRemotePeeringConnection, + "IPSEC_TUNNEL": DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeIpsecTunnel, +} + +// GetDrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeEnumValues Enumerates the set of values for DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeEnum +func GetDrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeEnumValues() []DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeEnum { + values := make([]DrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentTypeEnum, 0) + for _, v := range mappingDrgAttachmentTypeDrgRouteDistributionMatchCriteriaAttachmentType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_redundancy_status.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_redundancy_status.go new file mode 100644 index 000000000..c3836b728 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_redundancy_status.go @@ -0,0 +1,68 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DrgRedundancyStatus The redundancy status of the DRG. For more information, see +// Redundancy Remedies (https://docs.cloud.oracle.com/iaas/Content/Network/Troubleshoot/drgredundancy.htm). +type DrgRedundancyStatus struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the DRG. + Id *string `mandatory:"false" json:"id"` + + // The redundancy status of the DRG. + Status DrgRedundancyStatusStatusEnum `mandatory:"false" json:"status,omitempty"` +} + +func (m DrgRedundancyStatus) String() string { + return common.PointerString(m) +} + +// DrgRedundancyStatusStatusEnum Enum with underlying type: string +type DrgRedundancyStatusStatusEnum string + +// Set of constants representing the allowable values for DrgRedundancyStatusStatusEnum +const ( + DrgRedundancyStatusStatusNotAvailable DrgRedundancyStatusStatusEnum = "NOT_AVAILABLE" + DrgRedundancyStatusStatusRedundant DrgRedundancyStatusStatusEnum = "REDUNDANT" + DrgRedundancyStatusStatusNotRedundantSingleIpsec DrgRedundancyStatusStatusEnum = "NOT_REDUNDANT_SINGLE_IPSEC" + DrgRedundancyStatusStatusNotRedundantSingleVirtualcircuit DrgRedundancyStatusStatusEnum = "NOT_REDUNDANT_SINGLE_VIRTUALCIRCUIT" + DrgRedundancyStatusStatusNotRedundantMultipleIpsecs DrgRedundancyStatusStatusEnum = "NOT_REDUNDANT_MULTIPLE_IPSECS" + DrgRedundancyStatusStatusNotRedundantMultipleVirtualcircuits DrgRedundancyStatusStatusEnum = "NOT_REDUNDANT_MULTIPLE_VIRTUALCIRCUITS" + DrgRedundancyStatusStatusNotRedundantMixConnections DrgRedundancyStatusStatusEnum = "NOT_REDUNDANT_MIX_CONNECTIONS" + DrgRedundancyStatusStatusNotRedundantNoConnection DrgRedundancyStatusStatusEnum = "NOT_REDUNDANT_NO_CONNECTION" +) + +var mappingDrgRedundancyStatusStatus = map[string]DrgRedundancyStatusStatusEnum{ + "NOT_AVAILABLE": DrgRedundancyStatusStatusNotAvailable, + "REDUNDANT": DrgRedundancyStatusStatusRedundant, + "NOT_REDUNDANT_SINGLE_IPSEC": DrgRedundancyStatusStatusNotRedundantSingleIpsec, + "NOT_REDUNDANT_SINGLE_VIRTUALCIRCUIT": DrgRedundancyStatusStatusNotRedundantSingleVirtualcircuit, + "NOT_REDUNDANT_MULTIPLE_IPSECS": DrgRedundancyStatusStatusNotRedundantMultipleIpsecs, + "NOT_REDUNDANT_MULTIPLE_VIRTUALCIRCUITS": DrgRedundancyStatusStatusNotRedundantMultipleVirtualcircuits, + "NOT_REDUNDANT_MIX_CONNECTIONS": DrgRedundancyStatusStatusNotRedundantMixConnections, + "NOT_REDUNDANT_NO_CONNECTION": DrgRedundancyStatusStatusNotRedundantNoConnection, +} + +// GetDrgRedundancyStatusStatusEnumValues Enumerates the set of values for DrgRedundancyStatusStatusEnum +func GetDrgRedundancyStatusStatusEnumValues() []DrgRedundancyStatusStatusEnum { + values := make([]DrgRedundancyStatusStatusEnum, 0) + for _, v := range mappingDrgRedundancyStatusStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_distribution.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_distribution.go new file mode 100644 index 000000000..386846bc2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_distribution.go @@ -0,0 +1,121 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DrgRouteDistribution A route distribution establishes how routes get imported into DRG route tables and exported through the DRG attachments. +// A route distribution is a list of statements. Each statement consists of a set of matches, all of which must be `True` in order for +// the statement's action to take place. Each statement determines which routes are propagated. +// You can assign a route distribution as a route table's import distribution. The statements in an import +// route distribution specify how how incoming route advertisements through a referenced attachment or all attachments of a certain type are inserted into the route table. +// You can assign a route distribution as a DRG attachment's export distribution. Export route distribution statements specify how routes in a +// DRG attachment's assigned table are advertised out through the attachment. When a DRG attachment is created, a route distribution is created with a +// single ACCEPT statement with an empty match criteria (empty match criteria implies match ALL). +// Exporting routes through VCN attachments is unsupported, so no VCN attachments are assigned an export distribution. +// The two auto-generated DRG route tables (one as the default for VCN attachments, and the other for all other types of attachments) +// are each assigned an auto generated import route distribution. The default VCN table's import distribution has a single statement with empty match criteria statement to import routes from +// each DRG attachment type. The other table's import distribution has a statement to import routes from attachments with the VCN type. +// The route distribution is always in the same compartment as the DRG. +type DrgRouteDistribution struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG that contains this route distribution. + DrgId *string `mandatory:"true" json:"drgId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the route distribution. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The route distribution's Oracle ID (OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"true" json:"id"` + + // The route distribution's current state. + LifecycleState DrgRouteDistributionLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the route distribution was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // Whether this distribution defines how routes get imported into route tables or exported through DRG attachments. + DistributionType DrgRouteDistributionDistributionTypeEnum `mandatory:"true" json:"distributionType"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m DrgRouteDistribution) String() string { + return common.PointerString(m) +} + +// DrgRouteDistributionLifecycleStateEnum Enum with underlying type: string +type DrgRouteDistributionLifecycleStateEnum string + +// Set of constants representing the allowable values for DrgRouteDistributionLifecycleStateEnum +const ( + DrgRouteDistributionLifecycleStateProvisioning DrgRouteDistributionLifecycleStateEnum = "PROVISIONING" + DrgRouteDistributionLifecycleStateAvailable DrgRouteDistributionLifecycleStateEnum = "AVAILABLE" + DrgRouteDistributionLifecycleStateTerminating DrgRouteDistributionLifecycleStateEnum = "TERMINATING" + DrgRouteDistributionLifecycleStateTerminated DrgRouteDistributionLifecycleStateEnum = "TERMINATED" +) + +var mappingDrgRouteDistributionLifecycleState = map[string]DrgRouteDistributionLifecycleStateEnum{ + "PROVISIONING": DrgRouteDistributionLifecycleStateProvisioning, + "AVAILABLE": DrgRouteDistributionLifecycleStateAvailable, + "TERMINATING": DrgRouteDistributionLifecycleStateTerminating, + "TERMINATED": DrgRouteDistributionLifecycleStateTerminated, +} + +// GetDrgRouteDistributionLifecycleStateEnumValues Enumerates the set of values for DrgRouteDistributionLifecycleStateEnum +func GetDrgRouteDistributionLifecycleStateEnumValues() []DrgRouteDistributionLifecycleStateEnum { + values := make([]DrgRouteDistributionLifecycleStateEnum, 0) + for _, v := range mappingDrgRouteDistributionLifecycleState { + values = append(values, v) + } + return values +} + +// DrgRouteDistributionDistributionTypeEnum Enum with underlying type: string +type DrgRouteDistributionDistributionTypeEnum string + +// Set of constants representing the allowable values for DrgRouteDistributionDistributionTypeEnum +const ( + DrgRouteDistributionDistributionTypeImport DrgRouteDistributionDistributionTypeEnum = "IMPORT" + DrgRouteDistributionDistributionTypeExport DrgRouteDistributionDistributionTypeEnum = "EXPORT" +) + +var mappingDrgRouteDistributionDistributionType = map[string]DrgRouteDistributionDistributionTypeEnum{ + "IMPORT": DrgRouteDistributionDistributionTypeImport, + "EXPORT": DrgRouteDistributionDistributionTypeExport, +} + +// GetDrgRouteDistributionDistributionTypeEnumValues Enumerates the set of values for DrgRouteDistributionDistributionTypeEnum +func GetDrgRouteDistributionDistributionTypeEnumValues() []DrgRouteDistributionDistributionTypeEnum { + values := make([]DrgRouteDistributionDistributionTypeEnum, 0) + for _, v := range mappingDrgRouteDistributionDistributionType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_distribution_match_criteria.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_distribution_match_criteria.go new file mode 100644 index 000000000..2fa6c819e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_distribution_match_criteria.go @@ -0,0 +1,94 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DrgRouteDistributionMatchCriteria The match criteria in a route distribution statement. The match criteria outlines which routes +// should be imported or exported. Leaving the match criteria empty implies match ALL. +type DrgRouteDistributionMatchCriteria interface { +} + +type drgroutedistributionmatchcriteria struct { + JsonData []byte + MatchType string `json:"matchType"` +} + +// UnmarshalJSON unmarshals json +func (m *drgroutedistributionmatchcriteria) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerdrgroutedistributionmatchcriteria drgroutedistributionmatchcriteria + s := struct { + Model Unmarshalerdrgroutedistributionmatchcriteria + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.MatchType = s.Model.MatchType + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *drgroutedistributionmatchcriteria) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.MatchType { + case "DRG_ATTACHMENT_ID": + mm := DrgAttachmentIdDrgRouteDistributionMatchCriteria{} + err = json.Unmarshal(data, &mm) + return mm, err + case "DRG_ATTACHMENT_TYPE": + mm := DrgAttachmentTypeDrgRouteDistributionMatchCriteria{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +func (m drgroutedistributionmatchcriteria) String() string { + return common.PointerString(m) +} + +// DrgRouteDistributionMatchCriteriaMatchTypeEnum Enum with underlying type: string +type DrgRouteDistributionMatchCriteriaMatchTypeEnum string + +// Set of constants representing the allowable values for DrgRouteDistributionMatchCriteriaMatchTypeEnum +const ( + DrgRouteDistributionMatchCriteriaMatchTypeType DrgRouteDistributionMatchCriteriaMatchTypeEnum = "DRG_ATTACHMENT_TYPE" + DrgRouteDistributionMatchCriteriaMatchTypeId DrgRouteDistributionMatchCriteriaMatchTypeEnum = "DRG_ATTACHMENT_ID" +) + +var mappingDrgRouteDistributionMatchCriteriaMatchType = map[string]DrgRouteDistributionMatchCriteriaMatchTypeEnum{ + "DRG_ATTACHMENT_TYPE": DrgRouteDistributionMatchCriteriaMatchTypeType, + "DRG_ATTACHMENT_ID": DrgRouteDistributionMatchCriteriaMatchTypeId, +} + +// GetDrgRouteDistributionMatchCriteriaMatchTypeEnumValues Enumerates the set of values for DrgRouteDistributionMatchCriteriaMatchTypeEnum +func GetDrgRouteDistributionMatchCriteriaMatchTypeEnumValues() []DrgRouteDistributionMatchCriteriaMatchTypeEnum { + values := make([]DrgRouteDistributionMatchCriteriaMatchTypeEnum, 0) + for _, v := range mappingDrgRouteDistributionMatchCriteriaMatchType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_distribution_statement.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_distribution_statement.go new file mode 100644 index 000000000..4e98872bd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_distribution_statement.go @@ -0,0 +1,103 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DrgRouteDistributionStatement A single statement within a route distribution. All match criteria in a statement must be met +// for the action to take place. +type DrgRouteDistributionStatement struct { + + // The action is applied only if all of the match criteria is met. + // If there are no match criteria in a statement, any input is considered a match and the action is applied. + MatchCriteria []DrgRouteDistributionMatchCriteria `mandatory:"true" json:"matchCriteria"` + + // `ACCEPT` indicates the route should be imported or exported as-is. + Action DrgRouteDistributionStatementActionEnum `mandatory:"true" json:"action"` + + // This field specifies the priority of each statement in a route distribution. + // Priorities must be unique within a particular route distribution. + // The priority will be represented as a number between 0 and 65535 where a lower number + // indicates a higher priority. When a route is processed, statements are applied in the order + // defined by their priority. The first matching rule dictates the action that will be taken + // on the route. + Priority *int `mandatory:"true" json:"priority"` + + // The Oracle-assigned ID of the route distribution statement. + Id *string `mandatory:"true" json:"id"` +} + +func (m DrgRouteDistributionStatement) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *DrgRouteDistributionStatement) UnmarshalJSON(data []byte) (e error) { + model := struct { + MatchCriteria []drgroutedistributionmatchcriteria `json:"matchCriteria"` + Action DrgRouteDistributionStatementActionEnum `json:"action"` + Priority *int `json:"priority"` + Id *string `json:"id"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.MatchCriteria = make([]DrgRouteDistributionMatchCriteria, len(model.MatchCriteria)) + for i, n := range model.MatchCriteria { + nn, e = n.UnmarshalPolymorphicJSON(n.JsonData) + if e != nil { + return e + } + if nn != nil { + m.MatchCriteria[i] = nn.(DrgRouteDistributionMatchCriteria) + } else { + m.MatchCriteria[i] = nil + } + } + + m.Action = model.Action + + m.Priority = model.Priority + + m.Id = model.Id + + return +} + +// DrgRouteDistributionStatementActionEnum Enum with underlying type: string +type DrgRouteDistributionStatementActionEnum string + +// Set of constants representing the allowable values for DrgRouteDistributionStatementActionEnum +const ( + DrgRouteDistributionStatementActionAccept DrgRouteDistributionStatementActionEnum = "ACCEPT" +) + +var mappingDrgRouteDistributionStatementAction = map[string]DrgRouteDistributionStatementActionEnum{ + "ACCEPT": DrgRouteDistributionStatementActionAccept, +} + +// GetDrgRouteDistributionStatementActionEnumValues Enumerates the set of values for DrgRouteDistributionStatementActionEnum +func GetDrgRouteDistributionStatementActionEnumValues() []DrgRouteDistributionStatementActionEnum { + values := make([]DrgRouteDistributionStatementActionEnum, 0) + for _, v := range mappingDrgRouteDistributionStatementAction { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_rule.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_rule.go new file mode 100644 index 000000000..445096f54 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_rule.go @@ -0,0 +1,145 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DrgRouteRule A DRG route rule is a mapping between a destination IP address range and a DRG attachment. +// The map is used to route matching packets. Traffic will be routed across the attachments using Equal-cost multi-path routing (ECMP) +// if there are multiple rules with identical destinations and none of the rules conflict. +type DrgRouteRule struct { + + // Represents the range of IP addresses to match against when routing traffic. + // Potential values: + // * An IP address range (IPv4 or IPv6) in CIDR notation. For example: `192.168.1.0/24` + // or `2001:0db8:0123:45::/56`. + // * When you're setting up a security rule for traffic destined for a particular `Service` through + // a service gateway, this is the `cidrBlock` value associated with that Service. For example: `oci-phx-objectstorage`. + Destination *string `mandatory:"true" json:"destination"` + + // The type of destination for the rule. the type is required if `direction` = `EGRESS`. + // Allowed values: + // * `CIDR_BLOCK`: If the rule's `destination` is an IP address range in CIDR notation. + // * `SERVICE_CIDR_BLOCK`: If the rule's `destination` is the `cidrBlock` value for a + // Service (the rule is for traffic destined for a + // particular `Service` through a service gateway). + DestinationType DrgRouteRuleDestinationTypeEnum `mandatory:"true" json:"destinationType"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the next hop DRG attachment responsible + // for reaching the network destination. + // A value of `BLACKHOLE` means traffic for this route is discarded without notification. + NextHopDrgAttachmentId *string `mandatory:"true" json:"nextHopDrgAttachmentId"` + + // The Oracle-assigned ID of the DRG route rule. + Id *string `mandatory:"true" json:"id"` + + // The earliest origin of a route. If a route is advertised to a DRG through an IPsec tunnel attachment, + // and is propagated to peered DRGs via RPC attachments, the route's provenance in the peered DRGs remains `IPSEC_TUNNEL`, + // because that is the earliest origin. + // No routes with a provenance `IPSEC_TUNNEL` or `VIRTUAL_CIRCUIT` will be exported to IPsec tunnel or virtual circuit attachments, + // regardless of the attachment's export distribution. + RouteProvenance DrgRouteRuleRouteProvenanceEnum `mandatory:"true" json:"routeProvenance"` + + // You can specify static routes for the DRG route table using the API. + // The DRG learns dynamic routes from the DRG attachments using various routing protocols. + RouteType DrgRouteRuleRouteTypeEnum `mandatory:"false" json:"routeType,omitempty"` + + // Indicates that the route was not imported due to a conflict between route rules. + IsConflict *bool `mandatory:"false" json:"isConflict"` + + // Indicates that if the next hop attachment does not exist, so traffic for this route is discarded without notification. + IsBlackhole *bool `mandatory:"false" json:"isBlackhole"` + + // Additional properties for the route, computed by the service. + Attributes *interface{} `mandatory:"false" json:"attributes"` +} + +func (m DrgRouteRule) String() string { + return common.PointerString(m) +} + +// DrgRouteRuleDestinationTypeEnum Enum with underlying type: string +type DrgRouteRuleDestinationTypeEnum string + +// Set of constants representing the allowable values for DrgRouteRuleDestinationTypeEnum +const ( + DrgRouteRuleDestinationTypeCidrBlock DrgRouteRuleDestinationTypeEnum = "CIDR_BLOCK" + DrgRouteRuleDestinationTypeServiceCidrBlock DrgRouteRuleDestinationTypeEnum = "SERVICE_CIDR_BLOCK" +) + +var mappingDrgRouteRuleDestinationType = map[string]DrgRouteRuleDestinationTypeEnum{ + "CIDR_BLOCK": DrgRouteRuleDestinationTypeCidrBlock, + "SERVICE_CIDR_BLOCK": DrgRouteRuleDestinationTypeServiceCidrBlock, +} + +// GetDrgRouteRuleDestinationTypeEnumValues Enumerates the set of values for DrgRouteRuleDestinationTypeEnum +func GetDrgRouteRuleDestinationTypeEnumValues() []DrgRouteRuleDestinationTypeEnum { + values := make([]DrgRouteRuleDestinationTypeEnum, 0) + for _, v := range mappingDrgRouteRuleDestinationType { + values = append(values, v) + } + return values +} + +// DrgRouteRuleRouteTypeEnum Enum with underlying type: string +type DrgRouteRuleRouteTypeEnum string + +// Set of constants representing the allowable values for DrgRouteRuleRouteTypeEnum +const ( + DrgRouteRuleRouteTypeStatic DrgRouteRuleRouteTypeEnum = "STATIC" + DrgRouteRuleRouteTypeDynamic DrgRouteRuleRouteTypeEnum = "DYNAMIC" +) + +var mappingDrgRouteRuleRouteType = map[string]DrgRouteRuleRouteTypeEnum{ + "STATIC": DrgRouteRuleRouteTypeStatic, + "DYNAMIC": DrgRouteRuleRouteTypeDynamic, +} + +// GetDrgRouteRuleRouteTypeEnumValues Enumerates the set of values for DrgRouteRuleRouteTypeEnum +func GetDrgRouteRuleRouteTypeEnumValues() []DrgRouteRuleRouteTypeEnum { + values := make([]DrgRouteRuleRouteTypeEnum, 0) + for _, v := range mappingDrgRouteRuleRouteType { + values = append(values, v) + } + return values +} + +// DrgRouteRuleRouteProvenanceEnum Enum with underlying type: string +type DrgRouteRuleRouteProvenanceEnum string + +// Set of constants representing the allowable values for DrgRouteRuleRouteProvenanceEnum +const ( + DrgRouteRuleRouteProvenanceStatic DrgRouteRuleRouteProvenanceEnum = "STATIC" + DrgRouteRuleRouteProvenanceVcn DrgRouteRuleRouteProvenanceEnum = "VCN" + DrgRouteRuleRouteProvenanceVirtualCircuit DrgRouteRuleRouteProvenanceEnum = "VIRTUAL_CIRCUIT" + DrgRouteRuleRouteProvenanceIpsecTunnel DrgRouteRuleRouteProvenanceEnum = "IPSEC_TUNNEL" +) + +var mappingDrgRouteRuleRouteProvenance = map[string]DrgRouteRuleRouteProvenanceEnum{ + "STATIC": DrgRouteRuleRouteProvenanceStatic, + "VCN": DrgRouteRuleRouteProvenanceVcn, + "VIRTUAL_CIRCUIT": DrgRouteRuleRouteProvenanceVirtualCircuit, + "IPSEC_TUNNEL": DrgRouteRuleRouteProvenanceIpsecTunnel, +} + +// GetDrgRouteRuleRouteProvenanceEnumValues Enumerates the set of values for DrgRouteRuleRouteProvenanceEnum +func GetDrgRouteRuleRouteProvenanceEnumValues() []DrgRouteRuleRouteProvenanceEnum { + values := make([]DrgRouteRuleRouteProvenanceEnum, 0) + for _, v := range mappingDrgRouteRuleRouteProvenance { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_table.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_table.go new file mode 100644 index 000000000..a2fa22676 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/drg_route_table.go @@ -0,0 +1,102 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DrgRouteTable All routing inside the DRG is driven by the contents of DRG route tables. +// DRG route tables contain rules which route packets to a particular network destination, +// represented as a DRG attachment. +// The routing decision for a packet entering a DRG is determined by the rules in the DRG route table +// assigned to the attachment-of-entry. +// Each DRG attachment can inject routes in any DRG route table, provided there is a statement corresponding to the attachment in the route table's `importDrgRouteDistribution`. +// You can also insert static routes into the DRG route tables. +// The DRG route table is always in the same compartment as the DRG. There must always be a default +// DRG route table for each attachment type. +type DrgRouteTable struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the + // DRG route table. + Id *string `mandatory:"true" json:"id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the compartment the DRG is in. The DRG route table + // is always in the same compartment as the DRG. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the DRG the DRG that contains this route table. + DrgId *string `mandatory:"true" json:"drgId"` + + // The date and time the DRG route table was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The DRG route table's current state. + LifecycleState DrgRouteTableLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // If you want traffic to be routed using ECMP across your virtual circuits or IPSec tunnels to + // your on-premises network, enable ECMP on the DRG route table to which these attachments + // import routes. + IsEcmpEnabled *bool `mandatory:"true" json:"isEcmpEnabled"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the import route distribution used to specify how incoming route advertisements from + // referenced attachments are inserted into the DRG route table. + ImportDrgRouteDistributionId *string `mandatory:"false" json:"importDrgRouteDistributionId"` +} + +func (m DrgRouteTable) String() string { + return common.PointerString(m) +} + +// DrgRouteTableLifecycleStateEnum Enum with underlying type: string +type DrgRouteTableLifecycleStateEnum string + +// Set of constants representing the allowable values for DrgRouteTableLifecycleStateEnum +const ( + DrgRouteTableLifecycleStateProvisioning DrgRouteTableLifecycleStateEnum = "PROVISIONING" + DrgRouteTableLifecycleStateAvailable DrgRouteTableLifecycleStateEnum = "AVAILABLE" + DrgRouteTableLifecycleStateTerminating DrgRouteTableLifecycleStateEnum = "TERMINATING" + DrgRouteTableLifecycleStateTerminated DrgRouteTableLifecycleStateEnum = "TERMINATED" +) + +var mappingDrgRouteTableLifecycleState = map[string]DrgRouteTableLifecycleStateEnum{ + "PROVISIONING": DrgRouteTableLifecycleStateProvisioning, + "AVAILABLE": DrgRouteTableLifecycleStateAvailable, + "TERMINATING": DrgRouteTableLifecycleStateTerminating, + "TERMINATED": DrgRouteTableLifecycleStateTerminated, +} + +// GetDrgRouteTableLifecycleStateEnumValues Enumerates the set of values for DrgRouteTableLifecycleStateEnum +func GetDrgRouteTableLifecycleStateEnumValues() []DrgRouteTableLifecycleStateEnum { + values := make([]DrgRouteTableLifecycleStateEnum, 0) + for _, v := range mappingDrgRouteTableLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/egress_security_rule.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/egress_security_rule.go new file mode 100644 index 000000000..8bffaa781 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/egress_security_rule.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// EgressSecurityRule A rule for allowing outbound IP packets. +type EgressSecurityRule struct { + + // Conceptually, this is the range of IP addresses that a packet originating from the instance + // can go to. + // Allowed values: + // * IP address range in CIDR notation. For example: `192.168.1.0/24` or `2001:0db8:0123:45::/56` + // Note that IPv6 addressing is currently supported only in certain regions. See + // IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // * The `cidrBlock` value for a Service, if you're + // setting up a security list rule for traffic destined for a particular `Service` through + // a service gateway. For example: `oci-phx-objectstorage`. + Destination *string `mandatory:"true" json:"destination"` + + // The transport protocol. Specify either `all` or an IPv4 protocol number as + // defined in + // Protocol Numbers (http://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml). + // Options are supported only for ICMP ("1"), TCP ("6"), UDP ("17"), and ICMPv6 ("58"). + Protocol *string `mandatory:"true" json:"protocol"` + + // Type of destination for the rule. The default is `CIDR_BLOCK`. + // Allowed values: + // * `CIDR_BLOCK`: If the rule's `destination` is an IP address range in CIDR notation. + // * `SERVICE_CIDR_BLOCK`: If the rule's `destination` is the `cidrBlock` value for a + // Service (the rule is for traffic destined for a + // particular `Service` through a service gateway). + DestinationType EgressSecurityRuleDestinationTypeEnum `mandatory:"false" json:"destinationType,omitempty"` + + IcmpOptions *IcmpOptions `mandatory:"false" json:"icmpOptions"` + + // A stateless rule allows traffic in one direction. Remember to add a corresponding + // stateless rule in the other direction if you need to support bidirectional traffic. For + // example, if egress traffic allows TCP destination port 80, there should be an ingress + // rule to allow TCP source port 80. Defaults to false, which means the rule is stateful + // and a corresponding rule is not necessary for bidirectional traffic. + IsStateless *bool `mandatory:"false" json:"isStateless"` + + TcpOptions *TcpOptions `mandatory:"false" json:"tcpOptions"` + + UdpOptions *UdpOptions `mandatory:"false" json:"udpOptions"` + + // An optional description of your choice for the rule. + Description *string `mandatory:"false" json:"description"` +} + +func (m EgressSecurityRule) String() string { + return common.PointerString(m) +} + +// EgressSecurityRuleDestinationTypeEnum Enum with underlying type: string +type EgressSecurityRuleDestinationTypeEnum string + +// Set of constants representing the allowable values for EgressSecurityRuleDestinationTypeEnum +const ( + EgressSecurityRuleDestinationTypeCidrBlock EgressSecurityRuleDestinationTypeEnum = "CIDR_BLOCK" + EgressSecurityRuleDestinationTypeServiceCidrBlock EgressSecurityRuleDestinationTypeEnum = "SERVICE_CIDR_BLOCK" +) + +var mappingEgressSecurityRuleDestinationType = map[string]EgressSecurityRuleDestinationTypeEnum{ + "CIDR_BLOCK": EgressSecurityRuleDestinationTypeCidrBlock, + "SERVICE_CIDR_BLOCK": EgressSecurityRuleDestinationTypeServiceCidrBlock, +} + +// GetEgressSecurityRuleDestinationTypeEnumValues Enumerates the set of values for EgressSecurityRuleDestinationTypeEnum +func GetEgressSecurityRuleDestinationTypeEnumValues() []EgressSecurityRuleDestinationTypeEnum { + values := make([]EgressSecurityRuleDestinationTypeEnum, 0) + for _, v := range mappingEgressSecurityRuleDestinationType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/emulated_volume_attachment.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/emulated_volume_attachment.go new file mode 100644 index 000000000..519cde61b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/emulated_volume_attachment.go @@ -0,0 +1,160 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// EmulatedVolumeAttachment An Emulated volume attachment. +type EmulatedVolumeAttachment struct { + + // The availability domain of an instance. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the volume attachment. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the instance the volume is attached to. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // The date and time the volume was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID of the volume. + VolumeId *string `mandatory:"true" json:"volumeId"` + + // The device name. + Device *string `mandatory:"false" json:"device"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Whether the attachment was created in read-only mode. + IsReadOnly *bool `mandatory:"false" json:"isReadOnly"` + + // Whether the attachment should be created in shareable mode. If an attachment + // is created in shareable mode, then other instances can attach the same volume, provided + // that they also create their attachments in shareable mode. Only certain volume types can + // be attached in shareable mode. Defaults to false if not specified. + IsShareable *bool `mandatory:"false" json:"isShareable"` + + // Whether in-transit encryption for the data volume's paravirtualized attachment is enabled or not. + IsPvEncryptionInTransitEnabled *bool `mandatory:"false" json:"isPvEncryptionInTransitEnabled"` + + // Whether the attachment is multipath or not. + IsMultipath *bool `mandatory:"false" json:"isMultipath"` + + // The current state of the volume attachment. + LifecycleState VolumeAttachmentLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The iscsi login state of the volume attachment. For a multipath volume attachment, + // all iscsi sessions need to be all logged-in or logged-out to be in logged-in or logged-out state. + IscsiLoginState VolumeAttachmentIscsiLoginStateEnum `mandatory:"false" json:"iscsiLoginState,omitempty"` +} + +//GetAvailabilityDomain returns AvailabilityDomain +func (m EmulatedVolumeAttachment) GetAvailabilityDomain() *string { + return m.AvailabilityDomain +} + +//GetCompartmentId returns CompartmentId +func (m EmulatedVolumeAttachment) GetCompartmentId() *string { + return m.CompartmentId +} + +//GetDevice returns Device +func (m EmulatedVolumeAttachment) GetDevice() *string { + return m.Device +} + +//GetDisplayName returns DisplayName +func (m EmulatedVolumeAttachment) GetDisplayName() *string { + return m.DisplayName +} + +//GetId returns Id +func (m EmulatedVolumeAttachment) GetId() *string { + return m.Id +} + +//GetInstanceId returns InstanceId +func (m EmulatedVolumeAttachment) GetInstanceId() *string { + return m.InstanceId +} + +//GetIsReadOnly returns IsReadOnly +func (m EmulatedVolumeAttachment) GetIsReadOnly() *bool { + return m.IsReadOnly +} + +//GetIsShareable returns IsShareable +func (m EmulatedVolumeAttachment) GetIsShareable() *bool { + return m.IsShareable +} + +//GetLifecycleState returns LifecycleState +func (m EmulatedVolumeAttachment) GetLifecycleState() VolumeAttachmentLifecycleStateEnum { + return m.LifecycleState +} + +//GetTimeCreated returns TimeCreated +func (m EmulatedVolumeAttachment) GetTimeCreated() *common.SDKTime { + return m.TimeCreated +} + +//GetVolumeId returns VolumeId +func (m EmulatedVolumeAttachment) GetVolumeId() *string { + return m.VolumeId +} + +//GetIsPvEncryptionInTransitEnabled returns IsPvEncryptionInTransitEnabled +func (m EmulatedVolumeAttachment) GetIsPvEncryptionInTransitEnabled() *bool { + return m.IsPvEncryptionInTransitEnabled +} + +//GetIsMultipath returns IsMultipath +func (m EmulatedVolumeAttachment) GetIsMultipath() *bool { + return m.IsMultipath +} + +//GetIscsiLoginState returns IscsiLoginState +func (m EmulatedVolumeAttachment) GetIscsiLoginState() VolumeAttachmentIscsiLoginStateEnum { + return m.IscsiLoginState +} + +func (m EmulatedVolumeAttachment) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m EmulatedVolumeAttachment) MarshalJSON() (buff []byte, e error) { + type MarshalTypeEmulatedVolumeAttachment EmulatedVolumeAttachment + s := struct { + DiscriminatorParam string `json:"attachmentType"` + MarshalTypeEmulatedVolumeAttachment + }{ + "emulated", + (MarshalTypeEmulatedVolumeAttachment)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/encryption_domain_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/encryption_domain_config.go new file mode 100644 index 000000000..6aeae532a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/encryption_domain_config.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// EncryptionDomainConfig Configuration information used by the encryption domain policy. +type EncryptionDomainConfig struct { + + // Lists IPv4 or IPv6-enabled subnets in your Oracle tenancy. + OracleTrafficSelector []string `mandatory:"false" json:"oracleTrafficSelector"` + + // Lists IPv4 or IPv6-enabled subnets in your on-premises network. + CpeTrafficSelector []string `mandatory:"false" json:"cpeTrafficSelector"` +} + +func (m EncryptionDomainConfig) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/encryption_in_transit_type.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/encryption_in_transit_type.go new file mode 100644 index 000000000..65689aa2f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/encryption_in_transit_type.go @@ -0,0 +1,37 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +// EncryptionInTransitTypeEnum Enum with underlying type: string +type EncryptionInTransitTypeEnum string + +// Set of constants representing the allowable values for EncryptionInTransitTypeEnum +const ( + EncryptionInTransitTypeNone EncryptionInTransitTypeEnum = "NONE" + EncryptionInTransitTypeBmEncryptionInTransit EncryptionInTransitTypeEnum = "BM_ENCRYPTION_IN_TRANSIT" +) + +var mappingEncryptionInTransitType = map[string]EncryptionInTransitTypeEnum{ + "NONE": EncryptionInTransitTypeNone, + "BM_ENCRYPTION_IN_TRANSIT": EncryptionInTransitTypeBmEncryptionInTransit, +} + +// GetEncryptionInTransitTypeEnumValues Enumerates the set of values for EncryptionInTransitTypeEnum +func GetEncryptionInTransitTypeEnumValues() []EncryptionInTransitTypeEnum { + values := make([]EncryptionInTransitTypeEnum, 0) + for _, v := range mappingEncryptionInTransitType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/enum_integer_image_capability_descriptor.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/enum_integer_image_capability_descriptor.go new file mode 100644 index 000000000..a7ca778da --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/enum_integer_image_capability_descriptor.go @@ -0,0 +1,54 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// EnumIntegerImageCapabilityDescriptor Enum Integer type CapabilityDescriptor +type EnumIntegerImageCapabilityDescriptor struct { + + // the list of values for the enum + Values []int `mandatory:"true" json:"values"` + + // the default value + DefaultValue *int `mandatory:"false" json:"defaultValue"` + + Source ImageCapabilitySchemaDescriptorSourceEnum `mandatory:"true" json:"source"` +} + +//GetSource returns Source +func (m EnumIntegerImageCapabilityDescriptor) GetSource() ImageCapabilitySchemaDescriptorSourceEnum { + return m.Source +} + +func (m EnumIntegerImageCapabilityDescriptor) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m EnumIntegerImageCapabilityDescriptor) MarshalJSON() (buff []byte, e error) { + type MarshalTypeEnumIntegerImageCapabilityDescriptor EnumIntegerImageCapabilityDescriptor + s := struct { + DiscriminatorParam string `json:"descriptorType"` + MarshalTypeEnumIntegerImageCapabilityDescriptor + }{ + "enuminteger", + (MarshalTypeEnumIntegerImageCapabilityDescriptor)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/enum_string_image_capability_schema_descriptor.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/enum_string_image_capability_schema_descriptor.go new file mode 100644 index 000000000..236b9c594 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/enum_string_image_capability_schema_descriptor.go @@ -0,0 +1,54 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// EnumStringImageCapabilitySchemaDescriptor Enum String type of ImageCapabilitySchemaDescriptor +type EnumStringImageCapabilitySchemaDescriptor struct { + + // the list of values for the enum + Values []string `mandatory:"true" json:"values"` + + // the default value + DefaultValue *string `mandatory:"false" json:"defaultValue"` + + Source ImageCapabilitySchemaDescriptorSourceEnum `mandatory:"true" json:"source"` +} + +//GetSource returns Source +func (m EnumStringImageCapabilitySchemaDescriptor) GetSource() ImageCapabilitySchemaDescriptorSourceEnum { + return m.Source +} + +func (m EnumStringImageCapabilitySchemaDescriptor) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m EnumStringImageCapabilitySchemaDescriptor) MarshalJSON() (buff []byte, e error) { + type MarshalTypeEnumStringImageCapabilitySchemaDescriptor EnumStringImageCapabilitySchemaDescriptor + s := struct { + DiscriminatorParam string `json:"descriptorType"` + MarshalTypeEnumStringImageCapabilitySchemaDescriptor + }{ + "enumstring", + (MarshalTypeEnumStringImageCapabilitySchemaDescriptor)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_details.go new file mode 100644 index 000000000..fe5b29238 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_details.go @@ -0,0 +1,122 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ExportImageDetails The destination details for the image export. +// Set `destinationType` to `objectStorageTuple` +// and use ExportImageViaObjectStorageTupleDetails +// when specifying the namespace, bucket name, and object name. +// Set `destinationType` to `objectStorageUri` and +// use ExportImageViaObjectStorageUriDetails +// when specifying the Object Storage URL. +type ExportImageDetails interface { + + // The format to export the image to. The default value is `OCI`. + // The following image formats are available: + // - `OCI` - Oracle Cloud Infrastructure file with a QCOW2 image and Oracle Cloud Infrastructure metadata (.oci). + // Use this format to export a custom image that you want to import into other tenancies or regions. + // - `QCOW2` - QEMU Copy On Write (.qcow2) + // - `VDI` - Virtual Disk Image (.vdi) for Oracle VM VirtualBox + // - `VHD` - Virtual Hard Disk (.vhd) for Hyper-V + // - `VMDK` - Virtual Machine Disk (.vmdk) + GetExportFormat() ExportImageDetailsExportFormatEnum +} + +type exportimagedetails struct { + JsonData []byte + ExportFormat ExportImageDetailsExportFormatEnum `mandatory:"false" json:"exportFormat,omitempty"` + DestinationType string `json:"destinationType"` +} + +// UnmarshalJSON unmarshals json +func (m *exportimagedetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerexportimagedetails exportimagedetails + s := struct { + Model Unmarshalerexportimagedetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.ExportFormat = s.Model.ExportFormat + m.DestinationType = s.Model.DestinationType + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *exportimagedetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.DestinationType { + case "objectStorageUri": + mm := ExportImageViaObjectStorageUriDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "objectStorageTuple": + mm := ExportImageViaObjectStorageTupleDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetExportFormat returns ExportFormat +func (m exportimagedetails) GetExportFormat() ExportImageDetailsExportFormatEnum { + return m.ExportFormat +} + +func (m exportimagedetails) String() string { + return common.PointerString(m) +} + +// ExportImageDetailsExportFormatEnum Enum with underlying type: string +type ExportImageDetailsExportFormatEnum string + +// Set of constants representing the allowable values for ExportImageDetailsExportFormatEnum +const ( + ExportImageDetailsExportFormatQcow2 ExportImageDetailsExportFormatEnum = "QCOW2" + ExportImageDetailsExportFormatVmdk ExportImageDetailsExportFormatEnum = "VMDK" + ExportImageDetailsExportFormatOci ExportImageDetailsExportFormatEnum = "OCI" + ExportImageDetailsExportFormatVhd ExportImageDetailsExportFormatEnum = "VHD" + ExportImageDetailsExportFormatVdi ExportImageDetailsExportFormatEnum = "VDI" +) + +var mappingExportImageDetailsExportFormat = map[string]ExportImageDetailsExportFormatEnum{ + "QCOW2": ExportImageDetailsExportFormatQcow2, + "VMDK": ExportImageDetailsExportFormatVmdk, + "OCI": ExportImageDetailsExportFormatOci, + "VHD": ExportImageDetailsExportFormatVhd, + "VDI": ExportImageDetailsExportFormatVdi, +} + +// GetExportImageDetailsExportFormatEnumValues Enumerates the set of values for ExportImageDetailsExportFormatEnum +func GetExportImageDetailsExportFormatEnumValues() []ExportImageDetailsExportFormatEnum { + values := make([]ExportImageDetailsExportFormatEnum, 0) + for _, v := range mappingExportImageDetailsExportFormat { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_request_response.go new file mode 100644 index 000000000..38cbacda2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_request_response.go @@ -0,0 +1,96 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ExportImageRequest wrapper for the ExportImage operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ExportImage.go.html to see an example of how to use ExportImageRequest. +type ExportImageRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the image. + ImageId *string `mandatory:"true" contributesTo:"path" name:"imageId"` + + // Details for the image export. + ExportImageDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ExportImageRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ExportImageRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ExportImageRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ExportImageRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ExportImageResponse wrapper for the ExportImage operation +type ExportImageResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Image instance + Image `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response ExportImageResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ExportImageResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_via_object_storage_tuple_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_via_object_storage_tuple_details.go new file mode 100644 index 000000000..330ef5ab6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_via_object_storage_tuple_details.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ExportImageViaObjectStorageTupleDetails The representation of ExportImageViaObjectStorageTupleDetails +type ExportImageViaObjectStorageTupleDetails struct { + + // The Object Storage bucket to export the image to. + BucketName *string `mandatory:"true" json:"bucketName"` + + // The Object Storage namespace to export the image to. + NamespaceName *string `mandatory:"true" json:"namespaceName"` + + // The Object Storage object name for the exported image. + ObjectName *string `mandatory:"true" json:"objectName"` + + // The format to export the image to. The default value is `OCI`. + // The following image formats are available: + // - `OCI` - Oracle Cloud Infrastructure file with a QCOW2 image and Oracle Cloud Infrastructure metadata (.oci). + // Use this format to export a custom image that you want to import into other tenancies or regions. + // - `QCOW2` - QEMU Copy On Write (.qcow2) + // - `VDI` - Virtual Disk Image (.vdi) for Oracle VM VirtualBox + // - `VHD` - Virtual Hard Disk (.vhd) for Hyper-V + // - `VMDK` - Virtual Machine Disk (.vmdk) + ExportFormat ExportImageDetailsExportFormatEnum `mandatory:"false" json:"exportFormat,omitempty"` +} + +//GetExportFormat returns ExportFormat +func (m ExportImageViaObjectStorageTupleDetails) GetExportFormat() ExportImageDetailsExportFormatEnum { + return m.ExportFormat +} + +func (m ExportImageViaObjectStorageTupleDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m ExportImageViaObjectStorageTupleDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeExportImageViaObjectStorageTupleDetails ExportImageViaObjectStorageTupleDetails + s := struct { + DiscriminatorParam string `json:"destinationType"` + MarshalTypeExportImageViaObjectStorageTupleDetails + }{ + "objectStorageTuple", + (MarshalTypeExportImageViaObjectStorageTupleDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_via_object_storage_uri_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_via_object_storage_uri_details.go new file mode 100644 index 000000000..a0ae835e3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/export_image_via_object_storage_uri_details.go @@ -0,0 +1,62 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ExportImageViaObjectStorageUriDetails The representation of ExportImageViaObjectStorageUriDetails +type ExportImageViaObjectStorageUriDetails struct { + + // The Object Storage URL to export the image to. See Object + // Storage URLs (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/imageimportexport.htm#URLs) + // and Using Pre-Authenticated Requests (https://docs.cloud.oracle.com/iaas/Content/Object/Tasks/usingpreauthenticatedrequests.htm) + // for constructing URLs for image import/export. + DestinationUri *string `mandatory:"true" json:"destinationUri"` + + // The format to export the image to. The default value is `OCI`. + // The following image formats are available: + // - `OCI` - Oracle Cloud Infrastructure file with a QCOW2 image and Oracle Cloud Infrastructure metadata (.oci). + // Use this format to export a custom image that you want to import into other tenancies or regions. + // - `QCOW2` - QEMU Copy On Write (.qcow2) + // - `VDI` - Virtual Disk Image (.vdi) for Oracle VM VirtualBox + // - `VHD` - Virtual Hard Disk (.vhd) for Hyper-V + // - `VMDK` - Virtual Machine Disk (.vmdk) + ExportFormat ExportImageDetailsExportFormatEnum `mandatory:"false" json:"exportFormat,omitempty"` +} + +//GetExportFormat returns ExportFormat +func (m ExportImageViaObjectStorageUriDetails) GetExportFormat() ExportImageDetailsExportFormatEnum { + return m.ExportFormat +} + +func (m ExportImageViaObjectStorageUriDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m ExportImageViaObjectStorageUriDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeExportImageViaObjectStorageUriDetails ExportImageViaObjectStorageUriDetails + s := struct { + DiscriminatorParam string `json:"destinationType"` + MarshalTypeExportImageViaObjectStorageUriDetails + }{ + "objectStorageUri", + (MarshalTypeExportImageViaObjectStorageUriDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/fast_connect_provider_service.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/fast_connect_provider_service.go new file mode 100644 index 000000000..dd3ff9cb5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/fast_connect_provider_service.go @@ -0,0 +1,238 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// FastConnectProviderService A service offering from a supported provider. For more information, +// see FastConnect Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/fastconnect.htm). +type FastConnectProviderService struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the service offered by the provider. + Id *string `mandatory:"true" json:"id"` + + // Who is responsible for managing the private peering BGP information. + PrivatePeeringBgpManagement FastConnectProviderServicePrivatePeeringBgpManagementEnum `mandatory:"true" json:"privatePeeringBgpManagement"` + + // The name of the provider. + ProviderName *string `mandatory:"true" json:"providerName"` + + // The name of the service offered by the provider. + ProviderServiceName *string `mandatory:"true" json:"providerServiceName"` + + // Who is responsible for managing the public peering BGP information. + PublicPeeringBgpManagement FastConnectProviderServicePublicPeeringBgpManagementEnum `mandatory:"true" json:"publicPeeringBgpManagement"` + + // Who is responsible for managing the ASN information for the network at the other end + // of the connection from Oracle. + CustomerAsnManagement FastConnectProviderServiceCustomerAsnManagementEnum `mandatory:"true" json:"customerAsnManagement"` + + // Who is responsible for managing the provider service key. + ProviderServiceKeyManagement FastConnectProviderServiceProviderServiceKeyManagementEnum `mandatory:"true" json:"providerServiceKeyManagement"` + + // Who is responsible for managing the virtual circuit bandwidth. + BandwithShapeManagement FastConnectProviderServiceBandwithShapeManagementEnum `mandatory:"true" json:"bandwithShapeManagement"` + + // Total number of cross-connect or cross-connect groups required for the virtual circuit. + RequiredTotalCrossConnects *int `mandatory:"true" json:"requiredTotalCrossConnects"` + + // Provider service type. + Type FastConnectProviderServiceTypeEnum `mandatory:"true" json:"type"` + + // The location of the provider's website or portal. This portal is where you can get information + // about the provider service, create a virtual circuit connection from the provider to Oracle + // Cloud Infrastructure, and retrieve your provider service key for that virtual circuit connection. + // Example: `https://example.com` + Description *string `mandatory:"false" json:"description"` + + // An array of virtual circuit types supported by this service. + SupportedVirtualCircuitTypes []FastConnectProviderServiceSupportedVirtualCircuitTypesEnum `mandatory:"false" json:"supportedVirtualCircuitTypes,omitempty"` +} + +func (m FastConnectProviderService) String() string { + return common.PointerString(m) +} + +// FastConnectProviderServicePrivatePeeringBgpManagementEnum Enum with underlying type: string +type FastConnectProviderServicePrivatePeeringBgpManagementEnum string + +// Set of constants representing the allowable values for FastConnectProviderServicePrivatePeeringBgpManagementEnum +const ( + FastConnectProviderServicePrivatePeeringBgpManagementCustomerManaged FastConnectProviderServicePrivatePeeringBgpManagementEnum = "CUSTOMER_MANAGED" + FastConnectProviderServicePrivatePeeringBgpManagementProviderManaged FastConnectProviderServicePrivatePeeringBgpManagementEnum = "PROVIDER_MANAGED" + FastConnectProviderServicePrivatePeeringBgpManagementOracleManaged FastConnectProviderServicePrivatePeeringBgpManagementEnum = "ORACLE_MANAGED" +) + +var mappingFastConnectProviderServicePrivatePeeringBgpManagement = map[string]FastConnectProviderServicePrivatePeeringBgpManagementEnum{ + "CUSTOMER_MANAGED": FastConnectProviderServicePrivatePeeringBgpManagementCustomerManaged, + "PROVIDER_MANAGED": FastConnectProviderServicePrivatePeeringBgpManagementProviderManaged, + "ORACLE_MANAGED": FastConnectProviderServicePrivatePeeringBgpManagementOracleManaged, +} + +// GetFastConnectProviderServicePrivatePeeringBgpManagementEnumValues Enumerates the set of values for FastConnectProviderServicePrivatePeeringBgpManagementEnum +func GetFastConnectProviderServicePrivatePeeringBgpManagementEnumValues() []FastConnectProviderServicePrivatePeeringBgpManagementEnum { + values := make([]FastConnectProviderServicePrivatePeeringBgpManagementEnum, 0) + for _, v := range mappingFastConnectProviderServicePrivatePeeringBgpManagement { + values = append(values, v) + } + return values +} + +// FastConnectProviderServicePublicPeeringBgpManagementEnum Enum with underlying type: string +type FastConnectProviderServicePublicPeeringBgpManagementEnum string + +// Set of constants representing the allowable values for FastConnectProviderServicePublicPeeringBgpManagementEnum +const ( + FastConnectProviderServicePublicPeeringBgpManagementCustomerManaged FastConnectProviderServicePublicPeeringBgpManagementEnum = "CUSTOMER_MANAGED" + FastConnectProviderServicePublicPeeringBgpManagementProviderManaged FastConnectProviderServicePublicPeeringBgpManagementEnum = "PROVIDER_MANAGED" + FastConnectProviderServicePublicPeeringBgpManagementOracleManaged FastConnectProviderServicePublicPeeringBgpManagementEnum = "ORACLE_MANAGED" +) + +var mappingFastConnectProviderServicePublicPeeringBgpManagement = map[string]FastConnectProviderServicePublicPeeringBgpManagementEnum{ + "CUSTOMER_MANAGED": FastConnectProviderServicePublicPeeringBgpManagementCustomerManaged, + "PROVIDER_MANAGED": FastConnectProviderServicePublicPeeringBgpManagementProviderManaged, + "ORACLE_MANAGED": FastConnectProviderServicePublicPeeringBgpManagementOracleManaged, +} + +// GetFastConnectProviderServicePublicPeeringBgpManagementEnumValues Enumerates the set of values for FastConnectProviderServicePublicPeeringBgpManagementEnum +func GetFastConnectProviderServicePublicPeeringBgpManagementEnumValues() []FastConnectProviderServicePublicPeeringBgpManagementEnum { + values := make([]FastConnectProviderServicePublicPeeringBgpManagementEnum, 0) + for _, v := range mappingFastConnectProviderServicePublicPeeringBgpManagement { + values = append(values, v) + } + return values +} + +// FastConnectProviderServiceSupportedVirtualCircuitTypesEnum Enum with underlying type: string +type FastConnectProviderServiceSupportedVirtualCircuitTypesEnum string + +// Set of constants representing the allowable values for FastConnectProviderServiceSupportedVirtualCircuitTypesEnum +const ( + FastConnectProviderServiceSupportedVirtualCircuitTypesPublic FastConnectProviderServiceSupportedVirtualCircuitTypesEnum = "PUBLIC" + FastConnectProviderServiceSupportedVirtualCircuitTypesPrivate FastConnectProviderServiceSupportedVirtualCircuitTypesEnum = "PRIVATE" +) + +var mappingFastConnectProviderServiceSupportedVirtualCircuitTypes = map[string]FastConnectProviderServiceSupportedVirtualCircuitTypesEnum{ + "PUBLIC": FastConnectProviderServiceSupportedVirtualCircuitTypesPublic, + "PRIVATE": FastConnectProviderServiceSupportedVirtualCircuitTypesPrivate, +} + +// GetFastConnectProviderServiceSupportedVirtualCircuitTypesEnumValues Enumerates the set of values for FastConnectProviderServiceSupportedVirtualCircuitTypesEnum +func GetFastConnectProviderServiceSupportedVirtualCircuitTypesEnumValues() []FastConnectProviderServiceSupportedVirtualCircuitTypesEnum { + values := make([]FastConnectProviderServiceSupportedVirtualCircuitTypesEnum, 0) + for _, v := range mappingFastConnectProviderServiceSupportedVirtualCircuitTypes { + values = append(values, v) + } + return values +} + +// FastConnectProviderServiceCustomerAsnManagementEnum Enum with underlying type: string +type FastConnectProviderServiceCustomerAsnManagementEnum string + +// Set of constants representing the allowable values for FastConnectProviderServiceCustomerAsnManagementEnum +const ( + FastConnectProviderServiceCustomerAsnManagementCustomerManaged FastConnectProviderServiceCustomerAsnManagementEnum = "CUSTOMER_MANAGED" + FastConnectProviderServiceCustomerAsnManagementProviderManaged FastConnectProviderServiceCustomerAsnManagementEnum = "PROVIDER_MANAGED" + FastConnectProviderServiceCustomerAsnManagementOracleManaged FastConnectProviderServiceCustomerAsnManagementEnum = "ORACLE_MANAGED" +) + +var mappingFastConnectProviderServiceCustomerAsnManagement = map[string]FastConnectProviderServiceCustomerAsnManagementEnum{ + "CUSTOMER_MANAGED": FastConnectProviderServiceCustomerAsnManagementCustomerManaged, + "PROVIDER_MANAGED": FastConnectProviderServiceCustomerAsnManagementProviderManaged, + "ORACLE_MANAGED": FastConnectProviderServiceCustomerAsnManagementOracleManaged, +} + +// GetFastConnectProviderServiceCustomerAsnManagementEnumValues Enumerates the set of values for FastConnectProviderServiceCustomerAsnManagementEnum +func GetFastConnectProviderServiceCustomerAsnManagementEnumValues() []FastConnectProviderServiceCustomerAsnManagementEnum { + values := make([]FastConnectProviderServiceCustomerAsnManagementEnum, 0) + for _, v := range mappingFastConnectProviderServiceCustomerAsnManagement { + values = append(values, v) + } + return values +} + +// FastConnectProviderServiceProviderServiceKeyManagementEnum Enum with underlying type: string +type FastConnectProviderServiceProviderServiceKeyManagementEnum string + +// Set of constants representing the allowable values for FastConnectProviderServiceProviderServiceKeyManagementEnum +const ( + FastConnectProviderServiceProviderServiceKeyManagementCustomerManaged FastConnectProviderServiceProviderServiceKeyManagementEnum = "CUSTOMER_MANAGED" + FastConnectProviderServiceProviderServiceKeyManagementProviderManaged FastConnectProviderServiceProviderServiceKeyManagementEnum = "PROVIDER_MANAGED" + FastConnectProviderServiceProviderServiceKeyManagementOracleManaged FastConnectProviderServiceProviderServiceKeyManagementEnum = "ORACLE_MANAGED" +) + +var mappingFastConnectProviderServiceProviderServiceKeyManagement = map[string]FastConnectProviderServiceProviderServiceKeyManagementEnum{ + "CUSTOMER_MANAGED": FastConnectProviderServiceProviderServiceKeyManagementCustomerManaged, + "PROVIDER_MANAGED": FastConnectProviderServiceProviderServiceKeyManagementProviderManaged, + "ORACLE_MANAGED": FastConnectProviderServiceProviderServiceKeyManagementOracleManaged, +} + +// GetFastConnectProviderServiceProviderServiceKeyManagementEnumValues Enumerates the set of values for FastConnectProviderServiceProviderServiceKeyManagementEnum +func GetFastConnectProviderServiceProviderServiceKeyManagementEnumValues() []FastConnectProviderServiceProviderServiceKeyManagementEnum { + values := make([]FastConnectProviderServiceProviderServiceKeyManagementEnum, 0) + for _, v := range mappingFastConnectProviderServiceProviderServiceKeyManagement { + values = append(values, v) + } + return values +} + +// FastConnectProviderServiceBandwithShapeManagementEnum Enum with underlying type: string +type FastConnectProviderServiceBandwithShapeManagementEnum string + +// Set of constants representing the allowable values for FastConnectProviderServiceBandwithShapeManagementEnum +const ( + FastConnectProviderServiceBandwithShapeManagementCustomerManaged FastConnectProviderServiceBandwithShapeManagementEnum = "CUSTOMER_MANAGED" + FastConnectProviderServiceBandwithShapeManagementProviderManaged FastConnectProviderServiceBandwithShapeManagementEnum = "PROVIDER_MANAGED" + FastConnectProviderServiceBandwithShapeManagementOracleManaged FastConnectProviderServiceBandwithShapeManagementEnum = "ORACLE_MANAGED" +) + +var mappingFastConnectProviderServiceBandwithShapeManagement = map[string]FastConnectProviderServiceBandwithShapeManagementEnum{ + "CUSTOMER_MANAGED": FastConnectProviderServiceBandwithShapeManagementCustomerManaged, + "PROVIDER_MANAGED": FastConnectProviderServiceBandwithShapeManagementProviderManaged, + "ORACLE_MANAGED": FastConnectProviderServiceBandwithShapeManagementOracleManaged, +} + +// GetFastConnectProviderServiceBandwithShapeManagementEnumValues Enumerates the set of values for FastConnectProviderServiceBandwithShapeManagementEnum +func GetFastConnectProviderServiceBandwithShapeManagementEnumValues() []FastConnectProviderServiceBandwithShapeManagementEnum { + values := make([]FastConnectProviderServiceBandwithShapeManagementEnum, 0) + for _, v := range mappingFastConnectProviderServiceBandwithShapeManagement { + values = append(values, v) + } + return values +} + +// FastConnectProviderServiceTypeEnum Enum with underlying type: string +type FastConnectProviderServiceTypeEnum string + +// Set of constants representing the allowable values for FastConnectProviderServiceTypeEnum +const ( + FastConnectProviderServiceTypeLayer2 FastConnectProviderServiceTypeEnum = "LAYER2" + FastConnectProviderServiceTypeLayer3 FastConnectProviderServiceTypeEnum = "LAYER3" +) + +var mappingFastConnectProviderServiceType = map[string]FastConnectProviderServiceTypeEnum{ + "LAYER2": FastConnectProviderServiceTypeLayer2, + "LAYER3": FastConnectProviderServiceTypeLayer3, +} + +// GetFastConnectProviderServiceTypeEnumValues Enumerates the set of values for FastConnectProviderServiceTypeEnum +func GetFastConnectProviderServiceTypeEnumValues() []FastConnectProviderServiceTypeEnum { + values := make([]FastConnectProviderServiceTypeEnum, 0) + for _, v := range mappingFastConnectProviderServiceType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/fast_connect_provider_service_key.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/fast_connect_provider_service_key.go new file mode 100644 index 000000000..292b2d141 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/fast_connect_provider_service_key.go @@ -0,0 +1,42 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// FastConnectProviderServiceKey A provider service key and its details. A provider service key is an identifier for a provider's +// virtual circuit. +type FastConnectProviderServiceKey struct { + + // The service key that the provider gives you when you set up a virtual circuit connection + // from the provider to Oracle Cloud Infrastructure. Use this value as the `providerServiceKeyName` + // query parameter for + // GetFastConnectProviderServiceKey. + Name *string `mandatory:"true" json:"name"` + + // The provisioned data rate of the connection. To get a list of the + // available bandwidth levels (that is, shapes), see + // ListFastConnectProviderVirtualCircuitBandwidthShapes. + // Example: `10 Gbps` + BandwidthShapeName *string `mandatory:"false" json:"bandwidthShapeName"` + + // The provider's peering location. + PeeringLocation *string `mandatory:"false" json:"peeringLocation"` +} + +func (m FastConnectProviderServiceKey) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_all_drg_attachments_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_all_drg_attachments_request_response.go new file mode 100644 index 000000000..a2d69921a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_all_drg_attachments_request_response.go @@ -0,0 +1,125 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetAllDrgAttachmentsRequest wrapper for the GetAllDrgAttachments operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetAllDrgAttachments.go.html to see an example of how to use GetAllDrgAttachmentsRequest. +type GetAllDrgAttachmentsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"true" contributesTo:"path" name:"drgId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The type for the network resource attached to the DRG. + AttachmentType GetAllDrgAttachmentsAttachmentTypeEnum `mandatory:"false" contributesTo:"query" name:"attachmentType" omitEmpty:"true"` + + // Whether the DRG attachment lives in a different tenancy than the DRG. + IsCrossTenancy *bool `mandatory:"false" contributesTo:"query" name:"isCrossTenancy"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetAllDrgAttachmentsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetAllDrgAttachmentsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetAllDrgAttachmentsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetAllDrgAttachmentsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetAllDrgAttachmentsResponse wrapper for the GetAllDrgAttachments operation +type GetAllDrgAttachmentsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []DrgAttachmentInfo instances + Items []DrgAttachmentInfo `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetAllDrgAttachmentsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetAllDrgAttachmentsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// GetAllDrgAttachmentsAttachmentTypeEnum Enum with underlying type: string +type GetAllDrgAttachmentsAttachmentTypeEnum string + +// Set of constants representing the allowable values for GetAllDrgAttachmentsAttachmentTypeEnum +const ( + GetAllDrgAttachmentsAttachmentTypeVcn GetAllDrgAttachmentsAttachmentTypeEnum = "VCN" + GetAllDrgAttachmentsAttachmentTypeVirtualCircuit GetAllDrgAttachmentsAttachmentTypeEnum = "VIRTUAL_CIRCUIT" + GetAllDrgAttachmentsAttachmentTypeRemotePeeringConnection GetAllDrgAttachmentsAttachmentTypeEnum = "REMOTE_PEERING_CONNECTION" + GetAllDrgAttachmentsAttachmentTypeIpsecTunnel GetAllDrgAttachmentsAttachmentTypeEnum = "IPSEC_TUNNEL" + GetAllDrgAttachmentsAttachmentTypeAll GetAllDrgAttachmentsAttachmentTypeEnum = "ALL" +) + +var mappingGetAllDrgAttachmentsAttachmentType = map[string]GetAllDrgAttachmentsAttachmentTypeEnum{ + "VCN": GetAllDrgAttachmentsAttachmentTypeVcn, + "VIRTUAL_CIRCUIT": GetAllDrgAttachmentsAttachmentTypeVirtualCircuit, + "REMOTE_PEERING_CONNECTION": GetAllDrgAttachmentsAttachmentTypeRemotePeeringConnection, + "IPSEC_TUNNEL": GetAllDrgAttachmentsAttachmentTypeIpsecTunnel, + "ALL": GetAllDrgAttachmentsAttachmentTypeAll, +} + +// GetGetAllDrgAttachmentsAttachmentTypeEnumValues Enumerates the set of values for GetAllDrgAttachmentsAttachmentTypeEnum +func GetGetAllDrgAttachmentsAttachmentTypeEnumValues() []GetAllDrgAttachmentsAttachmentTypeEnum { + values := make([]GetAllDrgAttachmentsAttachmentTypeEnum, 0) + for _, v := range mappingGetAllDrgAttachmentsAttachmentType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_allowed_ike_i_p_sec_parameters_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_allowed_ike_i_p_sec_parameters_request_response.go new file mode 100644 index 000000000..3ec467eac --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_allowed_ike_i_p_sec_parameters_request_response.go @@ -0,0 +1,71 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetAllowedIkeIPSecParametersRequest wrapper for the GetAllowedIkeIPSecParameters operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetAllowedIkeIPSecParameters.go.html to see an example of how to use GetAllowedIkeIPSecParametersRequest. +type GetAllowedIkeIPSecParametersRequest struct { + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetAllowedIkeIPSecParametersRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetAllowedIkeIPSecParametersRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetAllowedIkeIPSecParametersRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetAllowedIkeIPSecParametersRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetAllowedIkeIPSecParametersResponse wrapper for the GetAllowedIkeIPSecParameters operation +type GetAllowedIkeIPSecParametersResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The AllowedIkeIpSecParameters instance + AllowedIkeIpSecParameters `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetAllowedIkeIPSecParametersResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetAllowedIkeIPSecParametersResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_app_catalog_listing_agreements_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_app_catalog_listing_agreements_request_response.go new file mode 100644 index 000000000..ebfca0ff5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_app_catalog_listing_agreements_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetAppCatalogListingAgreementsRequest wrapper for the GetAppCatalogListingAgreements operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetAppCatalogListingAgreements.go.html to see an example of how to use GetAppCatalogListingAgreementsRequest. +type GetAppCatalogListingAgreementsRequest struct { + + // The OCID of the listing. + ListingId *string `mandatory:"true" contributesTo:"path" name:"listingId"` + + // Listing Resource Version. + ResourceVersion *string `mandatory:"true" contributesTo:"path" name:"resourceVersion"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetAppCatalogListingAgreementsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetAppCatalogListingAgreementsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetAppCatalogListingAgreementsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetAppCatalogListingAgreementsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetAppCatalogListingAgreementsResponse wrapper for the GetAppCatalogListingAgreements operation +type GetAppCatalogListingAgreementsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The AppCatalogListingResourceVersionAgreements instance + AppCatalogListingResourceVersionAgreements `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetAppCatalogListingAgreementsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetAppCatalogListingAgreementsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_app_catalog_listing_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_app_catalog_listing_request_response.go new file mode 100644 index 000000000..1854613f0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_app_catalog_listing_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetAppCatalogListingRequest wrapper for the GetAppCatalogListing operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetAppCatalogListing.go.html to see an example of how to use GetAppCatalogListingRequest. +type GetAppCatalogListingRequest struct { + + // The OCID of the listing. + ListingId *string `mandatory:"true" contributesTo:"path" name:"listingId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetAppCatalogListingRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetAppCatalogListingRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetAppCatalogListingRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetAppCatalogListingRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetAppCatalogListingResponse wrapper for the GetAppCatalogListing operation +type GetAppCatalogListingResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The AppCatalogListing instance + AppCatalogListing `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetAppCatalogListingResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetAppCatalogListingResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_app_catalog_listing_resource_version_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_app_catalog_listing_resource_version_request_response.go new file mode 100644 index 000000000..29ca97f01 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_app_catalog_listing_resource_version_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetAppCatalogListingResourceVersionRequest wrapper for the GetAppCatalogListingResourceVersion operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetAppCatalogListingResourceVersion.go.html to see an example of how to use GetAppCatalogListingResourceVersionRequest. +type GetAppCatalogListingResourceVersionRequest struct { + + // The OCID of the listing. + ListingId *string `mandatory:"true" contributesTo:"path" name:"listingId"` + + // Listing Resource Version. + ResourceVersion *string `mandatory:"true" contributesTo:"path" name:"resourceVersion"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetAppCatalogListingResourceVersionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetAppCatalogListingResourceVersionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetAppCatalogListingResourceVersionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetAppCatalogListingResourceVersionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetAppCatalogListingResourceVersionResponse wrapper for the GetAppCatalogListingResourceVersion operation +type GetAppCatalogListingResourceVersionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The AppCatalogListingResourceVersion instance + AppCatalogListingResourceVersion `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetAppCatalogListingResourceVersionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetAppCatalogListingResourceVersionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_block_volume_replica_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_block_volume_replica_request_response.go new file mode 100644 index 000000000..1f86e1fa5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_block_volume_replica_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetBlockVolumeReplicaRequest wrapper for the GetBlockVolumeReplica operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetBlockVolumeReplica.go.html to see an example of how to use GetBlockVolumeReplicaRequest. +type GetBlockVolumeReplicaRequest struct { + + // The OCID of the block volume replica. + BlockVolumeReplicaId *string `mandatory:"true" contributesTo:"path" name:"blockVolumeReplicaId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetBlockVolumeReplicaRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetBlockVolumeReplicaRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetBlockVolumeReplicaRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetBlockVolumeReplicaRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetBlockVolumeReplicaResponse wrapper for the GetBlockVolumeReplica operation +type GetBlockVolumeReplicaResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The BlockVolumeReplica instance + BlockVolumeReplica `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetBlockVolumeReplicaResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetBlockVolumeReplicaResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_attachment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_attachment_request_response.go new file mode 100644 index 000000000..9ad394598 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_attachment_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetBootVolumeAttachmentRequest wrapper for the GetBootVolumeAttachment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetBootVolumeAttachment.go.html to see an example of how to use GetBootVolumeAttachmentRequest. +type GetBootVolumeAttachmentRequest struct { + + // The OCID of the boot volume attachment. + BootVolumeAttachmentId *string `mandatory:"true" contributesTo:"path" name:"bootVolumeAttachmentId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetBootVolumeAttachmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetBootVolumeAttachmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetBootVolumeAttachmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetBootVolumeAttachmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetBootVolumeAttachmentResponse wrapper for the GetBootVolumeAttachment operation +type GetBootVolumeAttachmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The BootVolumeAttachment instance + BootVolumeAttachment `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetBootVolumeAttachmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetBootVolumeAttachmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_backup_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_backup_request_response.go new file mode 100644 index 000000000..4b7b94c1c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_backup_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetBootVolumeBackupRequest wrapper for the GetBootVolumeBackup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetBootVolumeBackup.go.html to see an example of how to use GetBootVolumeBackupRequest. +type GetBootVolumeBackupRequest struct { + + // The OCID of the boot volume backup. + BootVolumeBackupId *string `mandatory:"true" contributesTo:"path" name:"bootVolumeBackupId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetBootVolumeBackupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetBootVolumeBackupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetBootVolumeBackupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetBootVolumeBackupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetBootVolumeBackupResponse wrapper for the GetBootVolumeBackup operation +type GetBootVolumeBackupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The BootVolumeBackup instance + BootVolumeBackup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetBootVolumeBackupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetBootVolumeBackupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_kms_key_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_kms_key_request_response.go new file mode 100644 index 000000000..53db4f872 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_kms_key_request_response.go @@ -0,0 +1,82 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetBootVolumeKmsKeyRequest wrapper for the GetBootVolumeKmsKey operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetBootVolumeKmsKey.go.html to see an example of how to use GetBootVolumeKmsKeyRequest. +type GetBootVolumeKmsKeyRequest struct { + + // The OCID of the boot volume. + BootVolumeId *string `mandatory:"true" contributesTo:"path" name:"bootVolumeId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetBootVolumeKmsKeyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetBootVolumeKmsKeyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetBootVolumeKmsKeyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetBootVolumeKmsKeyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetBootVolumeKmsKeyResponse wrapper for the GetBootVolumeKmsKey operation +type GetBootVolumeKmsKeyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The BootVolumeKmsKey instance + BootVolumeKmsKey `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetBootVolumeKmsKeyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetBootVolumeKmsKeyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_replica_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_replica_request_response.go new file mode 100644 index 000000000..e3229df51 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_replica_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetBootVolumeReplicaRequest wrapper for the GetBootVolumeReplica operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetBootVolumeReplica.go.html to see an example of how to use GetBootVolumeReplicaRequest. +type GetBootVolumeReplicaRequest struct { + + // The OCID of the boot volume replica. + BootVolumeReplicaId *string `mandatory:"true" contributesTo:"path" name:"bootVolumeReplicaId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetBootVolumeReplicaRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetBootVolumeReplicaRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetBootVolumeReplicaRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetBootVolumeReplicaRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetBootVolumeReplicaResponse wrapper for the GetBootVolumeReplica operation +type GetBootVolumeReplicaResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The BootVolumeReplica instance + BootVolumeReplica `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetBootVolumeReplicaResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetBootVolumeReplicaResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_request_response.go new file mode 100644 index 000000000..af93b4da9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_boot_volume_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetBootVolumeRequest wrapper for the GetBootVolume operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetBootVolume.go.html to see an example of how to use GetBootVolumeRequest. +type GetBootVolumeRequest struct { + + // The OCID of the boot volume. + BootVolumeId *string `mandatory:"true" contributesTo:"path" name:"bootVolumeId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetBootVolumeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetBootVolumeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetBootVolumeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetBootVolumeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetBootVolumeResponse wrapper for the GetBootVolume operation +type GetBootVolumeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The BootVolume instance + BootVolume `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetBootVolumeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetBootVolumeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_byoip_range_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_byoip_range_request_response.go new file mode 100644 index 000000000..7a4bd1f3b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_byoip_range_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetByoipRangeRequest wrapper for the GetByoipRange operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetByoipRange.go.html to see an example of how to use GetByoipRangeRequest. +type GetByoipRangeRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the `ByoipRange` resource containing the BYOIP CIDR block. + ByoipRangeId *string `mandatory:"true" contributesTo:"path" name:"byoipRangeId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetByoipRangeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetByoipRangeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetByoipRangeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetByoipRangeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetByoipRangeResponse wrapper for the GetByoipRange operation +type GetByoipRangeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ByoipRange instance + ByoipRange `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetByoipRangeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetByoipRangeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cluster_network_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cluster_network_request_response.go new file mode 100644 index 000000000..bb8228938 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cluster_network_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetClusterNetworkRequest wrapper for the GetClusterNetwork operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetClusterNetwork.go.html to see an example of how to use GetClusterNetworkRequest. +type GetClusterNetworkRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the cluster network. + ClusterNetworkId *string `mandatory:"true" contributesTo:"path" name:"clusterNetworkId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetClusterNetworkRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetClusterNetworkRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetClusterNetworkRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetClusterNetworkRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetClusterNetworkResponse wrapper for the GetClusterNetwork operation +type GetClusterNetworkResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ClusterNetwork instance + ClusterNetwork `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetClusterNetworkResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetClusterNetworkResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_capacity_reservation_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_capacity_reservation_request_response.go new file mode 100644 index 000000000..9c2af2a09 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_capacity_reservation_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetComputeCapacityReservationRequest wrapper for the GetComputeCapacityReservation operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetComputeCapacityReservation.go.html to see an example of how to use GetComputeCapacityReservationRequest. +type GetComputeCapacityReservationRequest struct { + + // The OCID of the compute capacity reservation. + CapacityReservationId *string `mandatory:"true" contributesTo:"path" name:"capacityReservationId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetComputeCapacityReservationRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetComputeCapacityReservationRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetComputeCapacityReservationRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetComputeCapacityReservationRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetComputeCapacityReservationResponse wrapper for the GetComputeCapacityReservation operation +type GetComputeCapacityReservationResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ComputeCapacityReservation instance + ComputeCapacityReservation `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetComputeCapacityReservationResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetComputeCapacityReservationResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_global_image_capability_schema_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_global_image_capability_schema_request_response.go new file mode 100644 index 000000000..2a33d30d2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_global_image_capability_schema_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetComputeGlobalImageCapabilitySchemaRequest wrapper for the GetComputeGlobalImageCapabilitySchema operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetComputeGlobalImageCapabilitySchema.go.html to see an example of how to use GetComputeGlobalImageCapabilitySchemaRequest. +type GetComputeGlobalImageCapabilitySchemaRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compute global image capability schema + ComputeGlobalImageCapabilitySchemaId *string `mandatory:"true" contributesTo:"path" name:"computeGlobalImageCapabilitySchemaId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetComputeGlobalImageCapabilitySchemaRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetComputeGlobalImageCapabilitySchemaRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetComputeGlobalImageCapabilitySchemaRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetComputeGlobalImageCapabilitySchemaRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetComputeGlobalImageCapabilitySchemaResponse wrapper for the GetComputeGlobalImageCapabilitySchema operation +type GetComputeGlobalImageCapabilitySchemaResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ComputeGlobalImageCapabilitySchema instance + ComputeGlobalImageCapabilitySchema `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetComputeGlobalImageCapabilitySchemaResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetComputeGlobalImageCapabilitySchemaResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_global_image_capability_schema_version_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_global_image_capability_schema_version_request_response.go new file mode 100644 index 000000000..204289a4b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_global_image_capability_schema_version_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetComputeGlobalImageCapabilitySchemaVersionRequest wrapper for the GetComputeGlobalImageCapabilitySchemaVersion operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetComputeGlobalImageCapabilitySchemaVersion.go.html to see an example of how to use GetComputeGlobalImageCapabilitySchemaVersionRequest. +type GetComputeGlobalImageCapabilitySchemaVersionRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compute global image capability schema + ComputeGlobalImageCapabilitySchemaId *string `mandatory:"true" contributesTo:"path" name:"computeGlobalImageCapabilitySchemaId"` + + // The name of the compute global image capability schema version + ComputeGlobalImageCapabilitySchemaVersionName *string `mandatory:"true" contributesTo:"path" name:"computeGlobalImageCapabilitySchemaVersionName"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetComputeGlobalImageCapabilitySchemaVersionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetComputeGlobalImageCapabilitySchemaVersionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetComputeGlobalImageCapabilitySchemaVersionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetComputeGlobalImageCapabilitySchemaVersionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetComputeGlobalImageCapabilitySchemaVersionResponse wrapper for the GetComputeGlobalImageCapabilitySchemaVersion operation +type GetComputeGlobalImageCapabilitySchemaVersionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ComputeGlobalImageCapabilitySchemaVersion instance + ComputeGlobalImageCapabilitySchemaVersion `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetComputeGlobalImageCapabilitySchemaVersionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetComputeGlobalImageCapabilitySchemaVersionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_image_capability_schema_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_image_capability_schema_request_response.go new file mode 100644 index 000000000..7928d0872 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_compute_image_capability_schema_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetComputeImageCapabilitySchemaRequest wrapper for the GetComputeImageCapabilitySchema operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetComputeImageCapabilitySchema.go.html to see an example of how to use GetComputeImageCapabilitySchemaRequest. +type GetComputeImageCapabilitySchemaRequest struct { + + // The id of the compute image capability schema or the image ocid + ComputeImageCapabilitySchemaId *string `mandatory:"true" contributesTo:"path" name:"computeImageCapabilitySchemaId"` + + // Merge the image capability schema with the global image capability schema + IsMergeEnabled *bool `mandatory:"false" contributesTo:"query" name:"isMergeEnabled"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetComputeImageCapabilitySchemaRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetComputeImageCapabilitySchemaRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetComputeImageCapabilitySchemaRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetComputeImageCapabilitySchemaRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetComputeImageCapabilitySchemaResponse wrapper for the GetComputeImageCapabilitySchema operation +type GetComputeImageCapabilitySchemaResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ComputeImageCapabilitySchema instance + ComputeImageCapabilitySchema `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetComputeImageCapabilitySchemaResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetComputeImageCapabilitySchemaResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_console_history_content_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_console_history_content_request_response.go new file mode 100644 index 000000000..1e56a175b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_console_history_content_request_response.go @@ -0,0 +1,83 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetConsoleHistoryContentRequest wrapper for the GetConsoleHistoryContent operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetConsoleHistoryContent.go.html to see an example of how to use GetConsoleHistoryContentRequest. +type GetConsoleHistoryContentRequest struct { + + // The OCID of the console history. + InstanceConsoleHistoryId *string `mandatory:"true" contributesTo:"path" name:"instanceConsoleHistoryId"` + + // Offset of the snapshot data to retrieve. + Offset *int `mandatory:"false" contributesTo:"query" name:"offset"` + + // Length of the snapshot data to retrieve. + Length *int `mandatory:"false" contributesTo:"query" name:"length"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetConsoleHistoryContentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetConsoleHistoryContentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetConsoleHistoryContentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetConsoleHistoryContentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetConsoleHistoryContentResponse wrapper for the GetConsoleHistoryContent operation +type GetConsoleHistoryContentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The string instance + Value *string `presentIn:"body" encoding:"plain-text"` + + // The number of bytes remaining in the snapshot. + OpcBytesRemaining *int `presentIn:"header" name:"opc-bytes-remaining"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetConsoleHistoryContentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetConsoleHistoryContentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_console_history_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_console_history_request_response.go new file mode 100644 index 000000000..1b217a31d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_console_history_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetConsoleHistoryRequest wrapper for the GetConsoleHistory operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetConsoleHistory.go.html to see an example of how to use GetConsoleHistoryRequest. +type GetConsoleHistoryRequest struct { + + // The OCID of the console history. + InstanceConsoleHistoryId *string `mandatory:"true" contributesTo:"path" name:"instanceConsoleHistoryId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetConsoleHistoryRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetConsoleHistoryRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetConsoleHistoryRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetConsoleHistoryRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetConsoleHistoryResponse wrapper for the GetConsoleHistory operation +type GetConsoleHistoryResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ConsoleHistory instance + ConsoleHistory `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetConsoleHistoryResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetConsoleHistoryResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cpe_device_config_content_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cpe_device_config_content_request_response.go new file mode 100644 index 000000000..ba3d42be9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cpe_device_config_content_request_response.go @@ -0,0 +1,75 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "io" + "net/http" +) + +// GetCpeDeviceConfigContentRequest wrapper for the GetCpeDeviceConfigContent operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetCpeDeviceConfigContent.go.html to see an example of how to use GetCpeDeviceConfigContentRequest. +type GetCpeDeviceConfigContentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the CPE. + CpeId *string `mandatory:"true" contributesTo:"path" name:"cpeId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetCpeDeviceConfigContentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetCpeDeviceConfigContentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetCpeDeviceConfigContentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetCpeDeviceConfigContentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetCpeDeviceConfigContentResponse wrapper for the GetCpeDeviceConfigContent operation +type GetCpeDeviceConfigContentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The io.ReadCloser instance + Content io.ReadCloser `presentIn:"body" encoding:"binary"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetCpeDeviceConfigContentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetCpeDeviceConfigContentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cpe_device_shape_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cpe_device_shape_request_response.go new file mode 100644 index 000000000..ef267c990 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cpe_device_shape_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetCpeDeviceShapeRequest wrapper for the GetCpeDeviceShape operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetCpeDeviceShape.go.html to see an example of how to use GetCpeDeviceShapeRequest. +type GetCpeDeviceShapeRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the CPE device shape. + CpeDeviceShapeId *string `mandatory:"true" contributesTo:"path" name:"cpeDeviceShapeId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetCpeDeviceShapeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetCpeDeviceShapeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetCpeDeviceShapeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetCpeDeviceShapeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetCpeDeviceShapeResponse wrapper for the GetCpeDeviceShape operation +type GetCpeDeviceShapeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The CpeDeviceShapeDetail instance + CpeDeviceShapeDetail `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetCpeDeviceShapeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetCpeDeviceShapeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cpe_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cpe_request_response.go new file mode 100644 index 000000000..90da93d27 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cpe_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetCpeRequest wrapper for the GetCpe operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetCpe.go.html to see an example of how to use GetCpeRequest. +type GetCpeRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the CPE. + CpeId *string `mandatory:"true" contributesTo:"path" name:"cpeId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetCpeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetCpeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetCpeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetCpeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetCpeResponse wrapper for the GetCpe operation +type GetCpeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Cpe instance + Cpe `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetCpeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetCpeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_group_request_response.go new file mode 100644 index 000000000..eaeddbfde --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_group_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetCrossConnectGroupRequest wrapper for the GetCrossConnectGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetCrossConnectGroup.go.html to see an example of how to use GetCrossConnectGroupRequest. +type GetCrossConnectGroupRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the cross-connect group. + CrossConnectGroupId *string `mandatory:"true" contributesTo:"path" name:"crossConnectGroupId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetCrossConnectGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetCrossConnectGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetCrossConnectGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetCrossConnectGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetCrossConnectGroupResponse wrapper for the GetCrossConnectGroup operation +type GetCrossConnectGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The CrossConnectGroup instance + CrossConnectGroup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetCrossConnectGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetCrossConnectGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_letter_of_authority_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_letter_of_authority_request_response.go new file mode 100644 index 000000000..9497d0a57 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_letter_of_authority_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetCrossConnectLetterOfAuthorityRequest wrapper for the GetCrossConnectLetterOfAuthority operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetCrossConnectLetterOfAuthority.go.html to see an example of how to use GetCrossConnectLetterOfAuthorityRequest. +type GetCrossConnectLetterOfAuthorityRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the cross-connect. + CrossConnectId *string `mandatory:"true" contributesTo:"path" name:"crossConnectId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetCrossConnectLetterOfAuthorityRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetCrossConnectLetterOfAuthorityRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetCrossConnectLetterOfAuthorityRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetCrossConnectLetterOfAuthorityRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetCrossConnectLetterOfAuthorityResponse wrapper for the GetCrossConnectLetterOfAuthority operation +type GetCrossConnectLetterOfAuthorityResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The LetterOfAuthority instance + LetterOfAuthority `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetCrossConnectLetterOfAuthorityResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetCrossConnectLetterOfAuthorityResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_request_response.go new file mode 100644 index 000000000..897434917 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetCrossConnectRequest wrapper for the GetCrossConnect operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetCrossConnect.go.html to see an example of how to use GetCrossConnectRequest. +type GetCrossConnectRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the cross-connect. + CrossConnectId *string `mandatory:"true" contributesTo:"path" name:"crossConnectId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetCrossConnectRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetCrossConnectRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetCrossConnectRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetCrossConnectRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetCrossConnectResponse wrapper for the GetCrossConnect operation +type GetCrossConnectResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The CrossConnect instance + CrossConnect `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetCrossConnectResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetCrossConnectResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_status_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_status_request_response.go new file mode 100644 index 000000000..8a7c17e60 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_cross_connect_status_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetCrossConnectStatusRequest wrapper for the GetCrossConnectStatus operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetCrossConnectStatus.go.html to see an example of how to use GetCrossConnectStatusRequest. +type GetCrossConnectStatusRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the cross-connect. + CrossConnectId *string `mandatory:"true" contributesTo:"path" name:"crossConnectId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetCrossConnectStatusRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetCrossConnectStatusRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetCrossConnectStatusRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetCrossConnectStatusRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetCrossConnectStatusResponse wrapper for the GetCrossConnectStatus operation +type GetCrossConnectStatusResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The CrossConnectStatus instance + CrossConnectStatus `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetCrossConnectStatusResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetCrossConnectStatusResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_dedicated_vm_host_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_dedicated_vm_host_request_response.go new file mode 100644 index 000000000..193994422 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_dedicated_vm_host_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetDedicatedVmHostRequest wrapper for the GetDedicatedVmHost operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetDedicatedVmHost.go.html to see an example of how to use GetDedicatedVmHostRequest. +type GetDedicatedVmHostRequest struct { + + // The OCID of the dedicated VM host. + DedicatedVmHostId *string `mandatory:"true" contributesTo:"path" name:"dedicatedVmHostId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetDedicatedVmHostRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetDedicatedVmHostRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetDedicatedVmHostRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetDedicatedVmHostRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetDedicatedVmHostResponse wrapper for the GetDedicatedVmHost operation +type GetDedicatedVmHostResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DedicatedVmHost instance + DedicatedVmHost `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetDedicatedVmHostResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetDedicatedVmHostResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_dhcp_options_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_dhcp_options_request_response.go new file mode 100644 index 000000000..28b207cc6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_dhcp_options_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetDhcpOptionsRequest wrapper for the GetDhcpOptions operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetDhcpOptions.go.html to see an example of how to use GetDhcpOptionsRequest. +type GetDhcpOptionsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) for the set of DHCP options. + DhcpId *string `mandatory:"true" contributesTo:"path" name:"dhcpId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetDhcpOptionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetDhcpOptionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetDhcpOptionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetDhcpOptionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetDhcpOptionsResponse wrapper for the GetDhcpOptions operation +type GetDhcpOptionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DhcpOptions instance + DhcpOptions `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetDhcpOptionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetDhcpOptionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_attachment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_attachment_request_response.go new file mode 100644 index 000000000..8bcfacadf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_attachment_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetDrgAttachmentRequest wrapper for the GetDrgAttachment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetDrgAttachment.go.html to see an example of how to use GetDrgAttachmentRequest. +type GetDrgAttachmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG attachment. + DrgAttachmentId *string `mandatory:"true" contributesTo:"path" name:"drgAttachmentId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetDrgAttachmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetDrgAttachmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetDrgAttachmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetDrgAttachmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetDrgAttachmentResponse wrapper for the GetDrgAttachment operation +type GetDrgAttachmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DrgAttachment instance + DrgAttachment `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetDrgAttachmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetDrgAttachmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_redundancy_status_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_redundancy_status_request_response.go new file mode 100644 index 000000000..e8a955545 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_redundancy_status_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetDrgRedundancyStatusRequest wrapper for the GetDrgRedundancyStatus operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetDrgRedundancyStatus.go.html to see an example of how to use GetDrgRedundancyStatusRequest. +type GetDrgRedundancyStatusRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"true" contributesTo:"path" name:"drgId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetDrgRedundancyStatusRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetDrgRedundancyStatusRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetDrgRedundancyStatusRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetDrgRedundancyStatusRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetDrgRedundancyStatusResponse wrapper for the GetDrgRedundancyStatus operation +type GetDrgRedundancyStatusResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DrgRedundancyStatus instance + DrgRedundancyStatus `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetDrgRedundancyStatusResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetDrgRedundancyStatusResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_request_response.go new file mode 100644 index 000000000..20a42a1ef --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetDrgRequest wrapper for the GetDrg operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetDrg.go.html to see an example of how to use GetDrgRequest. +type GetDrgRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"true" contributesTo:"path" name:"drgId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetDrgRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetDrgRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetDrgRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetDrgRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetDrgResponse wrapper for the GetDrg operation +type GetDrgResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Drg instance + Drg `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetDrgResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetDrgResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_route_distribution_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_route_distribution_request_response.go new file mode 100644 index 000000000..b440fe74f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_route_distribution_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetDrgRouteDistributionRequest wrapper for the GetDrgRouteDistribution operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetDrgRouteDistribution.go.html to see an example of how to use GetDrgRouteDistributionRequest. +type GetDrgRouteDistributionRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route distribution. + DrgRouteDistributionId *string `mandatory:"true" contributesTo:"path" name:"drgRouteDistributionId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetDrgRouteDistributionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetDrgRouteDistributionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetDrgRouteDistributionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetDrgRouteDistributionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetDrgRouteDistributionResponse wrapper for the GetDrgRouteDistribution operation +type GetDrgRouteDistributionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DrgRouteDistribution instance + DrgRouteDistribution `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetDrgRouteDistributionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetDrgRouteDistributionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_route_table_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_route_table_request_response.go new file mode 100644 index 000000000..5326506fd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_drg_route_table_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetDrgRouteTableRequest wrapper for the GetDrgRouteTable operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetDrgRouteTable.go.html to see an example of how to use GetDrgRouteTableRequest. +type GetDrgRouteTableRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG route table. + DrgRouteTableId *string `mandatory:"true" contributesTo:"path" name:"drgRouteTableId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetDrgRouteTableRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetDrgRouteTableRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetDrgRouteTableRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetDrgRouteTableRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetDrgRouteTableResponse wrapper for the GetDrgRouteTable operation +type GetDrgRouteTableResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DrgRouteTable instance + DrgRouteTable `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetDrgRouteTableResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetDrgRouteTableResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_fast_connect_provider_service_key_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_fast_connect_provider_service_key_request_response.go new file mode 100644 index 000000000..0ad8acfeb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_fast_connect_provider_service_key_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetFastConnectProviderServiceKeyRequest wrapper for the GetFastConnectProviderServiceKey operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetFastConnectProviderServiceKey.go.html to see an example of how to use GetFastConnectProviderServiceKeyRequest. +type GetFastConnectProviderServiceKeyRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the provider service. + ProviderServiceId *string `mandatory:"true" contributesTo:"path" name:"providerServiceId"` + + // The provider service key that the provider gives you when you set up a virtual circuit connection + // from the provider to Oracle Cloud Infrastructure. You can set up that connection and get your + // provider service key at the provider's website or portal. For the portal location, see the `description` + // attribute of the FastConnectProviderService. + ProviderServiceKeyName *string `mandatory:"true" contributesTo:"path" name:"providerServiceKeyName"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetFastConnectProviderServiceKeyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetFastConnectProviderServiceKeyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetFastConnectProviderServiceKeyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetFastConnectProviderServiceKeyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetFastConnectProviderServiceKeyResponse wrapper for the GetFastConnectProviderServiceKey operation +type GetFastConnectProviderServiceKeyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The FastConnectProviderServiceKey instance + FastConnectProviderServiceKey `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetFastConnectProviderServiceKeyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetFastConnectProviderServiceKeyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_fast_connect_provider_service_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_fast_connect_provider_service_request_response.go new file mode 100644 index 000000000..7c5be587e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_fast_connect_provider_service_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetFastConnectProviderServiceRequest wrapper for the GetFastConnectProviderService operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetFastConnectProviderService.go.html to see an example of how to use GetFastConnectProviderServiceRequest. +type GetFastConnectProviderServiceRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the provider service. + ProviderServiceId *string `mandatory:"true" contributesTo:"path" name:"providerServiceId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetFastConnectProviderServiceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetFastConnectProviderServiceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetFastConnectProviderServiceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetFastConnectProviderServiceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetFastConnectProviderServiceResponse wrapper for the GetFastConnectProviderService operation +type GetFastConnectProviderServiceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The FastConnectProviderService instance + FastConnectProviderService `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetFastConnectProviderServiceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetFastConnectProviderServiceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_device_config_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_device_config_request_response.go new file mode 100644 index 000000000..729f2ee3e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_device_config_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetIPSecConnectionDeviceConfigRequest wrapper for the GetIPSecConnectionDeviceConfig operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIPSecConnectionDeviceConfig.go.html to see an example of how to use GetIPSecConnectionDeviceConfigRequest. +type GetIPSecConnectionDeviceConfigRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetIPSecConnectionDeviceConfigRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetIPSecConnectionDeviceConfigRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetIPSecConnectionDeviceConfigRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetIPSecConnectionDeviceConfigRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetIPSecConnectionDeviceConfigResponse wrapper for the GetIPSecConnectionDeviceConfig operation +type GetIPSecConnectionDeviceConfigResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IpSecConnectionDeviceConfig instance + IpSecConnectionDeviceConfig `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetIPSecConnectionDeviceConfigResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetIPSecConnectionDeviceConfigResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_device_status_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_device_status_request_response.go new file mode 100644 index 000000000..209a5079b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_device_status_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetIPSecConnectionDeviceStatusRequest wrapper for the GetIPSecConnectionDeviceStatus operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIPSecConnectionDeviceStatus.go.html to see an example of how to use GetIPSecConnectionDeviceStatusRequest. +type GetIPSecConnectionDeviceStatusRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetIPSecConnectionDeviceStatusRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetIPSecConnectionDeviceStatusRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetIPSecConnectionDeviceStatusRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetIPSecConnectionDeviceStatusRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetIPSecConnectionDeviceStatusResponse wrapper for the GetIPSecConnectionDeviceStatus operation +type GetIPSecConnectionDeviceStatusResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IpSecConnectionDeviceStatus instance + IpSecConnectionDeviceStatus `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetIPSecConnectionDeviceStatusResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetIPSecConnectionDeviceStatusResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_request_response.go new file mode 100644 index 000000000..d96d8c42c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetIPSecConnectionRequest wrapper for the GetIPSecConnection operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIPSecConnection.go.html to see an example of how to use GetIPSecConnectionRequest. +type GetIPSecConnectionRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetIPSecConnectionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetIPSecConnectionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetIPSecConnectionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetIPSecConnectionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetIPSecConnectionResponse wrapper for the GetIPSecConnection operation +type GetIPSecConnectionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IpSecConnection instance + IpSecConnection `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetIPSecConnectionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetIPSecConnectionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_tunnel_error_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_tunnel_error_request_response.go new file mode 100644 index 000000000..3b4130877 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_tunnel_error_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetIPSecConnectionTunnelErrorRequest wrapper for the GetIPSecConnectionTunnelError operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIPSecConnectionTunnelError.go.html to see an example of how to use GetIPSecConnectionTunnelErrorRequest. +type GetIPSecConnectionTunnelErrorRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the tunnel. + TunnelId *string `mandatory:"true" contributesTo:"path" name:"tunnelId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetIPSecConnectionTunnelErrorRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetIPSecConnectionTunnelErrorRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetIPSecConnectionTunnelErrorRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetIPSecConnectionTunnelErrorRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetIPSecConnectionTunnelErrorResponse wrapper for the GetIPSecConnectionTunnelError operation +type GetIPSecConnectionTunnelErrorResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IpSecConnectionTunnelErrorDetails instance + IpSecConnectionTunnelErrorDetails `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetIPSecConnectionTunnelErrorResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetIPSecConnectionTunnelErrorResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_tunnel_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_tunnel_request_response.go new file mode 100644 index 000000000..f2291309b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_tunnel_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetIPSecConnectionTunnelRequest wrapper for the GetIPSecConnectionTunnel operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIPSecConnectionTunnel.go.html to see an example of how to use GetIPSecConnectionTunnelRequest. +type GetIPSecConnectionTunnelRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the tunnel. + TunnelId *string `mandatory:"true" contributesTo:"path" name:"tunnelId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetIPSecConnectionTunnelRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetIPSecConnectionTunnelRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetIPSecConnectionTunnelRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetIPSecConnectionTunnelRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetIPSecConnectionTunnelResponse wrapper for the GetIPSecConnectionTunnel operation +type GetIPSecConnectionTunnelResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IpSecConnectionTunnel instance + IpSecConnectionTunnel `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetIPSecConnectionTunnelResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetIPSecConnectionTunnelResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_tunnel_shared_secret_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_tunnel_shared_secret_request_response.go new file mode 100644 index 000000000..cf0937775 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_i_p_sec_connection_tunnel_shared_secret_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetIPSecConnectionTunnelSharedSecretRequest wrapper for the GetIPSecConnectionTunnelSharedSecret operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIPSecConnectionTunnelSharedSecret.go.html to see an example of how to use GetIPSecConnectionTunnelSharedSecretRequest. +type GetIPSecConnectionTunnelSharedSecretRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the tunnel. + TunnelId *string `mandatory:"true" contributesTo:"path" name:"tunnelId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetIPSecConnectionTunnelSharedSecretRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetIPSecConnectionTunnelSharedSecretRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetIPSecConnectionTunnelSharedSecretRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetIPSecConnectionTunnelSharedSecretRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetIPSecConnectionTunnelSharedSecretResponse wrapper for the GetIPSecConnectionTunnelSharedSecret operation +type GetIPSecConnectionTunnelSharedSecretResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IpSecConnectionTunnelSharedSecret instance + IpSecConnectionTunnelSharedSecret `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetIPSecConnectionTunnelSharedSecretResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetIPSecConnectionTunnelSharedSecretResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_image_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_image_request_response.go new file mode 100644 index 000000000..2c95e96fa --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_image_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetImageRequest wrapper for the GetImage operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetImage.go.html to see an example of how to use GetImageRequest. +type GetImageRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the image. + ImageId *string `mandatory:"true" contributesTo:"path" name:"imageId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetImageRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetImageRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetImageRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetImageRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetImageResponse wrapper for the GetImage operation +type GetImageResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Image instance + Image `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetImageResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetImageResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_image_shape_compatibility_entry_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_image_shape_compatibility_entry_request_response.go new file mode 100644 index 000000000..33bbacb84 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_image_shape_compatibility_entry_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetImageShapeCompatibilityEntryRequest wrapper for the GetImageShapeCompatibilityEntry operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetImageShapeCompatibilityEntry.go.html to see an example of how to use GetImageShapeCompatibilityEntryRequest. +type GetImageShapeCompatibilityEntryRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the image. + ImageId *string `mandatory:"true" contributesTo:"path" name:"imageId"` + + // Shape name. + ShapeName *string `mandatory:"true" contributesTo:"path" name:"shapeName"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetImageShapeCompatibilityEntryRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetImageShapeCompatibilityEntryRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetImageShapeCompatibilityEntryRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetImageShapeCompatibilityEntryRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetImageShapeCompatibilityEntryResponse wrapper for the GetImageShapeCompatibilityEntry operation +type GetImageShapeCompatibilityEntryResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ImageShapeCompatibilityEntry instance + ImageShapeCompatibilityEntry `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetImageShapeCompatibilityEntryResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetImageShapeCompatibilityEntryResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_configuration_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_configuration_request_response.go new file mode 100644 index 000000000..1e6a1b43d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_configuration_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetInstanceConfigurationRequest wrapper for the GetInstanceConfiguration operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetInstanceConfiguration.go.html to see an example of how to use GetInstanceConfigurationRequest. +type GetInstanceConfigurationRequest struct { + + // The OCID of the instance configuration. + InstanceConfigurationId *string `mandatory:"true" contributesTo:"path" name:"instanceConfigurationId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetInstanceConfigurationRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetInstanceConfigurationRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetInstanceConfigurationRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetInstanceConfigurationRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetInstanceConfigurationResponse wrapper for the GetInstanceConfiguration operation +type GetInstanceConfigurationResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstanceConfiguration instance + InstanceConfiguration `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetInstanceConfigurationResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetInstanceConfigurationResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_console_connection_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_console_connection_request_response.go new file mode 100644 index 000000000..6322221ad --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_console_connection_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetInstanceConsoleConnectionRequest wrapper for the GetInstanceConsoleConnection operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetInstanceConsoleConnection.go.html to see an example of how to use GetInstanceConsoleConnectionRequest. +type GetInstanceConsoleConnectionRequest struct { + + // The OCID of the instance console connection. + InstanceConsoleConnectionId *string `mandatory:"true" contributesTo:"path" name:"instanceConsoleConnectionId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetInstanceConsoleConnectionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetInstanceConsoleConnectionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetInstanceConsoleConnectionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetInstanceConsoleConnectionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetInstanceConsoleConnectionResponse wrapper for the GetInstanceConsoleConnection operation +type GetInstanceConsoleConnectionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstanceConsoleConnection instance + InstanceConsoleConnection `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetInstanceConsoleConnectionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetInstanceConsoleConnectionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_pool_instance_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_pool_instance_request_response.go new file mode 100644 index 000000000..891d2d173 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_pool_instance_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetInstancePoolInstanceRequest wrapper for the GetInstancePoolInstance operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetInstancePoolInstance.go.html to see an example of how to use GetInstancePoolInstanceRequest. +type GetInstancePoolInstanceRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" contributesTo:"path" name:"instancePoolId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance. + InstanceId *string `mandatory:"true" contributesTo:"path" name:"instanceId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetInstancePoolInstanceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetInstancePoolInstanceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetInstancePoolInstanceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetInstancePoolInstanceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetInstancePoolInstanceResponse wrapper for the GetInstancePoolInstance operation +type GetInstancePoolInstanceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstancePoolInstance instance + InstancePoolInstance `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetInstancePoolInstanceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetInstancePoolInstanceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_pool_load_balancer_attachment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_pool_load_balancer_attachment_request_response.go new file mode 100644 index 000000000..ffc0ef93a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_pool_load_balancer_attachment_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetInstancePoolLoadBalancerAttachmentRequest wrapper for the GetInstancePoolLoadBalancerAttachment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetInstancePoolLoadBalancerAttachment.go.html to see an example of how to use GetInstancePoolLoadBalancerAttachmentRequest. +type GetInstancePoolLoadBalancerAttachmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" contributesTo:"path" name:"instancePoolId"` + + // The OCID of the load balancer attachment. + InstancePoolLoadBalancerAttachmentId *string `mandatory:"true" contributesTo:"path" name:"instancePoolLoadBalancerAttachmentId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetInstancePoolLoadBalancerAttachmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetInstancePoolLoadBalancerAttachmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetInstancePoolLoadBalancerAttachmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetInstancePoolLoadBalancerAttachmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetInstancePoolLoadBalancerAttachmentResponse wrapper for the GetInstancePoolLoadBalancerAttachment operation +type GetInstancePoolLoadBalancerAttachmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstancePoolLoadBalancerAttachment instance + InstancePoolLoadBalancerAttachment `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetInstancePoolLoadBalancerAttachmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetInstancePoolLoadBalancerAttachmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_pool_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_pool_request_response.go new file mode 100644 index 000000000..02aeae91e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_pool_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetInstancePoolRequest wrapper for the GetInstancePool operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetInstancePool.go.html to see an example of how to use GetInstancePoolRequest. +type GetInstancePoolRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" contributesTo:"path" name:"instancePoolId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetInstancePoolRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetInstancePoolRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetInstancePoolRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetInstancePoolRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetInstancePoolResponse wrapper for the GetInstancePool operation +type GetInstancePoolResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstancePool instance + InstancePool `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetInstancePoolResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetInstancePoolResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_request_response.go new file mode 100644 index 000000000..209207369 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_instance_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetInstanceRequest wrapper for the GetInstance operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetInstance.go.html to see an example of how to use GetInstanceRequest. +type GetInstanceRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance. + InstanceId *string `mandatory:"true" contributesTo:"path" name:"instanceId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetInstanceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetInstanceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetInstanceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetInstanceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetInstanceResponse wrapper for the GetInstance operation +type GetInstanceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Instance instance + Instance `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetInstanceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetInstanceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_internet_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_internet_gateway_request_response.go new file mode 100644 index 000000000..b17a65376 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_internet_gateway_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetInternetGatewayRequest wrapper for the GetInternetGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetInternetGateway.go.html to see an example of how to use GetInternetGatewayRequest. +type GetInternetGatewayRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the internet gateway. + IgId *string `mandatory:"true" contributesTo:"path" name:"igId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetInternetGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetInternetGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetInternetGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetInternetGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetInternetGatewayResponse wrapper for the GetInternetGateway operation +type GetInternetGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InternetGateway instance + InternetGateway `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetInternetGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetInternetGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_ipsec_cpe_device_config_content_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_ipsec_cpe_device_config_content_request_response.go new file mode 100644 index 000000000..8de5a2b6c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_ipsec_cpe_device_config_content_request_response.go @@ -0,0 +1,75 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "io" + "net/http" +) + +// GetIpsecCpeDeviceConfigContentRequest wrapper for the GetIpsecCpeDeviceConfigContent operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIpsecCpeDeviceConfigContent.go.html to see an example of how to use GetIpsecCpeDeviceConfigContentRequest. +type GetIpsecCpeDeviceConfigContentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetIpsecCpeDeviceConfigContentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetIpsecCpeDeviceConfigContentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetIpsecCpeDeviceConfigContentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetIpsecCpeDeviceConfigContentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetIpsecCpeDeviceConfigContentResponse wrapper for the GetIpsecCpeDeviceConfigContent operation +type GetIpsecCpeDeviceConfigContentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The io.ReadCloser instance + Content io.ReadCloser `presentIn:"body" encoding:"binary"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetIpsecCpeDeviceConfigContentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetIpsecCpeDeviceConfigContentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_ipv6_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_ipv6_request_response.go new file mode 100644 index 000000000..d422540d5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_ipv6_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetIpv6Request wrapper for the GetIpv6 operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetIpv6.go.html to see an example of how to use GetIpv6Request. +type GetIpv6Request struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the IPv6. + Ipv6Id *string `mandatory:"true" contributesTo:"path" name:"ipv6Id"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetIpv6Request) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetIpv6Request) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetIpv6Request) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetIpv6Request) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetIpv6Response wrapper for the GetIpv6 operation +type GetIpv6Response struct { + + // The underlying http response + RawResponse *http.Response + + // The Ipv6 instance + Ipv6 `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetIpv6Response) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetIpv6Response) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_local_peering_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_local_peering_gateway_request_response.go new file mode 100644 index 000000000..eec9ea497 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_local_peering_gateway_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetLocalPeeringGatewayRequest wrapper for the GetLocalPeeringGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetLocalPeeringGateway.go.html to see an example of how to use GetLocalPeeringGatewayRequest. +type GetLocalPeeringGatewayRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the local peering gateway. + LocalPeeringGatewayId *string `mandatory:"true" contributesTo:"path" name:"localPeeringGatewayId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetLocalPeeringGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetLocalPeeringGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetLocalPeeringGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetLocalPeeringGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetLocalPeeringGatewayResponse wrapper for the GetLocalPeeringGateway operation +type GetLocalPeeringGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The LocalPeeringGateway instance + LocalPeeringGateway `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetLocalPeeringGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetLocalPeeringGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_measured_boot_report_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_measured_boot_report_request_response.go new file mode 100644 index 000000000..783ae9310 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_measured_boot_report_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetMeasuredBootReportRequest wrapper for the GetMeasuredBootReport operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetMeasuredBootReport.go.html to see an example of how to use GetMeasuredBootReportRequest. +type GetMeasuredBootReportRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance. + InstanceId *string `mandatory:"true" contributesTo:"path" name:"instanceId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetMeasuredBootReportRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetMeasuredBootReportRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetMeasuredBootReportRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetMeasuredBootReportRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetMeasuredBootReportResponse wrapper for the GetMeasuredBootReport operation +type GetMeasuredBootReportResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The MeasuredBootReport instance + MeasuredBootReport `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetMeasuredBootReportResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetMeasuredBootReportResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_nat_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_nat_gateway_request_response.go new file mode 100644 index 000000000..3754bcbed --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_nat_gateway_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetNatGatewayRequest wrapper for the GetNatGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetNatGateway.go.html to see an example of how to use GetNatGatewayRequest. +type GetNatGatewayRequest struct { + + // The NAT gateway's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + NatGatewayId *string `mandatory:"true" contributesTo:"path" name:"natGatewayId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetNatGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetNatGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetNatGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetNatGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetNatGatewayResponse wrapper for the GetNatGateway operation +type GetNatGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The NatGateway instance + NatGateway `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetNatGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetNatGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_network_security_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_network_security_group_request_response.go new file mode 100644 index 000000000..1d1bd3c55 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_network_security_group_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetNetworkSecurityGroupRequest wrapper for the GetNetworkSecurityGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetNetworkSecurityGroup.go.html to see an example of how to use GetNetworkSecurityGroupRequest. +type GetNetworkSecurityGroupRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network security group. + NetworkSecurityGroupId *string `mandatory:"true" contributesTo:"path" name:"networkSecurityGroupId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetNetworkSecurityGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetNetworkSecurityGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetNetworkSecurityGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetNetworkSecurityGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetNetworkSecurityGroupResponse wrapper for the GetNetworkSecurityGroup operation +type GetNetworkSecurityGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The NetworkSecurityGroup instance + NetworkSecurityGroup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetNetworkSecurityGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetNetworkSecurityGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_networking_topology_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_networking_topology_request_response.go new file mode 100644 index 000000000..8fedb861b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_networking_topology_request_response.go @@ -0,0 +1,125 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetNetworkingTopologyRequest wrapper for the GetNetworkingTopology operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetNetworkingTopology.go.html to see an example of how to use GetNetworkingTopologyRequest. +type GetNetworkingTopologyRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // Valid values are `ANY` and `ACCESSIBLE`. The default is `ANY`. + // Setting this to `ACCESSIBLE` returns only compartments for which a + // user has INSPECT permissions, either directly or indirectly (permissions can be on a + // resource in a subcompartment). A restricted set of fields is returned for compartments in which a user has + // indirect INSPECT permissions. + // When set to `ANY` permissions are not checked. + AccessLevel GetNetworkingTopologyAccessLevelEnum `mandatory:"false" contributesTo:"query" name:"accessLevel" omitEmpty:"true"` + + // When set to true, the hierarchy of compartments is traversed + // and the specified compartment and its subcompartments are + // inspected depending on the the setting of `accessLevel`. + // Default is false. + QueryCompartmentSubtree *bool `mandatory:"false" contributesTo:"query" name:"queryCompartmentSubtree"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // For querying if there is a cached value on the server. The If-None-Match HTTP request header + // makes the request conditional. For GET and HEAD methods, the server will send back the requested + // resource, with a 200 status, only if it doesn't have an ETag matching the given ones. + // For other methods, the request will be processed only if the eventually existing resource's + // ETag doesn't match any of the values listed. + IfNoneMatch *string `mandatory:"false" contributesTo:"header" name:"if-none-match"` + + // The Cache-Control HTTP header holds directives (instructions) + // for caching in both requests and responses. + CacheControl *string `mandatory:"false" contributesTo:"header" name:"cache-control"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetNetworkingTopologyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetNetworkingTopologyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetNetworkingTopologyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetNetworkingTopologyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetNetworkingTopologyResponse wrapper for the GetNetworkingTopology operation +type GetNetworkingTopologyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The NetworkingTopology instance + NetworkingTopology `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetNetworkingTopologyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetNetworkingTopologyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// GetNetworkingTopologyAccessLevelEnum Enum with underlying type: string +type GetNetworkingTopologyAccessLevelEnum string + +// Set of constants representing the allowable values for GetNetworkingTopologyAccessLevelEnum +const ( + GetNetworkingTopologyAccessLevelAny GetNetworkingTopologyAccessLevelEnum = "ANY" + GetNetworkingTopologyAccessLevelAccessible GetNetworkingTopologyAccessLevelEnum = "ACCESSIBLE" +) + +var mappingGetNetworkingTopologyAccessLevel = map[string]GetNetworkingTopologyAccessLevelEnum{ + "ANY": GetNetworkingTopologyAccessLevelAny, + "ACCESSIBLE": GetNetworkingTopologyAccessLevelAccessible, +} + +// GetGetNetworkingTopologyAccessLevelEnumValues Enumerates the set of values for GetNetworkingTopologyAccessLevelEnum +func GetGetNetworkingTopologyAccessLevelEnumValues() []GetNetworkingTopologyAccessLevelEnum { + values := make([]GetNetworkingTopologyAccessLevelEnum, 0) + for _, v := range mappingGetNetworkingTopologyAccessLevel { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_private_ip_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_private_ip_request_response.go new file mode 100644 index 000000000..7cb7edeba --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_private_ip_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetPrivateIpRequest wrapper for the GetPrivateIp operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetPrivateIp.go.html to see an example of how to use GetPrivateIpRequest. +type GetPrivateIpRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the private IP. + PrivateIpId *string `mandatory:"true" contributesTo:"path" name:"privateIpId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetPrivateIpRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetPrivateIpRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetPrivateIpRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetPrivateIpRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetPrivateIpResponse wrapper for the GetPrivateIp operation +type GetPrivateIpResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The PrivateIp instance + PrivateIp `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetPrivateIpResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetPrivateIpResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_ip_address_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_ip_address_details.go new file mode 100644 index 000000000..5b17f65f5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_ip_address_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// GetPublicIpByIpAddressDetails IP address of the public IP. +type GetPublicIpByIpAddressDetails struct { + + // The public IP address. + // Example: 203.0.113.2 + IpAddress *string `mandatory:"true" json:"ipAddress"` +} + +func (m GetPublicIpByIpAddressDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_ip_address_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_ip_address_request_response.go new file mode 100644 index 000000000..444ef0681 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_ip_address_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetPublicIpByIpAddressRequest wrapper for the GetPublicIpByIpAddress operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetPublicIpByIpAddress.go.html to see an example of how to use GetPublicIpByIpAddressRequest. +type GetPublicIpByIpAddressRequest struct { + + // IP address details for fetching the public IP. + GetPublicIpByIpAddressDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetPublicIpByIpAddressRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetPublicIpByIpAddressRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetPublicIpByIpAddressRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetPublicIpByIpAddressRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetPublicIpByIpAddressResponse wrapper for the GetPublicIpByIpAddress operation +type GetPublicIpByIpAddressResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The PublicIp instance + PublicIp `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetPublicIpByIpAddressResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetPublicIpByIpAddressResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_private_ip_id_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_private_ip_id_details.go new file mode 100644 index 000000000..b7095f44b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_private_ip_id_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// GetPublicIpByPrivateIpIdDetails Details of the private IP that the public IP is assigned to. +type GetPublicIpByPrivateIpIdDetails struct { + + // OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the private IP. + PrivateIpId *string `mandatory:"true" json:"privateIpId"` +} + +func (m GetPublicIpByPrivateIpIdDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_private_ip_id_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_private_ip_id_request_response.go new file mode 100644 index 000000000..6fda26ca4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_by_private_ip_id_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetPublicIpByPrivateIpIdRequest wrapper for the GetPublicIpByPrivateIpId operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetPublicIpByPrivateIpId.go.html to see an example of how to use GetPublicIpByPrivateIpIdRequest. +type GetPublicIpByPrivateIpIdRequest struct { + + // Private IP details for fetching the public IP. + GetPublicIpByPrivateIpIdDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetPublicIpByPrivateIpIdRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetPublicIpByPrivateIpIdRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetPublicIpByPrivateIpIdRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetPublicIpByPrivateIpIdRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetPublicIpByPrivateIpIdResponse wrapper for the GetPublicIpByPrivateIpId operation +type GetPublicIpByPrivateIpIdResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The PublicIp instance + PublicIp `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetPublicIpByPrivateIpIdResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetPublicIpByPrivateIpIdResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_pool_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_pool_request_response.go new file mode 100644 index 000000000..6a4178ebd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_pool_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetPublicIpPoolRequest wrapper for the GetPublicIpPool operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetPublicIpPool.go.html to see an example of how to use GetPublicIpPoolRequest. +type GetPublicIpPoolRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the public IP pool. + PublicIpPoolId *string `mandatory:"true" contributesTo:"path" name:"publicIpPoolId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetPublicIpPoolRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetPublicIpPoolRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetPublicIpPoolRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetPublicIpPoolRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetPublicIpPoolResponse wrapper for the GetPublicIpPool operation +type GetPublicIpPoolResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The PublicIpPool instance + PublicIpPool `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetPublicIpPoolResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetPublicIpPoolResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_request_response.go new file mode 100644 index 000000000..8c32bba14 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_public_ip_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetPublicIpRequest wrapper for the GetPublicIp operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetPublicIp.go.html to see an example of how to use GetPublicIpRequest. +type GetPublicIpRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the public IP. + PublicIpId *string `mandatory:"true" contributesTo:"path" name:"publicIpId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetPublicIpRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetPublicIpRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetPublicIpRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetPublicIpRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetPublicIpResponse wrapper for the GetPublicIp operation +type GetPublicIpResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The PublicIp instance + PublicIp `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetPublicIpResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetPublicIpResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_remote_peering_connection_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_remote_peering_connection_request_response.go new file mode 100644 index 000000000..d0a349e5f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_remote_peering_connection_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetRemotePeeringConnectionRequest wrapper for the GetRemotePeeringConnection operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetRemotePeeringConnection.go.html to see an example of how to use GetRemotePeeringConnectionRequest. +type GetRemotePeeringConnectionRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the remote peering connection (RPC). + RemotePeeringConnectionId *string `mandatory:"true" contributesTo:"path" name:"remotePeeringConnectionId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetRemotePeeringConnectionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetRemotePeeringConnectionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetRemotePeeringConnectionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetRemotePeeringConnectionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetRemotePeeringConnectionResponse wrapper for the GetRemotePeeringConnection operation +type GetRemotePeeringConnectionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The RemotePeeringConnection instance + RemotePeeringConnection `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetRemotePeeringConnectionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetRemotePeeringConnectionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_route_table_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_route_table_request_response.go new file mode 100644 index 000000000..6386922a2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_route_table_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetRouteTableRequest wrapper for the GetRouteTable operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetRouteTable.go.html to see an example of how to use GetRouteTableRequest. +type GetRouteTableRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the route table. + RtId *string `mandatory:"true" contributesTo:"path" name:"rtId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetRouteTableRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetRouteTableRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetRouteTableRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetRouteTableRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetRouteTableResponse wrapper for the GetRouteTable operation +type GetRouteTableResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The RouteTable instance + RouteTable `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetRouteTableResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetRouteTableResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_security_list_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_security_list_request_response.go new file mode 100644 index 000000000..184c447ca --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_security_list_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetSecurityListRequest wrapper for the GetSecurityList operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetSecurityList.go.html to see an example of how to use GetSecurityListRequest. +type GetSecurityListRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the security list. + SecurityListId *string `mandatory:"true" contributesTo:"path" name:"securityListId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetSecurityListRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetSecurityListRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetSecurityListRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetSecurityListRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetSecurityListResponse wrapper for the GetSecurityList operation +type GetSecurityListResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The SecurityList instance + SecurityList `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetSecurityListResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetSecurityListResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_service_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_service_gateway_request_response.go new file mode 100644 index 000000000..543975bf9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_service_gateway_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetServiceGatewayRequest wrapper for the GetServiceGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetServiceGateway.go.html to see an example of how to use GetServiceGatewayRequest. +type GetServiceGatewayRequest struct { + + // The service gateway's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + ServiceGatewayId *string `mandatory:"true" contributesTo:"path" name:"serviceGatewayId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetServiceGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetServiceGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetServiceGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetServiceGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetServiceGatewayResponse wrapper for the GetServiceGateway operation +type GetServiceGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ServiceGateway instance + ServiceGateway `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetServiceGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetServiceGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_service_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_service_request_response.go new file mode 100644 index 000000000..f0fee3807 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_service_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetServiceRequest wrapper for the GetService operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetService.go.html to see an example of how to use GetServiceRequest. +type GetServiceRequest struct { + + // The service's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + ServiceId *string `mandatory:"true" contributesTo:"path" name:"serviceId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetServiceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetServiceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetServiceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetServiceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetServiceResponse wrapper for the GetService operation +type GetServiceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Service instance + Service `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetServiceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetServiceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_subnet_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_subnet_request_response.go new file mode 100644 index 000000000..87ca3af05 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_subnet_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetSubnetRequest wrapper for the GetSubnet operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetSubnet.go.html to see an example of how to use GetSubnetRequest. +type GetSubnetRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the subnet. + SubnetId *string `mandatory:"true" contributesTo:"path" name:"subnetId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetSubnetRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetSubnetRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetSubnetRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetSubnetRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetSubnetResponse wrapper for the GetSubnet operation +type GetSubnetResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Subnet instance + Subnet `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetSubnetResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetSubnetResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_subnet_topology_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_subnet_topology_request_response.go new file mode 100644 index 000000000..5ed3d043c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_subnet_topology_request_response.go @@ -0,0 +1,128 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetSubnetTopologyRequest wrapper for the GetSubnetTopology operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetSubnetTopology.go.html to see an example of how to use GetSubnetTopologyRequest. +type GetSubnetTopologyRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the subnet. + SubnetId *string `mandatory:"true" contributesTo:"query" name:"subnetId"` + + // Valid values are `ANY` and `ACCESSIBLE`. The default is `ANY`. + // Setting this to `ACCESSIBLE` returns only compartments for which a + // user has INSPECT permissions, either directly or indirectly (permissions can be on a + // resource in a subcompartment). A restricted set of fields is returned for compartments in which a user has + // indirect INSPECT permissions. + // When set to `ANY` permissions are not checked. + AccessLevel GetSubnetTopologyAccessLevelEnum `mandatory:"false" contributesTo:"query" name:"accessLevel" omitEmpty:"true"` + + // When set to true, the hierarchy of compartments is traversed + // and the specified compartment and its subcompartments are + // inspected depending on the the setting of `accessLevel`. + // Default is false. + QueryCompartmentSubtree *bool `mandatory:"false" contributesTo:"query" name:"queryCompartmentSubtree"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // For querying if there is a cached value on the server. The If-None-Match HTTP request header + // makes the request conditional. For GET and HEAD methods, the server will send back the requested + // resource, with a 200 status, only if it doesn't have an ETag matching the given ones. + // For other methods, the request will be processed only if the eventually existing resource's + // ETag doesn't match any of the values listed. + IfNoneMatch *string `mandatory:"false" contributesTo:"header" name:"if-none-match"` + + // The Cache-Control HTTP header holds directives (instructions) + // for caching in both requests and responses. + CacheControl *string `mandatory:"false" contributesTo:"header" name:"cache-control"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetSubnetTopologyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetSubnetTopologyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetSubnetTopologyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetSubnetTopologyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetSubnetTopologyResponse wrapper for the GetSubnetTopology operation +type GetSubnetTopologyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The SubnetTopology instance + SubnetTopology `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetSubnetTopologyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetSubnetTopologyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// GetSubnetTopologyAccessLevelEnum Enum with underlying type: string +type GetSubnetTopologyAccessLevelEnum string + +// Set of constants representing the allowable values for GetSubnetTopologyAccessLevelEnum +const ( + GetSubnetTopologyAccessLevelAny GetSubnetTopologyAccessLevelEnum = "ANY" + GetSubnetTopologyAccessLevelAccessible GetSubnetTopologyAccessLevelEnum = "ACCESSIBLE" +) + +var mappingGetSubnetTopologyAccessLevel = map[string]GetSubnetTopologyAccessLevelEnum{ + "ANY": GetSubnetTopologyAccessLevelAny, + "ACCESSIBLE": GetSubnetTopologyAccessLevelAccessible, +} + +// GetGetSubnetTopologyAccessLevelEnumValues Enumerates the set of values for GetSubnetTopologyAccessLevelEnum +func GetGetSubnetTopologyAccessLevelEnumValues() []GetSubnetTopologyAccessLevelEnum { + values := make([]GetSubnetTopologyAccessLevelEnum, 0) + for _, v := range mappingGetSubnetTopologyAccessLevel { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_tunnel_cpe_device_config_content_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_tunnel_cpe_device_config_content_request_response.go new file mode 100644 index 000000000..0532ff4d9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_tunnel_cpe_device_config_content_request_response.go @@ -0,0 +1,78 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "io" + "net/http" +) + +// GetTunnelCpeDeviceConfigContentRequest wrapper for the GetTunnelCpeDeviceConfigContent operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetTunnelCpeDeviceConfigContent.go.html to see an example of how to use GetTunnelCpeDeviceConfigContentRequest. +type GetTunnelCpeDeviceConfigContentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the tunnel. + TunnelId *string `mandatory:"true" contributesTo:"path" name:"tunnelId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetTunnelCpeDeviceConfigContentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetTunnelCpeDeviceConfigContentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetTunnelCpeDeviceConfigContentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetTunnelCpeDeviceConfigContentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetTunnelCpeDeviceConfigContentResponse wrapper for the GetTunnelCpeDeviceConfigContent operation +type GetTunnelCpeDeviceConfigContentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The io.ReadCloser instance + Content io.ReadCloser `presentIn:"body" encoding:"binary"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetTunnelCpeDeviceConfigContentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetTunnelCpeDeviceConfigContentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_tunnel_cpe_device_config_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_tunnel_cpe_device_config_request_response.go new file mode 100644 index 000000000..20e65152b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_tunnel_cpe_device_config_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetTunnelCpeDeviceConfigRequest wrapper for the GetTunnelCpeDeviceConfig operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetTunnelCpeDeviceConfig.go.html to see an example of how to use GetTunnelCpeDeviceConfigRequest. +type GetTunnelCpeDeviceConfigRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the tunnel. + TunnelId *string `mandatory:"true" contributesTo:"path" name:"tunnelId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetTunnelCpeDeviceConfigRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetTunnelCpeDeviceConfigRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetTunnelCpeDeviceConfigRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetTunnelCpeDeviceConfigRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetTunnelCpeDeviceConfigResponse wrapper for the GetTunnelCpeDeviceConfig operation +type GetTunnelCpeDeviceConfigResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The TunnelCpeDeviceConfig instance + TunnelCpeDeviceConfig `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetTunnelCpeDeviceConfigResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetTunnelCpeDeviceConfigResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_upgrade_status_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_upgrade_status_request_response.go new file mode 100644 index 000000000..4ffa8eac6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_upgrade_status_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetUpgradeStatusRequest wrapper for the GetUpgradeStatus operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetUpgradeStatus.go.html to see an example of how to use GetUpgradeStatusRequest. +type GetUpgradeStatusRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"true" contributesTo:"path" name:"drgId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetUpgradeStatusRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetUpgradeStatusRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetUpgradeStatusRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetUpgradeStatusRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetUpgradeStatusResponse wrapper for the GetUpgradeStatus operation +type GetUpgradeStatusResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The UpgradeStatus instance + UpgradeStatus `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetUpgradeStatusResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetUpgradeStatusResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vcn_dns_resolver_association_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vcn_dns_resolver_association_request_response.go new file mode 100644 index 000000000..cf84fed9a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vcn_dns_resolver_association_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVcnDnsResolverAssociationRequest wrapper for the GetVcnDnsResolverAssociation operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVcnDnsResolverAssociation.go.html to see an example of how to use GetVcnDnsResolverAssociationRequest. +type GetVcnDnsResolverAssociationRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"true" contributesTo:"path" name:"vcnId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVcnDnsResolverAssociationRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVcnDnsResolverAssociationRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVcnDnsResolverAssociationRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVcnDnsResolverAssociationRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVcnDnsResolverAssociationResponse wrapper for the GetVcnDnsResolverAssociation operation +type GetVcnDnsResolverAssociationResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VcnDnsResolverAssociation instance + VcnDnsResolverAssociation `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVcnDnsResolverAssociationResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVcnDnsResolverAssociationResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vcn_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vcn_request_response.go new file mode 100644 index 000000000..bc3fda421 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vcn_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVcnRequest wrapper for the GetVcn operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVcn.go.html to see an example of how to use GetVcnRequest. +type GetVcnRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"true" contributesTo:"path" name:"vcnId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVcnRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVcnRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVcnRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVcnRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVcnResponse wrapper for the GetVcn operation +type GetVcnResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Vcn instance + Vcn `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVcnResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVcnResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vcn_topology_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vcn_topology_request_response.go new file mode 100644 index 000000000..b3243e7fe --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vcn_topology_request_response.go @@ -0,0 +1,128 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVcnTopologyRequest wrapper for the GetVcnTopology operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVcnTopology.go.html to see an example of how to use GetVcnTopologyRequest. +type GetVcnTopologyRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"true" contributesTo:"query" name:"vcnId"` + + // Valid values are `ANY` and `ACCESSIBLE`. The default is `ANY`. + // Setting this to `ACCESSIBLE` returns only compartments for which a + // user has INSPECT permissions, either directly or indirectly (permissions can be on a + // resource in a subcompartment). A restricted set of fields is returned for compartments in which a user has + // indirect INSPECT permissions. + // When set to `ANY` permissions are not checked. + AccessLevel GetVcnTopologyAccessLevelEnum `mandatory:"false" contributesTo:"query" name:"accessLevel" omitEmpty:"true"` + + // When set to true, the hierarchy of compartments is traversed + // and the specified compartment and its subcompartments are + // inspected depending on the the setting of `accessLevel`. + // Default is false. + QueryCompartmentSubtree *bool `mandatory:"false" contributesTo:"query" name:"queryCompartmentSubtree"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // For querying if there is a cached value on the server. The If-None-Match HTTP request header + // makes the request conditional. For GET and HEAD methods, the server will send back the requested + // resource, with a 200 status, only if it doesn't have an ETag matching the given ones. + // For other methods, the request will be processed only if the eventually existing resource's + // ETag doesn't match any of the values listed. + IfNoneMatch *string `mandatory:"false" contributesTo:"header" name:"if-none-match"` + + // The Cache-Control HTTP header holds directives (instructions) + // for caching in both requests and responses. + CacheControl *string `mandatory:"false" contributesTo:"header" name:"cache-control"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVcnTopologyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVcnTopologyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVcnTopologyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVcnTopologyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVcnTopologyResponse wrapper for the GetVcnTopology operation +type GetVcnTopologyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VcnTopology instance + VcnTopology `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVcnTopologyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVcnTopologyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// GetVcnTopologyAccessLevelEnum Enum with underlying type: string +type GetVcnTopologyAccessLevelEnum string + +// Set of constants representing the allowable values for GetVcnTopologyAccessLevelEnum +const ( + GetVcnTopologyAccessLevelAny GetVcnTopologyAccessLevelEnum = "ANY" + GetVcnTopologyAccessLevelAccessible GetVcnTopologyAccessLevelEnum = "ACCESSIBLE" +) + +var mappingGetVcnTopologyAccessLevel = map[string]GetVcnTopologyAccessLevelEnum{ + "ANY": GetVcnTopologyAccessLevelAny, + "ACCESSIBLE": GetVcnTopologyAccessLevelAccessible, +} + +// GetGetVcnTopologyAccessLevelEnumValues Enumerates the set of values for GetVcnTopologyAccessLevelEnum +func GetGetVcnTopologyAccessLevelEnumValues() []GetVcnTopologyAccessLevelEnum { + values := make([]GetVcnTopologyAccessLevelEnum, 0) + for _, v := range mappingGetVcnTopologyAccessLevel { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_virtual_circuit_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_virtual_circuit_request_response.go new file mode 100644 index 000000000..d4f7db2ac --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_virtual_circuit_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVirtualCircuitRequest wrapper for the GetVirtualCircuit operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVirtualCircuit.go.html to see an example of how to use GetVirtualCircuitRequest. +type GetVirtualCircuitRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the virtual circuit. + VirtualCircuitId *string `mandatory:"true" contributesTo:"path" name:"virtualCircuitId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVirtualCircuitRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVirtualCircuitRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVirtualCircuitRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVirtualCircuitRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVirtualCircuitResponse wrapper for the GetVirtualCircuit operation +type GetVirtualCircuitResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VirtualCircuit instance + VirtualCircuit `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVirtualCircuitResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVirtualCircuitResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vlan_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vlan_request_response.go new file mode 100644 index 000000000..5a8329b3b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vlan_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVlanRequest wrapper for the GetVlan operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVlan.go.html to see an example of how to use GetVlanRequest. +type GetVlanRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VLAN. + VlanId *string `mandatory:"true" contributesTo:"path" name:"vlanId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVlanRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVlanRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVlanRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVlanRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVlanResponse wrapper for the GetVlan operation +type GetVlanResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Vlan instance + Vlan `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVlanResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVlanResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vnic_attachment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vnic_attachment_request_response.go new file mode 100644 index 000000000..1c8506d66 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vnic_attachment_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVnicAttachmentRequest wrapper for the GetVnicAttachment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVnicAttachment.go.html to see an example of how to use GetVnicAttachmentRequest. +type GetVnicAttachmentRequest struct { + + // The OCID of the VNIC attachment. + VnicAttachmentId *string `mandatory:"true" contributesTo:"path" name:"vnicAttachmentId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVnicAttachmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVnicAttachmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVnicAttachmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVnicAttachmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVnicAttachmentResponse wrapper for the GetVnicAttachment operation +type GetVnicAttachmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VnicAttachment instance + VnicAttachment `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVnicAttachmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVnicAttachmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vnic_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vnic_request_response.go new file mode 100644 index 000000000..e7854b3da --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_vnic_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVnicRequest wrapper for the GetVnic operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVnic.go.html to see an example of how to use GetVnicRequest. +type GetVnicRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the VNIC. + VnicId *string `mandatory:"true" contributesTo:"path" name:"vnicId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVnicRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVnicRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVnicRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVnicRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVnicResponse wrapper for the GetVnic operation +type GetVnicResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Vnic instance + Vnic `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVnicResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVnicResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_attachment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_attachment_request_response.go new file mode 100644 index 000000000..b39f36d7d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_attachment_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVolumeAttachmentRequest wrapper for the GetVolumeAttachment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeAttachment.go.html to see an example of how to use GetVolumeAttachmentRequest. +type GetVolumeAttachmentRequest struct { + + // The OCID of the volume attachment. + VolumeAttachmentId *string `mandatory:"true" contributesTo:"path" name:"volumeAttachmentId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVolumeAttachmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVolumeAttachmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVolumeAttachmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVolumeAttachmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVolumeAttachmentResponse wrapper for the GetVolumeAttachment operation +type GetVolumeAttachmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeAttachment instance + VolumeAttachment `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVolumeAttachmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVolumeAttachmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_policy_asset_assignment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_policy_asset_assignment_request_response.go new file mode 100644 index 000000000..f0e655290 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_policy_asset_assignment_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVolumeBackupPolicyAssetAssignmentRequest wrapper for the GetVolumeBackupPolicyAssetAssignment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeBackupPolicyAssetAssignment.go.html to see an example of how to use GetVolumeBackupPolicyAssetAssignmentRequest. +type GetVolumeBackupPolicyAssetAssignmentRequest struct { + + // The OCID of an asset (e.g. a volume). + AssetId *string `mandatory:"true" contributesTo:"query" name:"assetId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVolumeBackupPolicyAssetAssignmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVolumeBackupPolicyAssetAssignmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVolumeBackupPolicyAssetAssignmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVolumeBackupPolicyAssetAssignmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVolumeBackupPolicyAssetAssignmentResponse wrapper for the GetVolumeBackupPolicyAssetAssignment operation +type GetVolumeBackupPolicyAssetAssignmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []VolumeBackupPolicyAssignment instances + Items []VolumeBackupPolicyAssignment `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVolumeBackupPolicyAssetAssignmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVolumeBackupPolicyAssetAssignmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_policy_assignment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_policy_assignment_request_response.go new file mode 100644 index 000000000..9949d9948 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_policy_assignment_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVolumeBackupPolicyAssignmentRequest wrapper for the GetVolumeBackupPolicyAssignment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeBackupPolicyAssignment.go.html to see an example of how to use GetVolumeBackupPolicyAssignmentRequest. +type GetVolumeBackupPolicyAssignmentRequest struct { + + // The OCID of the volume backup policy assignment. + PolicyAssignmentId *string `mandatory:"true" contributesTo:"path" name:"policyAssignmentId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVolumeBackupPolicyAssignmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVolumeBackupPolicyAssignmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVolumeBackupPolicyAssignmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVolumeBackupPolicyAssignmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVolumeBackupPolicyAssignmentResponse wrapper for the GetVolumeBackupPolicyAssignment operation +type GetVolumeBackupPolicyAssignmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeBackupPolicyAssignment instance + VolumeBackupPolicyAssignment `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVolumeBackupPolicyAssignmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVolumeBackupPolicyAssignmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_policy_request_response.go new file mode 100644 index 000000000..c98f95293 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_policy_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVolumeBackupPolicyRequest wrapper for the GetVolumeBackupPolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeBackupPolicy.go.html to see an example of how to use GetVolumeBackupPolicyRequest. +type GetVolumeBackupPolicyRequest struct { + + // The OCID of the volume backup policy. + PolicyId *string `mandatory:"true" contributesTo:"path" name:"policyId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVolumeBackupPolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVolumeBackupPolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVolumeBackupPolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVolumeBackupPolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVolumeBackupPolicyResponse wrapper for the GetVolumeBackupPolicy operation +type GetVolumeBackupPolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeBackupPolicy instance + VolumeBackupPolicy `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVolumeBackupPolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVolumeBackupPolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_request_response.go new file mode 100644 index 000000000..b708c816a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_backup_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVolumeBackupRequest wrapper for the GetVolumeBackup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeBackup.go.html to see an example of how to use GetVolumeBackupRequest. +type GetVolumeBackupRequest struct { + + // The OCID of the volume backup. + VolumeBackupId *string `mandatory:"true" contributesTo:"path" name:"volumeBackupId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVolumeBackupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVolumeBackupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVolumeBackupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVolumeBackupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVolumeBackupResponse wrapper for the GetVolumeBackup operation +type GetVolumeBackupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeBackup instance + VolumeBackup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVolumeBackupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVolumeBackupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_group_backup_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_group_backup_request_response.go new file mode 100644 index 000000000..301377b6c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_group_backup_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVolumeGroupBackupRequest wrapper for the GetVolumeGroupBackup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeGroupBackup.go.html to see an example of how to use GetVolumeGroupBackupRequest. +type GetVolumeGroupBackupRequest struct { + + // The Oracle Cloud ID (OCID) that uniquely identifies the volume group backup. + VolumeGroupBackupId *string `mandatory:"true" contributesTo:"path" name:"volumeGroupBackupId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVolumeGroupBackupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVolumeGroupBackupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVolumeGroupBackupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVolumeGroupBackupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVolumeGroupBackupResponse wrapper for the GetVolumeGroupBackup operation +type GetVolumeGroupBackupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeGroupBackup instance + VolumeGroupBackup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVolumeGroupBackupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVolumeGroupBackupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_group_request_response.go new file mode 100644 index 000000000..c7ff580ff --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_group_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVolumeGroupRequest wrapper for the GetVolumeGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeGroup.go.html to see an example of how to use GetVolumeGroupRequest. +type GetVolumeGroupRequest struct { + + // The Oracle Cloud ID (OCID) that uniquely identifies the volume group. + VolumeGroupId *string `mandatory:"true" contributesTo:"path" name:"volumeGroupId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVolumeGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVolumeGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVolumeGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVolumeGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVolumeGroupResponse wrapper for the GetVolumeGroup operation +type GetVolumeGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeGroup instance + VolumeGroup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVolumeGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVolumeGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_kms_key_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_kms_key_request_response.go new file mode 100644 index 000000000..a8ec9df7b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_kms_key_request_response.go @@ -0,0 +1,82 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVolumeKmsKeyRequest wrapper for the GetVolumeKmsKey operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolumeKmsKey.go.html to see an example of how to use GetVolumeKmsKeyRequest. +type GetVolumeKmsKeyRequest struct { + + // The OCID of the volume. + VolumeId *string `mandatory:"true" contributesTo:"path" name:"volumeId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVolumeKmsKeyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVolumeKmsKeyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVolumeKmsKeyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVolumeKmsKeyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVolumeKmsKeyResponse wrapper for the GetVolumeKmsKey operation +type GetVolumeKmsKeyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeKmsKey instance + VolumeKmsKey `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVolumeKmsKeyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVolumeKmsKeyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_request_response.go new file mode 100644 index 000000000..969c31689 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_volume_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetVolumeRequest wrapper for the GetVolume operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetVolume.go.html to see an example of how to use GetVolumeRequest. +type GetVolumeRequest struct { + + // The OCID of the volume. + VolumeId *string `mandatory:"true" contributesTo:"path" name:"volumeId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetVolumeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetVolumeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetVolumeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetVolumeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetVolumeResponse wrapper for the GetVolume operation +type GetVolumeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Volume instance + Volume `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetVolumeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetVolumeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/get_windows_instance_initial_credentials_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_windows_instance_initial_credentials_request_response.go new file mode 100644 index 000000000..7986da0c7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/get_windows_instance_initial_credentials_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetWindowsInstanceInitialCredentialsRequest wrapper for the GetWindowsInstanceInitialCredentials operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/GetWindowsInstanceInitialCredentials.go.html to see an example of how to use GetWindowsInstanceInitialCredentialsRequest. +type GetWindowsInstanceInitialCredentialsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance. + InstanceId *string `mandatory:"true" contributesTo:"path" name:"instanceId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetWindowsInstanceInitialCredentialsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetWindowsInstanceInitialCredentialsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetWindowsInstanceInitialCredentialsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetWindowsInstanceInitialCredentialsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetWindowsInstanceInitialCredentialsResponse wrapper for the GetWindowsInstanceInitialCredentials operation +type GetWindowsInstanceInitialCredentialsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstanceCredentials instance + InstanceCredentials `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetWindowsInstanceInitialCredentialsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetWindowsInstanceInitialCredentialsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/i_scsi_volume_attachment.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/i_scsi_volume_attachment.go new file mode 100644 index 000000000..019e966b6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/i_scsi_volume_attachment.go @@ -0,0 +1,190 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IScsiVolumeAttachment An ISCSI volume attachment. +type IScsiVolumeAttachment struct { + + // The availability domain of an instance. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the volume attachment. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the instance the volume is attached to. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // The date and time the volume was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID of the volume. + VolumeId *string `mandatory:"true" json:"volumeId"` + + // The volume's iSCSI IP address. + // Example: `169.254.0.2` + Ipv4 *string `mandatory:"true" json:"ipv4"` + + // The target volume's iSCSI Qualified Name in the format defined + // by RFC 3720 (https://tools.ietf.org/html/rfc3720#page-32). + // Example: `iqn.2015-12.us.oracle.com:` + Iqn *string `mandatory:"true" json:"iqn"` + + // The volume's iSCSI port, usually port 860 or 3260. + // Example: `3260` + Port *int `mandatory:"true" json:"port"` + + // The device name. + Device *string `mandatory:"false" json:"device"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Whether the attachment was created in read-only mode. + IsReadOnly *bool `mandatory:"false" json:"isReadOnly"` + + // Whether the attachment should be created in shareable mode. If an attachment + // is created in shareable mode, then other instances can attach the same volume, provided + // that they also create their attachments in shareable mode. Only certain volume types can + // be attached in shareable mode. Defaults to false if not specified. + IsShareable *bool `mandatory:"false" json:"isShareable"` + + // Whether in-transit encryption for the data volume's paravirtualized attachment is enabled or not. + IsPvEncryptionInTransitEnabled *bool `mandatory:"false" json:"isPvEncryptionInTransitEnabled"` + + // Whether the attachment is multipath or not. + IsMultipath *bool `mandatory:"false" json:"isMultipath"` + + // The Challenge-Handshake-Authentication-Protocol (CHAP) secret + // valid for the associated CHAP user name. + // (Also called the "CHAP password".) + ChapSecret *string `mandatory:"false" json:"chapSecret"` + + // The volume's system-generated Challenge-Handshake-Authentication-Protocol + // (CHAP) user name. See RFC 1994 (https://tools.ietf.org/html/rfc1994) for more on CHAP. + // Example: `ocid1.volume.oc1.phx.` + ChapUsername *string `mandatory:"false" json:"chapUsername"` + + // A list of secondary multipath devices + MultipathDevices []MultipathDevice `mandatory:"false" json:"multipathDevices"` + + // The current state of the volume attachment. + LifecycleState VolumeAttachmentLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The iscsi login state of the volume attachment. For a multipath volume attachment, + // all iscsi sessions need to be all logged-in or logged-out to be in logged-in or logged-out state. + IscsiLoginState VolumeAttachmentIscsiLoginStateEnum `mandatory:"false" json:"iscsiLoginState,omitempty"` + + // Refer the top-level definition of encryptionInTransitType. + // The default value is NONE. + EncryptionInTransitType EncryptionInTransitTypeEnum `mandatory:"false" json:"encryptionInTransitType,omitempty"` +} + +//GetAvailabilityDomain returns AvailabilityDomain +func (m IScsiVolumeAttachment) GetAvailabilityDomain() *string { + return m.AvailabilityDomain +} + +//GetCompartmentId returns CompartmentId +func (m IScsiVolumeAttachment) GetCompartmentId() *string { + return m.CompartmentId +} + +//GetDevice returns Device +func (m IScsiVolumeAttachment) GetDevice() *string { + return m.Device +} + +//GetDisplayName returns DisplayName +func (m IScsiVolumeAttachment) GetDisplayName() *string { + return m.DisplayName +} + +//GetId returns Id +func (m IScsiVolumeAttachment) GetId() *string { + return m.Id +} + +//GetInstanceId returns InstanceId +func (m IScsiVolumeAttachment) GetInstanceId() *string { + return m.InstanceId +} + +//GetIsReadOnly returns IsReadOnly +func (m IScsiVolumeAttachment) GetIsReadOnly() *bool { + return m.IsReadOnly +} + +//GetIsShareable returns IsShareable +func (m IScsiVolumeAttachment) GetIsShareable() *bool { + return m.IsShareable +} + +//GetLifecycleState returns LifecycleState +func (m IScsiVolumeAttachment) GetLifecycleState() VolumeAttachmentLifecycleStateEnum { + return m.LifecycleState +} + +//GetTimeCreated returns TimeCreated +func (m IScsiVolumeAttachment) GetTimeCreated() *common.SDKTime { + return m.TimeCreated +} + +//GetVolumeId returns VolumeId +func (m IScsiVolumeAttachment) GetVolumeId() *string { + return m.VolumeId +} + +//GetIsPvEncryptionInTransitEnabled returns IsPvEncryptionInTransitEnabled +func (m IScsiVolumeAttachment) GetIsPvEncryptionInTransitEnabled() *bool { + return m.IsPvEncryptionInTransitEnabled +} + +//GetIsMultipath returns IsMultipath +func (m IScsiVolumeAttachment) GetIsMultipath() *bool { + return m.IsMultipath +} + +//GetIscsiLoginState returns IscsiLoginState +func (m IScsiVolumeAttachment) GetIscsiLoginState() VolumeAttachmentIscsiLoginStateEnum { + return m.IscsiLoginState +} + +func (m IScsiVolumeAttachment) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m IScsiVolumeAttachment) MarshalJSON() (buff []byte, e error) { + type MarshalTypeIScsiVolumeAttachment IScsiVolumeAttachment + s := struct { + DiscriminatorParam string `json:"attachmentType"` + MarshalTypeIScsiVolumeAttachment + }{ + "iscsi", + (MarshalTypeIScsiVolumeAttachment)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/icmp_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/icmp_options.go new file mode 100644 index 000000000..2fe887c1d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/icmp_options.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IcmpOptions Optional and valid only for ICMP and ICMPv6. Use to specify a particular ICMP type and code +// as defined in: +// - ICMP Parameters (http://www.iana.org/assignments/icmp-parameters/icmp-parameters.xhtml) +// - ICMPv6 Parameters (https://www.iana.org/assignments/icmpv6-parameters/icmpv6-parameters.xhtml) +// If you specify ICMP or ICMPv6 as the protocol but omit this object, then all ICMP types and +// codes are allowed. If you do provide this object, the type is required and the code is optional. +// To enable MTU negotiation for ingress internet traffic via IPv4, make sure to allow type 3 ("Destination +// Unreachable") code 4 ("Fragmentation Needed and Don't Fragment was Set"). If you need to specify +// multiple codes for a single type, create a separate security list rule for each. +type IcmpOptions struct { + + // The ICMP type. + Type *int `mandatory:"true" json:"type"` + + // The ICMP code (optional). + Code *int `mandatory:"false" json:"code"` +} + +func (m IcmpOptions) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/image.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/image.go new file mode 100644 index 000000000..5fa82ccf1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/image.go @@ -0,0 +1,180 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Image A boot disk image for launching an instance. For more information, see +// Overview of the Compute Service (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you +// supply string values using the API. +type Image struct { + + // The OCID of the compartment containing the instance you want to use as the basis for the image. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // Whether instances launched with this image can be used to create new images. + // For example, you cannot create an image of an Oracle Database instance. + // Example: `true` + CreateImageAllowed *bool `mandatory:"true" json:"createImageAllowed"` + + // The OCID of the image. + Id *string `mandatory:"true" json:"id"` + + LifecycleState ImageLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The image's operating system. + // Example: `Oracle Linux` + OperatingSystem *string `mandatory:"true" json:"operatingSystem"` + + // The image's operating system version. + // Example: `7.2` + OperatingSystemVersion *string `mandatory:"true" json:"operatingSystemVersion"` + + // The date and time the image was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID of the image originally used to launch the instance. + BaseImageId *string `mandatory:"false" json:"baseImageId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name for the image. It does not have to be unique, and it's changeable. + // Avoid entering confidential information. + // You cannot use a platform image name as a custom image name. + // Example: `My custom Oracle Linux image` + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Specifies the configuration mode for launching virtual machine (VM) instances. The configuration modes are: + // * `NATIVE` - VM instances launch with iSCSI boot and VFIO devices. The default value for platform images. + // * `EMULATED` - VM instances launch with emulated devices, such as the E1000 network driver and emulated SCSI disk controller. + // * `PARAVIRTUALIZED` - VM instances launch with paravirtualized devices using VirtIO drivers. + // * `CUSTOM` - VM instances launch with custom configuration settings specified in the `LaunchOptions` parameter. + LaunchMode ImageLaunchModeEnum `mandatory:"false" json:"launchMode,omitempty"` + + LaunchOptions *LaunchOptions `mandatory:"false" json:"launchOptions"` + + AgentFeatures *InstanceAgentFeatures `mandatory:"false" json:"agentFeatures"` + + // The listing type of the image. The default value is "NONE". + ListingType ImageListingTypeEnum `mandatory:"false" json:"listingType,omitempty"` + + // The boot volume size for an instance launched from this image (1 MB = 1,048,576 bytes). + // Note this is not the same as the size of the image when it was exported or the actual size of the image. + // Example: `47694` + SizeInMBs *int64 `mandatory:"false" json:"sizeInMBs"` + + // The size of the internal storage for this image that is subject to billing (1 GB = 1,073,741,824 bytes). + // Example: `100` + BillableSizeInGBs *int64 `mandatory:"false" json:"billableSizeInGBs"` +} + +func (m Image) String() string { + return common.PointerString(m) +} + +// ImageLaunchModeEnum Enum with underlying type: string +type ImageLaunchModeEnum string + +// Set of constants representing the allowable values for ImageLaunchModeEnum +const ( + ImageLaunchModeNative ImageLaunchModeEnum = "NATIVE" + ImageLaunchModeEmulated ImageLaunchModeEnum = "EMULATED" + ImageLaunchModeParavirtualized ImageLaunchModeEnum = "PARAVIRTUALIZED" + ImageLaunchModeCustom ImageLaunchModeEnum = "CUSTOM" +) + +var mappingImageLaunchMode = map[string]ImageLaunchModeEnum{ + "NATIVE": ImageLaunchModeNative, + "EMULATED": ImageLaunchModeEmulated, + "PARAVIRTUALIZED": ImageLaunchModeParavirtualized, + "CUSTOM": ImageLaunchModeCustom, +} + +// GetImageLaunchModeEnumValues Enumerates the set of values for ImageLaunchModeEnum +func GetImageLaunchModeEnumValues() []ImageLaunchModeEnum { + values := make([]ImageLaunchModeEnum, 0) + for _, v := range mappingImageLaunchMode { + values = append(values, v) + } + return values +} + +// ImageLifecycleStateEnum Enum with underlying type: string +type ImageLifecycleStateEnum string + +// Set of constants representing the allowable values for ImageLifecycleStateEnum +const ( + ImageLifecycleStateProvisioning ImageLifecycleStateEnum = "PROVISIONING" + ImageLifecycleStateImporting ImageLifecycleStateEnum = "IMPORTING" + ImageLifecycleStateAvailable ImageLifecycleStateEnum = "AVAILABLE" + ImageLifecycleStateExporting ImageLifecycleStateEnum = "EXPORTING" + ImageLifecycleStateDisabled ImageLifecycleStateEnum = "DISABLED" + ImageLifecycleStateDeleted ImageLifecycleStateEnum = "DELETED" +) + +var mappingImageLifecycleState = map[string]ImageLifecycleStateEnum{ + "PROVISIONING": ImageLifecycleStateProvisioning, + "IMPORTING": ImageLifecycleStateImporting, + "AVAILABLE": ImageLifecycleStateAvailable, + "EXPORTING": ImageLifecycleStateExporting, + "DISABLED": ImageLifecycleStateDisabled, + "DELETED": ImageLifecycleStateDeleted, +} + +// GetImageLifecycleStateEnumValues Enumerates the set of values for ImageLifecycleStateEnum +func GetImageLifecycleStateEnumValues() []ImageLifecycleStateEnum { + values := make([]ImageLifecycleStateEnum, 0) + for _, v := range mappingImageLifecycleState { + values = append(values, v) + } + return values +} + +// ImageListingTypeEnum Enum with underlying type: string +type ImageListingTypeEnum string + +// Set of constants representing the allowable values for ImageListingTypeEnum +const ( + ImageListingTypeCommunity ImageListingTypeEnum = "COMMUNITY" + ImageListingTypeNone ImageListingTypeEnum = "NONE" +) + +var mappingImageListingType = map[string]ImageListingTypeEnum{ + "COMMUNITY": ImageListingTypeCommunity, + "NONE": ImageListingTypeNone, +} + +// GetImageListingTypeEnumValues Enumerates the set of values for ImageListingTypeEnum +func GetImageListingTypeEnumValues() []ImageListingTypeEnum { + values := make([]ImageListingTypeEnum, 0) + for _, v := range mappingImageListingType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/image_capability_schema_descriptor.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_capability_schema_descriptor.go new file mode 100644 index 000000000..e79f971e3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_capability_schema_descriptor.go @@ -0,0 +1,105 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ImageCapabilitySchemaDescriptor Image Capability Schema Descriptor is a type of capability for an image. +type ImageCapabilitySchemaDescriptor interface { + GetSource() ImageCapabilitySchemaDescriptorSourceEnum +} + +type imagecapabilityschemadescriptor struct { + JsonData []byte + Source ImageCapabilitySchemaDescriptorSourceEnum `mandatory:"true" json:"source"` + DescriptorType string `json:"descriptorType"` +} + +// UnmarshalJSON unmarshals json +func (m *imagecapabilityschemadescriptor) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerimagecapabilityschemadescriptor imagecapabilityschemadescriptor + s := struct { + Model Unmarshalerimagecapabilityschemadescriptor + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.Source = s.Model.Source + m.DescriptorType = s.Model.DescriptorType + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *imagecapabilityschemadescriptor) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.DescriptorType { + case "enumstring": + mm := EnumStringImageCapabilitySchemaDescriptor{} + err = json.Unmarshal(data, &mm) + return mm, err + case "enuminteger": + mm := EnumIntegerImageCapabilityDescriptor{} + err = json.Unmarshal(data, &mm) + return mm, err + case "boolean": + mm := BooleanImageCapabilitySchemaDescriptor{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetSource returns Source +func (m imagecapabilityschemadescriptor) GetSource() ImageCapabilitySchemaDescriptorSourceEnum { + return m.Source +} + +func (m imagecapabilityschemadescriptor) String() string { + return common.PointerString(m) +} + +// ImageCapabilitySchemaDescriptorSourceEnum Enum with underlying type: string +type ImageCapabilitySchemaDescriptorSourceEnum string + +// Set of constants representing the allowable values for ImageCapabilitySchemaDescriptorSourceEnum +const ( + ImageCapabilitySchemaDescriptorSourceGlobal ImageCapabilitySchemaDescriptorSourceEnum = "GLOBAL" + ImageCapabilitySchemaDescriptorSourceImage ImageCapabilitySchemaDescriptorSourceEnum = "IMAGE" +) + +var mappingImageCapabilitySchemaDescriptorSource = map[string]ImageCapabilitySchemaDescriptorSourceEnum{ + "GLOBAL": ImageCapabilitySchemaDescriptorSourceGlobal, + "IMAGE": ImageCapabilitySchemaDescriptorSourceImage, +} + +// GetImageCapabilitySchemaDescriptorSourceEnumValues Enumerates the set of values for ImageCapabilitySchemaDescriptorSourceEnum +func GetImageCapabilitySchemaDescriptorSourceEnumValues() []ImageCapabilitySchemaDescriptorSourceEnum { + values := make([]ImageCapabilitySchemaDescriptorSourceEnum, 0) + for _, v := range mappingImageCapabilitySchemaDescriptorSource { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/image_memory_constraints.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_memory_constraints.go new file mode 100644 index 000000000..da524b977 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_memory_constraints.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ImageMemoryConstraints For a flexible image and shape, the amount of memory supported for instances that use this image. +type ImageMemoryConstraints struct { + + // The minimum amount of memory, in gigabytes. + MinInGBs *int `mandatory:"false" json:"minInGBs"` + + // The maximum amount of memory, in gigabytes. + MaxInGBs *int `mandatory:"false" json:"maxInGBs"` +} + +func (m ImageMemoryConstraints) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/image_ocpu_constraints.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_ocpu_constraints.go new file mode 100644 index 000000000..de1b51656 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_ocpu_constraints.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ImageOcpuConstraints OCPU options for an image and shape. +type ImageOcpuConstraints struct { + + // The minimum number of OCPUs supported for this image and shape. + Min *int `mandatory:"false" json:"min"` + + // The maximum number of OCPUs supported for this image and shape. + Max *int `mandatory:"false" json:"max"` +} + +func (m ImageOcpuConstraints) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/image_shape_compatibility_entry.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_shape_compatibility_entry.go new file mode 100644 index 000000000..33c324496 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_shape_compatibility_entry.go @@ -0,0 +1,36 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ImageShapeCompatibilityEntry An image and shape that are compatible. +type ImageShapeCompatibilityEntry struct { + + // The image OCID. + ImageId *string `mandatory:"true" json:"imageId"` + + // The shape name. + Shape *string `mandatory:"true" json:"shape"` + + MemoryConstraints *ImageMemoryConstraints `mandatory:"false" json:"memoryConstraints"` + + OcpuConstraints *ImageOcpuConstraints `mandatory:"false" json:"ocpuConstraints"` +} + +func (m ImageShapeCompatibilityEntry) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/image_shape_compatibility_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_shape_compatibility_summary.go new file mode 100644 index 000000000..ac0883563 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_shape_compatibility_summary.go @@ -0,0 +1,36 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ImageShapeCompatibilitySummary Summary information for a compatible image and shape. +type ImageShapeCompatibilitySummary struct { + + // The image OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + ImageId *string `mandatory:"true" json:"imageId"` + + // The shape name. + Shape *string `mandatory:"true" json:"shape"` + + MemoryConstraints *ImageMemoryConstraints `mandatory:"false" json:"memoryConstraints"` + + OcpuConstraints *ImageOcpuConstraints `mandatory:"false" json:"ocpuConstraints"` +} + +func (m ImageShapeCompatibilitySummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/image_source_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_source_details.go new file mode 100644 index 000000000..fe0d67946 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_source_details.go @@ -0,0 +1,121 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ImageSourceDetails The representation of ImageSourceDetails +type ImageSourceDetails interface { + GetOperatingSystem() *string + + GetOperatingSystemVersion() *string + + // The format of the image to be imported. Only monolithic + // images are supported. This attribute is not used for exported Oracle images with the OCI image format. + GetSourceImageType() ImageSourceDetailsSourceImageTypeEnum +} + +type imagesourcedetails struct { + JsonData []byte + OperatingSystem *string `mandatory:"false" json:"operatingSystem"` + OperatingSystemVersion *string `mandatory:"false" json:"operatingSystemVersion"` + SourceImageType ImageSourceDetailsSourceImageTypeEnum `mandatory:"false" json:"sourceImageType,omitempty"` + SourceType string `json:"sourceType"` +} + +// UnmarshalJSON unmarshals json +func (m *imagesourcedetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerimagesourcedetails imagesourcedetails + s := struct { + Model Unmarshalerimagesourcedetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.OperatingSystem = s.Model.OperatingSystem + m.OperatingSystemVersion = s.Model.OperatingSystemVersion + m.SourceImageType = s.Model.SourceImageType + m.SourceType = s.Model.SourceType + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *imagesourcedetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.SourceType { + case "objectStorageTuple": + mm := ImageSourceViaObjectStorageTupleDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "objectStorageUri": + mm := ImageSourceViaObjectStorageUriDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetOperatingSystem returns OperatingSystem +func (m imagesourcedetails) GetOperatingSystem() *string { + return m.OperatingSystem +} + +//GetOperatingSystemVersion returns OperatingSystemVersion +func (m imagesourcedetails) GetOperatingSystemVersion() *string { + return m.OperatingSystemVersion +} + +//GetSourceImageType returns SourceImageType +func (m imagesourcedetails) GetSourceImageType() ImageSourceDetailsSourceImageTypeEnum { + return m.SourceImageType +} + +func (m imagesourcedetails) String() string { + return common.PointerString(m) +} + +// ImageSourceDetailsSourceImageTypeEnum Enum with underlying type: string +type ImageSourceDetailsSourceImageTypeEnum string + +// Set of constants representing the allowable values for ImageSourceDetailsSourceImageTypeEnum +const ( + ImageSourceDetailsSourceImageTypeQcow2 ImageSourceDetailsSourceImageTypeEnum = "QCOW2" + ImageSourceDetailsSourceImageTypeVmdk ImageSourceDetailsSourceImageTypeEnum = "VMDK" +) + +var mappingImageSourceDetailsSourceImageType = map[string]ImageSourceDetailsSourceImageTypeEnum{ + "QCOW2": ImageSourceDetailsSourceImageTypeQcow2, + "VMDK": ImageSourceDetailsSourceImageTypeVmdk, +} + +// GetImageSourceDetailsSourceImageTypeEnumValues Enumerates the set of values for ImageSourceDetailsSourceImageTypeEnum +func GetImageSourceDetailsSourceImageTypeEnumValues() []ImageSourceDetailsSourceImageTypeEnum { + values := make([]ImageSourceDetailsSourceImageTypeEnum, 0) + for _, v := range mappingImageSourceDetailsSourceImageType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/image_source_via_object_storage_tuple_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_source_via_object_storage_tuple_details.go new file mode 100644 index 000000000..6d1d4b223 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_source_via_object_storage_tuple_details.go @@ -0,0 +1,73 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ImageSourceViaObjectStorageTupleDetails The representation of ImageSourceViaObjectStorageTupleDetails +type ImageSourceViaObjectStorageTupleDetails struct { + + // The Object Storage bucket for the image. + BucketName *string `mandatory:"true" json:"bucketName"` + + // The Object Storage namespace for the image. + NamespaceName *string `mandatory:"true" json:"namespaceName"` + + // The Object Storage name for the image. + ObjectName *string `mandatory:"true" json:"objectName"` + + OperatingSystem *string `mandatory:"false" json:"operatingSystem"` + + OperatingSystemVersion *string `mandatory:"false" json:"operatingSystemVersion"` + + // The format of the image to be imported. Only monolithic + // images are supported. This attribute is not used for exported Oracle images with the OCI image format. + SourceImageType ImageSourceDetailsSourceImageTypeEnum `mandatory:"false" json:"sourceImageType,omitempty"` +} + +//GetOperatingSystem returns OperatingSystem +func (m ImageSourceViaObjectStorageTupleDetails) GetOperatingSystem() *string { + return m.OperatingSystem +} + +//GetOperatingSystemVersion returns OperatingSystemVersion +func (m ImageSourceViaObjectStorageTupleDetails) GetOperatingSystemVersion() *string { + return m.OperatingSystemVersion +} + +//GetSourceImageType returns SourceImageType +func (m ImageSourceViaObjectStorageTupleDetails) GetSourceImageType() ImageSourceDetailsSourceImageTypeEnum { + return m.SourceImageType +} + +func (m ImageSourceViaObjectStorageTupleDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m ImageSourceViaObjectStorageTupleDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeImageSourceViaObjectStorageTupleDetails ImageSourceViaObjectStorageTupleDetails + s := struct { + DiscriminatorParam string `json:"sourceType"` + MarshalTypeImageSourceViaObjectStorageTupleDetails + }{ + "objectStorageTuple", + (MarshalTypeImageSourceViaObjectStorageTupleDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/image_source_via_object_storage_uri_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_source_via_object_storage_uri_details.go new file mode 100644 index 000000000..0640dee2b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/image_source_via_object_storage_uri_details.go @@ -0,0 +1,67 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ImageSourceViaObjectStorageUriDetails The representation of ImageSourceViaObjectStorageUriDetails +type ImageSourceViaObjectStorageUriDetails struct { + + // The Object Storage URL for the image. + SourceUri *string `mandatory:"true" json:"sourceUri"` + + OperatingSystem *string `mandatory:"false" json:"operatingSystem"` + + OperatingSystemVersion *string `mandatory:"false" json:"operatingSystemVersion"` + + // The format of the image to be imported. Only monolithic + // images are supported. This attribute is not used for exported Oracle images with the OCI image format. + SourceImageType ImageSourceDetailsSourceImageTypeEnum `mandatory:"false" json:"sourceImageType,omitempty"` +} + +//GetOperatingSystem returns OperatingSystem +func (m ImageSourceViaObjectStorageUriDetails) GetOperatingSystem() *string { + return m.OperatingSystem +} + +//GetOperatingSystemVersion returns OperatingSystemVersion +func (m ImageSourceViaObjectStorageUriDetails) GetOperatingSystemVersion() *string { + return m.OperatingSystemVersion +} + +//GetSourceImageType returns SourceImageType +func (m ImageSourceViaObjectStorageUriDetails) GetSourceImageType() ImageSourceDetailsSourceImageTypeEnum { + return m.SourceImageType +} + +func (m ImageSourceViaObjectStorageUriDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m ImageSourceViaObjectStorageUriDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeImageSourceViaObjectStorageUriDetails ImageSourceViaObjectStorageUriDetails + s := struct { + DiscriminatorParam string `json:"sourceType"` + MarshalTypeImageSourceViaObjectStorageUriDetails + }{ + "objectStorageUri", + (MarshalTypeImageSourceViaObjectStorageUriDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/ingress_security_rule.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/ingress_security_rule.go new file mode 100644 index 000000000..a25e1d33c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/ingress_security_rule.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IngressSecurityRule A rule for allowing inbound IP packets. +type IngressSecurityRule struct { + + // The transport protocol. Specify either `all` or an IPv4 protocol number as + // defined in + // Protocol Numbers (http://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml). + // Options are supported only for ICMP ("1"), TCP ("6"), UDP ("17"), and ICMPv6 ("58"). + Protocol *string `mandatory:"true" json:"protocol"` + + // Conceptually, this is the range of IP addresses that a packet coming into the instance + // can come from. + // Allowed values: + // * IP address range in CIDR notation. For example: `192.168.1.0/24` or `2001:0db8:0123:45::/56`. + // IPv6 addressing is supported for all commercial and government regions. See + // IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // * The `cidrBlock` value for a Service, if you're + // setting up a security list rule for traffic coming from a particular `Service` through + // a service gateway. For example: `oci-phx-objectstorage`. + Source *string `mandatory:"true" json:"source"` + + IcmpOptions *IcmpOptions `mandatory:"false" json:"icmpOptions"` + + // A stateless rule allows traffic in one direction. Remember to add a corresponding + // stateless rule in the other direction if you need to support bidirectional traffic. For + // example, if ingress traffic allows TCP destination port 80, there should be an egress + // rule to allow TCP source port 80. Defaults to false, which means the rule is stateful + // and a corresponding rule is not necessary for bidirectional traffic. + IsStateless *bool `mandatory:"false" json:"isStateless"` + + // Type of source for the rule. The default is `CIDR_BLOCK`. + // * `CIDR_BLOCK`: If the rule's `source` is an IP address range in CIDR notation. + // * `SERVICE_CIDR_BLOCK`: If the rule's `source` is the `cidrBlock` value for a + // Service (the rule is for traffic coming from a + // particular `Service` through a service gateway). + SourceType IngressSecurityRuleSourceTypeEnum `mandatory:"false" json:"sourceType,omitempty"` + + TcpOptions *TcpOptions `mandatory:"false" json:"tcpOptions"` + + UdpOptions *UdpOptions `mandatory:"false" json:"udpOptions"` + + // An optional description of your choice for the rule. + Description *string `mandatory:"false" json:"description"` +} + +func (m IngressSecurityRule) String() string { + return common.PointerString(m) +} + +// IngressSecurityRuleSourceTypeEnum Enum with underlying type: string +type IngressSecurityRuleSourceTypeEnum string + +// Set of constants representing the allowable values for IngressSecurityRuleSourceTypeEnum +const ( + IngressSecurityRuleSourceTypeCidrBlock IngressSecurityRuleSourceTypeEnum = "CIDR_BLOCK" + IngressSecurityRuleSourceTypeServiceCidrBlock IngressSecurityRuleSourceTypeEnum = "SERVICE_CIDR_BLOCK" +) + +var mappingIngressSecurityRuleSourceType = map[string]IngressSecurityRuleSourceTypeEnum{ + "CIDR_BLOCK": IngressSecurityRuleSourceTypeCidrBlock, + "SERVICE_CIDR_BLOCK": IngressSecurityRuleSourceTypeServiceCidrBlock, +} + +// GetIngressSecurityRuleSourceTypeEnumValues Enumerates the set of values for IngressSecurityRuleSourceTypeEnum +func GetIngressSecurityRuleSourceTypeEnumValues() []IngressSecurityRuleSourceTypeEnum { + values := make([]IngressSecurityRuleSourceTypeEnum, 0) + for _, v := range mappingIngressSecurityRuleSourceType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance.go new file mode 100644 index 000000000..2d0e3e331 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance.go @@ -0,0 +1,342 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Instance A compute host. The image used to launch the instance determines its operating system and other +// software. The shape specified during the launch process determines the number of CPUs and memory +// allocated to the instance. For more information, see +// Overview of the Compute Service (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you +// supply string values using the API. +type Instance struct { + + // The availability domain the instance is running in. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment that contains the instance. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the instance. + Id *string `mandatory:"true" json:"id"` + + // The current state of the instance. + LifecycleState InstanceLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The region that contains the availability domain the instance is running in. + // For the us-phoenix-1 and us-ashburn-1 regions, `phx` and `iad` are returned, respectively. + // For all other regions, the full region name is returned. + // Examples: `phx`, `eu-frankfurt-1` + Region *string `mandatory:"true" json:"region"` + + // The shape of the instance. The shape determines the number of CPUs and the amount of memory + // allocated to the instance. You can enumerate all available shapes by calling + // ListShapes. + Shape *string `mandatory:"true" json:"shape"` + + // The date and time the instance was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID of the compute capacity reservation this instance is launched under. + // When this field contains an empty string or is null, the instance is not currently in a capacity reservation. + // For more information, see Capacity Reservations (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/reserve-capacity.htm#default). + CapacityReservationId *string `mandatory:"false" json:"capacityReservationId"` + + // The OCID of dedicated VM host. + DedicatedVmHostId *string `mandatory:"false" json:"dedicatedVmHostId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Additional metadata key/value pairs that you provide. They serve the same purpose and functionality + // as fields in the `metadata` object. + // They are distinguished from `metadata` fields in that these can be nested JSON objects (whereas `metadata` + // fields are string/string maps only). + ExtendedMetadata map[string]interface{} `mandatory:"false" json:"extendedMetadata"` + + // The name of the fault domain the instance is running in. + // A fault domain is a grouping of hardware and infrastructure within an availability domain. + // Each availability domain contains three fault domains. Fault domains let you distribute your + // instances so that they are not on the same physical hardware within a single availability domain. + // A hardware failure or Compute hardware maintenance that affects one fault domain does not affect + // instances in other fault domains. + // If you do not specify the fault domain, the system selects one for you. + // Example: `FAULT-DOMAIN-1` + FaultDomain *string `mandatory:"false" json:"faultDomain"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Deprecated. Use `sourceDetails` instead. + ImageId *string `mandatory:"false" json:"imageId"` + + // When a bare metal or virtual machine + // instance boots, the iPXE firmware that runs on the instance is + // configured to run an iPXE script to continue the boot process. + // If you want more control over the boot process, you can provide + // your own custom iPXE script that will run when the instance boots. + // Be aware that the same iPXE script will run + // every time an instance boots, not only after the initial + // LaunchInstance call. + // The default iPXE script connects to the instance's local boot + // volume over iSCSI and performs a network boot. If you use a custom iPXE + // script and want to network-boot from the instance's local boot volume + // over iSCSI the same way as the default iPXE script, use the + // following iSCSI IP address: 169.254.0.2, and boot volume IQN: + // iqn.2015-02.oracle.boot. + // If your instance boot volume type is paravirtualized, + // the boot volume is attached to the instance through virtio-scsi and no iPXE script is used. + // If your instance boot volume type is paravirtualized + // and you use custom iPXE to network boot into your instance, + // the primary boot volume is attached as a data volume through virtio-scsi drive. + // For more information about the Bring Your Own Image feature of + // Oracle Cloud Infrastructure, see + // Bring Your Own Image (https://docs.cloud.oracle.com/iaas/Content/Compute/References/bringyourownimage.htm). + // For more information about iPXE, see http://ipxe.org. + IpxeScript *string `mandatory:"false" json:"ipxeScript"` + + // Specifies the configuration mode for launching virtual machine (VM) instances. The configuration modes are: + // * `NATIVE` - VM instances launch with iSCSI boot and VFIO devices. The default value for platform images. + // * `EMULATED` - VM instances launch with emulated devices, such as the E1000 network driver and emulated SCSI disk controller. + // * `PARAVIRTUALIZED` - VM instances launch with paravirtualized devices using VirtIO drivers. + // * `CUSTOM` - VM instances launch with custom configuration settings specified in the `LaunchOptions` parameter. + LaunchMode InstanceLaunchModeEnum `mandatory:"false" json:"launchMode,omitempty"` + + LaunchOptions *LaunchOptions `mandatory:"false" json:"launchOptions"` + + InstanceOptions *InstanceOptions `mandatory:"false" json:"instanceOptions"` + + AvailabilityConfig *InstanceAvailabilityConfig `mandatory:"false" json:"availabilityConfig"` + + PreemptibleInstanceConfig *PreemptibleInstanceConfigDetails `mandatory:"false" json:"preemptibleInstanceConfig"` + + // Custom metadata that you provide. + Metadata map[string]string `mandatory:"false" json:"metadata"` + + ShapeConfig *InstanceShapeConfig `mandatory:"false" json:"shapeConfig"` + + SourceDetails InstanceSourceDetails `mandatory:"false" json:"sourceDetails"` + + // System tags for this resource. Each key is predefined and scoped to a namespace. + // Example: `{"foo-namespace": {"bar-key": "value"}}` + SystemTags map[string]map[string]interface{} `mandatory:"false" json:"systemTags"` + + AgentConfig *InstanceAgentConfig `mandatory:"false" json:"agentConfig"` + + // The date and time the instance is expected to be stopped / started, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // After that time if instance hasn't been rebooted, Oracle will reboot the instance within 24 hours of the due time. + // Regardless of how the instance was stopped, the flag will be reset to empty as soon as instance reaches Stopped state. + // Example: `2018-05-25T21:10:29.600Z` + TimeMaintenanceRebootDue *common.SDKTime `mandatory:"false" json:"timeMaintenanceRebootDue"` + + PlatformConfig PlatformConfig `mandatory:"false" json:"platformConfig"` +} + +func (m Instance) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *Instance) UnmarshalJSON(data []byte) (e error) { + model := struct { + CapacityReservationId *string `json:"capacityReservationId"` + DedicatedVmHostId *string `json:"dedicatedVmHostId"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + DisplayName *string `json:"displayName"` + ExtendedMetadata map[string]interface{} `json:"extendedMetadata"` + FaultDomain *string `json:"faultDomain"` + FreeformTags map[string]string `json:"freeformTags"` + ImageId *string `json:"imageId"` + IpxeScript *string `json:"ipxeScript"` + LaunchMode InstanceLaunchModeEnum `json:"launchMode"` + LaunchOptions *LaunchOptions `json:"launchOptions"` + InstanceOptions *InstanceOptions `json:"instanceOptions"` + AvailabilityConfig *InstanceAvailabilityConfig `json:"availabilityConfig"` + PreemptibleInstanceConfig *PreemptibleInstanceConfigDetails `json:"preemptibleInstanceConfig"` + Metadata map[string]string `json:"metadata"` + ShapeConfig *InstanceShapeConfig `json:"shapeConfig"` + SourceDetails instancesourcedetails `json:"sourceDetails"` + SystemTags map[string]map[string]interface{} `json:"systemTags"` + AgentConfig *InstanceAgentConfig `json:"agentConfig"` + TimeMaintenanceRebootDue *common.SDKTime `json:"timeMaintenanceRebootDue"` + PlatformConfig platformconfig `json:"platformConfig"` + AvailabilityDomain *string `json:"availabilityDomain"` + CompartmentId *string `json:"compartmentId"` + Id *string `json:"id"` + LifecycleState InstanceLifecycleStateEnum `json:"lifecycleState"` + Region *string `json:"region"` + Shape *string `json:"shape"` + TimeCreated *common.SDKTime `json:"timeCreated"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.CapacityReservationId = model.CapacityReservationId + + m.DedicatedVmHostId = model.DedicatedVmHostId + + m.DefinedTags = model.DefinedTags + + m.DisplayName = model.DisplayName + + m.ExtendedMetadata = model.ExtendedMetadata + + m.FaultDomain = model.FaultDomain + + m.FreeformTags = model.FreeformTags + + m.ImageId = model.ImageId + + m.IpxeScript = model.IpxeScript + + m.LaunchMode = model.LaunchMode + + m.LaunchOptions = model.LaunchOptions + + m.InstanceOptions = model.InstanceOptions + + m.AvailabilityConfig = model.AvailabilityConfig + + m.PreemptibleInstanceConfig = model.PreemptibleInstanceConfig + + m.Metadata = model.Metadata + + m.ShapeConfig = model.ShapeConfig + + nn, e = model.SourceDetails.UnmarshalPolymorphicJSON(model.SourceDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.SourceDetails = nn.(InstanceSourceDetails) + } else { + m.SourceDetails = nil + } + + m.SystemTags = model.SystemTags + + m.AgentConfig = model.AgentConfig + + m.TimeMaintenanceRebootDue = model.TimeMaintenanceRebootDue + + nn, e = model.PlatformConfig.UnmarshalPolymorphicJSON(model.PlatformConfig.JsonData) + if e != nil { + return + } + if nn != nil { + m.PlatformConfig = nn.(PlatformConfig) + } else { + m.PlatformConfig = nil + } + + m.AvailabilityDomain = model.AvailabilityDomain + + m.CompartmentId = model.CompartmentId + + m.Id = model.Id + + m.LifecycleState = model.LifecycleState + + m.Region = model.Region + + m.Shape = model.Shape + + m.TimeCreated = model.TimeCreated + + return +} + +// InstanceLaunchModeEnum Enum with underlying type: string +type InstanceLaunchModeEnum string + +// Set of constants representing the allowable values for InstanceLaunchModeEnum +const ( + InstanceLaunchModeNative InstanceLaunchModeEnum = "NATIVE" + InstanceLaunchModeEmulated InstanceLaunchModeEnum = "EMULATED" + InstanceLaunchModeParavirtualized InstanceLaunchModeEnum = "PARAVIRTUALIZED" + InstanceLaunchModeCustom InstanceLaunchModeEnum = "CUSTOM" +) + +var mappingInstanceLaunchMode = map[string]InstanceLaunchModeEnum{ + "NATIVE": InstanceLaunchModeNative, + "EMULATED": InstanceLaunchModeEmulated, + "PARAVIRTUALIZED": InstanceLaunchModeParavirtualized, + "CUSTOM": InstanceLaunchModeCustom, +} + +// GetInstanceLaunchModeEnumValues Enumerates the set of values for InstanceLaunchModeEnum +func GetInstanceLaunchModeEnumValues() []InstanceLaunchModeEnum { + values := make([]InstanceLaunchModeEnum, 0) + for _, v := range mappingInstanceLaunchMode { + values = append(values, v) + } + return values +} + +// InstanceLifecycleStateEnum Enum with underlying type: string +type InstanceLifecycleStateEnum string + +// Set of constants representing the allowable values for InstanceLifecycleStateEnum +const ( + InstanceLifecycleStateMoving InstanceLifecycleStateEnum = "MOVING" + InstanceLifecycleStateProvisioning InstanceLifecycleStateEnum = "PROVISIONING" + InstanceLifecycleStateRunning InstanceLifecycleStateEnum = "RUNNING" + InstanceLifecycleStateStarting InstanceLifecycleStateEnum = "STARTING" + InstanceLifecycleStateStopping InstanceLifecycleStateEnum = "STOPPING" + InstanceLifecycleStateStopped InstanceLifecycleStateEnum = "STOPPED" + InstanceLifecycleStateCreatingImage InstanceLifecycleStateEnum = "CREATING_IMAGE" + InstanceLifecycleStateTerminating InstanceLifecycleStateEnum = "TERMINATING" + InstanceLifecycleStateTerminated InstanceLifecycleStateEnum = "TERMINATED" +) + +var mappingInstanceLifecycleState = map[string]InstanceLifecycleStateEnum{ + "MOVING": InstanceLifecycleStateMoving, + "PROVISIONING": InstanceLifecycleStateProvisioning, + "RUNNING": InstanceLifecycleStateRunning, + "STARTING": InstanceLifecycleStateStarting, + "STOPPING": InstanceLifecycleStateStopping, + "STOPPED": InstanceLifecycleStateStopped, + "CREATING_IMAGE": InstanceLifecycleStateCreatingImage, + "TERMINATING": InstanceLifecycleStateTerminating, + "TERMINATED": InstanceLifecycleStateTerminated, +} + +// GetInstanceLifecycleStateEnumValues Enumerates the set of values for InstanceLifecycleStateEnum +func GetInstanceLifecycleStateEnumValues() []InstanceLifecycleStateEnum { + values := make([]InstanceLifecycleStateEnum, 0) + for _, v := range mappingInstanceLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_action_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_action_request_response.go new file mode 100644 index 000000000..06b2b9c1a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_action_request_response.go @@ -0,0 +1,123 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// InstanceActionRequest wrapper for the InstanceAction operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/InstanceAction.go.html to see an example of how to use InstanceActionRequest. +type InstanceActionRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance. + InstanceId *string `mandatory:"true" contributesTo:"path" name:"instanceId"` + + // The action to perform on the instance. + Action InstanceActionActionEnum `mandatory:"true" contributesTo:"query" name:"action" omitEmpty:"true"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request InstanceActionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request InstanceActionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request InstanceActionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request InstanceActionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// InstanceActionResponse wrapper for the InstanceAction operation +type InstanceActionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Instance instance + Instance `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response InstanceActionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response InstanceActionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// InstanceActionActionEnum Enum with underlying type: string +type InstanceActionActionEnum string + +// Set of constants representing the allowable values for InstanceActionActionEnum +const ( + InstanceActionActionStop InstanceActionActionEnum = "STOP" + InstanceActionActionStart InstanceActionActionEnum = "START" + InstanceActionActionSoftreset InstanceActionActionEnum = "SOFTRESET" + InstanceActionActionReset InstanceActionActionEnum = "RESET" + InstanceActionActionSoftstop InstanceActionActionEnum = "SOFTSTOP" + InstanceActionActionSenddiagnosticinterrupt InstanceActionActionEnum = "SENDDIAGNOSTICINTERRUPT" +) + +var mappingInstanceActionAction = map[string]InstanceActionActionEnum{ + "STOP": InstanceActionActionStop, + "START": InstanceActionActionStart, + "SOFTRESET": InstanceActionActionSoftreset, + "RESET": InstanceActionActionReset, + "SOFTSTOP": InstanceActionActionSoftstop, + "SENDDIAGNOSTICINTERRUPT": InstanceActionActionSenddiagnosticinterrupt, +} + +// GetInstanceActionActionEnumValues Enumerates the set of values for InstanceActionActionEnum +func GetInstanceActionActionEnumValues() []InstanceActionActionEnum { + values := make([]InstanceActionActionEnum, 0) + for _, v := range mappingInstanceActionAction { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_agent_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_agent_config.go new file mode 100644 index 000000000..9c2c5de63 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_agent_config.go @@ -0,0 +1,60 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceAgentConfig Configuration options for the Oracle Cloud Agent software running on the instance. +type InstanceAgentConfig struct { + + // Whether Oracle Cloud Agent can gather performance metrics and monitor the instance using the + // monitoring plugins. + // These are the monitoring plugins: Compute Instance Monitoring + // and Custom Logs Monitoring. + // The monitoring plugins are controlled by this parameter and by the per-plugin + // configuration in the `pluginsConfig` object. + // - If `isMonitoringDisabled` is true, all of the monitoring plugins are disabled, regardless of + // the per-plugin configuration. + // - If `isMonitoringDisabled` is false, all of the monitoring plugins are enabled. You + // can optionally disable individual monitoring plugins by providing a value in the `pluginsConfig` + // object. + IsMonitoringDisabled *bool `mandatory:"false" json:"isMonitoringDisabled"` + + // Whether Oracle Cloud Agent can run all the available management plugins. + // These are the management plugins: OS Management Service Agent and Compute Instance + // Run Command. + // The management plugins are controlled by this parameter and by the per-plugin + // configuration in the `pluginsConfig` object. + // - If `isManagementDisabled` is true, all of the management plugins are disabled, regardless of + // the per-plugin configuration. + // - If `isManagementDisabled` is false, all of the management plugins are enabled. You + // can optionally disable individual management plugins by providing a value in the `pluginsConfig` + // object. + IsManagementDisabled *bool `mandatory:"false" json:"isManagementDisabled"` + + // Whether Oracle Cloud Agent can run all of the available plugins. + // This includes the management and monitoring plugins. + // For more information about the available plugins, see + // Managing Plugins with Oracle Cloud Agent (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/manage-plugins.htm). + AreAllPluginsDisabled *bool `mandatory:"false" json:"areAllPluginsDisabled"` + + // The configuration of plugins associated with this instance. + PluginsConfig []InstanceAgentPluginConfigDetails `mandatory:"false" json:"pluginsConfig"` +} + +func (m InstanceAgentConfig) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_agent_features.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_agent_features.go new file mode 100644 index 000000000..3830cdfd0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_agent_features.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceAgentFeatures Oracle Cloud Agent features supported on the image. +type InstanceAgentFeatures struct { + + // This attribute is not used. + IsMonitoringSupported *bool `mandatory:"false" json:"isMonitoringSupported"` + + // This attribute is not used. + IsManagementSupported *bool `mandatory:"false" json:"isManagementSupported"` +} + +func (m InstanceAgentFeatures) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_agent_plugin_config_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_agent_plugin_config_details.go new file mode 100644 index 000000000..137f466a0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_agent_plugin_config_details.go @@ -0,0 +1,60 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceAgentPluginConfigDetails The configuration of plugins associated with this instance. +type InstanceAgentPluginConfigDetails struct { + + // The plugin name. To get a list of available plugins, use the + // ListInstanceagentAvailablePlugins + // operation in the Oracle Cloud Agent API. For more information about the available plugins, see + // Managing Plugins with Oracle Cloud Agent (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/manage-plugins.htm). + Name *string `mandatory:"true" json:"name"` + + // Whether the plugin should be enabled or disabled. + // To enable the monitoring and management plugins, the `isMonitoringDisabled` and + // `isManagementDisabled` attributes must also be set to false. + DesiredState InstanceAgentPluginConfigDetailsDesiredStateEnum `mandatory:"true" json:"desiredState"` +} + +func (m InstanceAgentPluginConfigDetails) String() string { + return common.PointerString(m) +} + +// InstanceAgentPluginConfigDetailsDesiredStateEnum Enum with underlying type: string +type InstanceAgentPluginConfigDetailsDesiredStateEnum string + +// Set of constants representing the allowable values for InstanceAgentPluginConfigDetailsDesiredStateEnum +const ( + InstanceAgentPluginConfigDetailsDesiredStateEnabled InstanceAgentPluginConfigDetailsDesiredStateEnum = "ENABLED" + InstanceAgentPluginConfigDetailsDesiredStateDisabled InstanceAgentPluginConfigDetailsDesiredStateEnum = "DISABLED" +) + +var mappingInstanceAgentPluginConfigDetailsDesiredState = map[string]InstanceAgentPluginConfigDetailsDesiredStateEnum{ + "ENABLED": InstanceAgentPluginConfigDetailsDesiredStateEnabled, + "DISABLED": InstanceAgentPluginConfigDetailsDesiredStateDisabled, +} + +// GetInstanceAgentPluginConfigDetailsDesiredStateEnumValues Enumerates the set of values for InstanceAgentPluginConfigDetailsDesiredStateEnum +func GetInstanceAgentPluginConfigDetailsDesiredStateEnumValues() []InstanceAgentPluginConfigDetailsDesiredStateEnum { + values := make([]InstanceAgentPluginConfigDetailsDesiredStateEnum, 0) + for _, v := range mappingInstanceAgentPluginConfigDetailsDesiredState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_availability_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_availability_config.go new file mode 100644 index 000000000..4e9c1d46d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_availability_config.go @@ -0,0 +1,60 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceAvailabilityConfig Options for defining the availabiity of a VM instance after a maintenance event that impacts the underlying hardware. +type InstanceAvailabilityConfig struct { + + // Whether to live migrate supported VM instances to a healthy physical VM host without + // disrupting running instances during infrastructure maintenance events. If null, Oracle + // chooses the best option for migrating the VM during infrastructure maintenance events. + IsLiveMigrationPreferred *bool `mandatory:"false" json:"isLiveMigrationPreferred"` + + // The lifecycle state for an instance when it is recovered after infrastructure maintenance. + // * `RESTORE_INSTANCE` - The instance is restored to the lifecycle state it was in before the maintenance event. + // If the instance was running, it is automatically rebooted. This is the default action when a value is not set. + // * `STOP_INSTANCE` - The instance is recovered in the stopped state. + RecoveryAction InstanceAvailabilityConfigRecoveryActionEnum `mandatory:"false" json:"recoveryAction,omitempty"` +} + +func (m InstanceAvailabilityConfig) String() string { + return common.PointerString(m) +} + +// InstanceAvailabilityConfigRecoveryActionEnum Enum with underlying type: string +type InstanceAvailabilityConfigRecoveryActionEnum string + +// Set of constants representing the allowable values for InstanceAvailabilityConfigRecoveryActionEnum +const ( + InstanceAvailabilityConfigRecoveryActionRestoreInstance InstanceAvailabilityConfigRecoveryActionEnum = "RESTORE_INSTANCE" + InstanceAvailabilityConfigRecoveryActionStopInstance InstanceAvailabilityConfigRecoveryActionEnum = "STOP_INSTANCE" +) + +var mappingInstanceAvailabilityConfigRecoveryAction = map[string]InstanceAvailabilityConfigRecoveryActionEnum{ + "RESTORE_INSTANCE": InstanceAvailabilityConfigRecoveryActionRestoreInstance, + "STOP_INSTANCE": InstanceAvailabilityConfigRecoveryActionStopInstance, +} + +// GetInstanceAvailabilityConfigRecoveryActionEnumValues Enumerates the set of values for InstanceAvailabilityConfigRecoveryActionEnum +func GetInstanceAvailabilityConfigRecoveryActionEnumValues() []InstanceAvailabilityConfigRecoveryActionEnum { + values := make([]InstanceAvailabilityConfigRecoveryActionEnum, 0) + for _, v := range mappingInstanceAvailabilityConfigRecoveryAction { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration.go new file mode 100644 index 000000000..b4a8e5c76 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration.go @@ -0,0 +1,109 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfiguration An instance configuration is a template that defines the settings to use when creating Compute instances. +// For more information about instance configurations, see +// Managing Compute Instances (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/instancemanagement.htm). +type InstanceConfiguration struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment + // containing the instance configuration. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance configuration. + Id *string `mandatory:"true" json:"id"` + + // The date and time the instance configuration was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + InstanceDetails InstanceConfigurationInstanceDetails `mandatory:"false" json:"instanceDetails"` + + // Parameters that were not specified when the instance configuration was created, but that + // are required to launch an instance from the instance configuration. See the + // LaunchInstanceConfiguration operation. + DeferredFields []string `mandatory:"false" json:"deferredFields"` +} + +func (m InstanceConfiguration) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *InstanceConfiguration) UnmarshalJSON(data []byte) (e error) { + model := struct { + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + DisplayName *string `json:"displayName"` + FreeformTags map[string]string `json:"freeformTags"` + InstanceDetails instanceconfigurationinstancedetails `json:"instanceDetails"` + DeferredFields []string `json:"deferredFields"` + CompartmentId *string `json:"compartmentId"` + Id *string `json:"id"` + TimeCreated *common.SDKTime `json:"timeCreated"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.DefinedTags = model.DefinedTags + + m.DisplayName = model.DisplayName + + m.FreeformTags = model.FreeformTags + + nn, e = model.InstanceDetails.UnmarshalPolymorphicJSON(model.InstanceDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.InstanceDetails = nn.(InstanceConfigurationInstanceDetails) + } else { + m.InstanceDetails = nil + } + + m.DeferredFields = make([]string, len(model.DeferredFields)) + for i, n := range model.DeferredFields { + m.DeferredFields[i] = n + } + + m.CompartmentId = model.CompartmentId + + m.Id = model.Id + + m.TimeCreated = model.TimeCreated + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_amd_milan_bm_launch_instance_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_amd_milan_bm_launch_instance_platform_config.go new file mode 100644 index 000000000..c706ad915 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_amd_milan_bm_launch_instance_platform_config.go @@ -0,0 +1,96 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfig The platform configuration used when launching a bare metal instance with an E4 shape +// (the AMD Milan platform). +type InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfig struct { + + // Whether Secure Boot is enabled on the instance. + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + + // Whether the Measured Boot feature is enabled on the instance. + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` + + // The number of NUMA nodes per socket. + NumaNodesPerSocket InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum `mandatory:"false" json:"numaNodesPerSocket,omitempty"` +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfig) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfig) MarshalJSON() (buff []byte, e error) { + type MarshalTypeInstanceConfigurationAmdMilanBmLaunchInstancePlatformConfig InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfig + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeInstanceConfigurationAmdMilanBmLaunchInstancePlatformConfig + }{ + "AMD_MILAN_BM", + (MarshalTypeInstanceConfigurationAmdMilanBmLaunchInstancePlatformConfig)(m), + } + + return json.Marshal(&s) +} + +// InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum Enum with underlying type: string +type InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum string + +// Set of constants representing the allowable values for InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum +const ( + InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps0 InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum = "NPS0" + InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps1 InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum = "NPS1" + InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps2 InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum = "NPS2" + InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps4 InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum = "NPS4" +) + +var mappingInstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocket = map[string]InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum{ + "NPS0": InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps0, + "NPS1": InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps1, + "NPS2": InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps2, + "NPS4": InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketNps4, +} + +// GetInstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnumValues Enumerates the set of values for InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum +func GetInstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnumValues() []InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum { + values := make([]InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocketEnum, 0) + for _, v := range mappingInstanceConfigurationAmdMilanBmLaunchInstancePlatformConfigNumaNodesPerSocket { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_amd_rome_bm_launch_instance_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_amd_rome_bm_launch_instance_platform_config.go new file mode 100644 index 000000000..8e2ba60a4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_amd_rome_bm_launch_instance_platform_config.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationAmdRomeBmLaunchInstancePlatformConfig The platform configuration used when launching a bare metal instance with the AMD Rome platform. +type InstanceConfigurationAmdRomeBmLaunchInstancePlatformConfig struct { + + // Whether Secure Boot is enabled on the instance. + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + + // Whether the Measured Boot feature is enabled on the instance. + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m InstanceConfigurationAmdRomeBmLaunchInstancePlatformConfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m InstanceConfigurationAmdRomeBmLaunchInstancePlatformConfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m InstanceConfigurationAmdRomeBmLaunchInstancePlatformConfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m InstanceConfigurationAmdRomeBmLaunchInstancePlatformConfig) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m InstanceConfigurationAmdRomeBmLaunchInstancePlatformConfig) MarshalJSON() (buff []byte, e error) { + type MarshalTypeInstanceConfigurationAmdRomeBmLaunchInstancePlatformConfig InstanceConfigurationAmdRomeBmLaunchInstancePlatformConfig + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeInstanceConfigurationAmdRomeBmLaunchInstancePlatformConfig + }{ + "AMD_ROME_BM", + (MarshalTypeInstanceConfigurationAmdRomeBmLaunchInstancePlatformConfig)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_amd_vm_launch_instance_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_amd_vm_launch_instance_platform_config.go new file mode 100644 index 000000000..86d1a0b3b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_amd_vm_launch_instance_platform_config.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationAmdVmLaunchInstancePlatformConfig The platform configuration used when launching a virtual machine instance with the AMD platform. +type InstanceConfigurationAmdVmLaunchInstancePlatformConfig struct { + + // Whether Secure Boot is enabled on the instance. + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + + // Whether the Measured Boot feature is enabled on the instance. + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m InstanceConfigurationAmdVmLaunchInstancePlatformConfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m InstanceConfigurationAmdVmLaunchInstancePlatformConfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m InstanceConfigurationAmdVmLaunchInstancePlatformConfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m InstanceConfigurationAmdVmLaunchInstancePlatformConfig) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m InstanceConfigurationAmdVmLaunchInstancePlatformConfig) MarshalJSON() (buff []byte, e error) { + type MarshalTypeInstanceConfigurationAmdVmLaunchInstancePlatformConfig InstanceConfigurationAmdVmLaunchInstancePlatformConfig + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeInstanceConfigurationAmdVmLaunchInstancePlatformConfig + }{ + "AMD_VM", + (MarshalTypeInstanceConfigurationAmdVmLaunchInstancePlatformConfig)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_attach_vnic_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_attach_vnic_details.go new file mode 100644 index 000000000..135e7f1a9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_attach_vnic_details.go @@ -0,0 +1,38 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationAttachVnicDetails The representation of InstanceConfigurationAttachVnicDetails +type InstanceConfigurationAttachVnicDetails struct { + CreateVnicDetails *InstanceConfigurationCreateVnicDetails `mandatory:"false" json:"createVnicDetails"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Which physical network interface card (NIC) the VNIC will use. Defaults to 0. + // Certain bare metal instance shapes have two active physical NICs (0 and 1). If + // you add a secondary VNIC to one of these instances, you can specify which NIC + // the VNIC will use. For more information, see + // Virtual Network Interface Cards (VNICs) (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingVNICs.htm). + NicIndex *int `mandatory:"false" json:"nicIndex"` +} + +func (m InstanceConfigurationAttachVnicDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_attach_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_attach_volume_details.go new file mode 100644 index 000000000..dbc1ca426 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_attach_volume_details.go @@ -0,0 +1,114 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationAttachVolumeDetails Volume attachmentDetails. Please see AttachVolumeDetails +type InstanceConfigurationAttachVolumeDetails interface { + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + GetDisplayName() *string + + // Whether the attachment should be created in read-only mode. + GetIsReadOnly() *bool + + // The device name. + GetDevice() *string + + // Whether the attachment should be created in shareable mode. If an attachment + // is created in shareable mode, then other instances can attach the same volume, provided + // that they also create their attachments in shareable mode. Only certain volume types can + // be attached in shareable mode. Defaults to false if not specified. + GetIsShareable() *bool +} + +type instanceconfigurationattachvolumedetails struct { + JsonData []byte + DisplayName *string `mandatory:"false" json:"displayName"` + IsReadOnly *bool `mandatory:"false" json:"isReadOnly"` + Device *string `mandatory:"false" json:"device"` + IsShareable *bool `mandatory:"false" json:"isShareable"` + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *instanceconfigurationattachvolumedetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerinstanceconfigurationattachvolumedetails instanceconfigurationattachvolumedetails + s := struct { + Model Unmarshalerinstanceconfigurationattachvolumedetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.DisplayName = s.Model.DisplayName + m.IsReadOnly = s.Model.IsReadOnly + m.Device = s.Model.Device + m.IsShareable = s.Model.IsShareable + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *instanceconfigurationattachvolumedetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "iscsi": + mm := InstanceConfigurationIscsiAttachVolumeDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "paravirtualized": + mm := InstanceConfigurationParavirtualizedAttachVolumeDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetDisplayName returns DisplayName +func (m instanceconfigurationattachvolumedetails) GetDisplayName() *string { + return m.DisplayName +} + +//GetIsReadOnly returns IsReadOnly +func (m instanceconfigurationattachvolumedetails) GetIsReadOnly() *bool { + return m.IsReadOnly +} + +//GetDevice returns Device +func (m instanceconfigurationattachvolumedetails) GetDevice() *string { + return m.Device +} + +//GetIsShareable returns IsShareable +func (m instanceconfigurationattachvolumedetails) GetIsShareable() *bool { + return m.IsShareable +} + +func (m instanceconfigurationattachvolumedetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_availability_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_availability_config.go new file mode 100644 index 000000000..c9caf69a3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_availability_config.go @@ -0,0 +1,55 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationAvailabilityConfig Options for defining the availabiity of a VM instance after a maintenance event that impacts the underlying hardware. +type InstanceConfigurationAvailabilityConfig struct { + + // The lifecycle state for an instance when it is recovered after infrastructure maintenance. + // * `RESTORE_INSTANCE` - The instance is restored to the lifecycle state it was in before the maintenance event. + // If the instance was running, it is automatically rebooted. This is the default action when a value is not set. + // * `STOP_INSTANCE` - The instance is recovered in the stopped state. + RecoveryAction InstanceConfigurationAvailabilityConfigRecoveryActionEnum `mandatory:"false" json:"recoveryAction,omitempty"` +} + +func (m InstanceConfigurationAvailabilityConfig) String() string { + return common.PointerString(m) +} + +// InstanceConfigurationAvailabilityConfigRecoveryActionEnum Enum with underlying type: string +type InstanceConfigurationAvailabilityConfigRecoveryActionEnum string + +// Set of constants representing the allowable values for InstanceConfigurationAvailabilityConfigRecoveryActionEnum +const ( + InstanceConfigurationAvailabilityConfigRecoveryActionRestoreInstance InstanceConfigurationAvailabilityConfigRecoveryActionEnum = "RESTORE_INSTANCE" + InstanceConfigurationAvailabilityConfigRecoveryActionStopInstance InstanceConfigurationAvailabilityConfigRecoveryActionEnum = "STOP_INSTANCE" +) + +var mappingInstanceConfigurationAvailabilityConfigRecoveryAction = map[string]InstanceConfigurationAvailabilityConfigRecoveryActionEnum{ + "RESTORE_INSTANCE": InstanceConfigurationAvailabilityConfigRecoveryActionRestoreInstance, + "STOP_INSTANCE": InstanceConfigurationAvailabilityConfigRecoveryActionStopInstance, +} + +// GetInstanceConfigurationAvailabilityConfigRecoveryActionEnumValues Enumerates the set of values for InstanceConfigurationAvailabilityConfigRecoveryActionEnum +func GetInstanceConfigurationAvailabilityConfigRecoveryActionEnumValues() []InstanceConfigurationAvailabilityConfigRecoveryActionEnum { + values := make([]InstanceConfigurationAvailabilityConfigRecoveryActionEnum, 0) + for _, v := range mappingInstanceConfigurationAvailabilityConfigRecoveryAction { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_block_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_block_volume_details.go new file mode 100644 index 000000000..82cb7aa90 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_block_volume_details.go @@ -0,0 +1,63 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationBlockVolumeDetails Create new block volumes or attach to an existing volume. Specify either createDetails or volumeId. +type InstanceConfigurationBlockVolumeDetails struct { + AttachDetails InstanceConfigurationAttachVolumeDetails `mandatory:"false" json:"attachDetails"` + + CreateDetails *InstanceConfigurationCreateVolumeDetails `mandatory:"false" json:"createDetails"` + + // The OCID of the volume. + VolumeId *string `mandatory:"false" json:"volumeId"` +} + +func (m InstanceConfigurationBlockVolumeDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *InstanceConfigurationBlockVolumeDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + AttachDetails instanceconfigurationattachvolumedetails `json:"attachDetails"` + CreateDetails *InstanceConfigurationCreateVolumeDetails `json:"createDetails"` + VolumeId *string `json:"volumeId"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + nn, e = model.AttachDetails.UnmarshalPolymorphicJSON(model.AttachDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.AttachDetails = nn.(InstanceConfigurationAttachVolumeDetails) + } else { + m.AttachDetails = nil + } + + m.CreateDetails = model.CreateDetails + + m.VolumeId = model.VolumeId + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_create_vnic_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_create_vnic_details.go new file mode 100644 index 000000000..7937fec5e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_create_vnic_details.go @@ -0,0 +1,70 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationCreateVnicDetails Contains the properties of the VNIC for an instance configuration. See CreateVnicDetails +// and Instance Configurations (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/instancemanagement.htm#config) for more information. +type InstanceConfigurationCreateVnicDetails struct { + + // Whether the VNIC should be assigned a public IP address. See the `assignPublicIp` attribute of CreateVnicDetails + // for more information. + AssignPublicIp *bool `mandatory:"false" json:"assignPublicIp"` + + // Whether the VNIC should be assigned a private DNS record. See the `assignPrivateDnsRecord` attribute of CreateVnicDetails + // for more information. + AssignPrivateDnsRecord *bool `mandatory:"false" json:"assignPrivateDnsRecord"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The hostname for the VNIC's primary private IP. + // See the `hostnameLabel` attribute of CreateVnicDetails for more information. + HostnameLabel *string `mandatory:"false" json:"hostnameLabel"` + + // A list of the OCIDs of the network security groups (NSGs) to add the VNIC to. For more + // information about NSGs, see + // NetworkSecurityGroup. + NsgIds []string `mandatory:"false" json:"nsgIds"` + + // A private IP address of your choice to assign to the VNIC. + // See the `privateIp` attribute of CreateVnicDetails for more information. + PrivateIp *string `mandatory:"false" json:"privateIp"` + + // Whether the source/destination check is disabled on the VNIC. + // See the `skipSourceDestCheck` attribute of CreateVnicDetails for more information. + SkipSourceDestCheck *bool `mandatory:"false" json:"skipSourceDestCheck"` + + // The OCID of the subnet to create the VNIC in. + // See the `subnetId` attribute of CreateVnicDetails for more information. + SubnetId *string `mandatory:"false" json:"subnetId"` +} + +func (m InstanceConfigurationCreateVnicDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_create_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_create_volume_details.go new file mode 100644 index 000000000..217dc4187 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_create_volume_details.go @@ -0,0 +1,121 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationCreateVolumeDetails Creates a new block volume. Please see CreateVolumeDetails +type InstanceConfigurationCreateVolumeDetails struct { + + // The availability domain of the volume. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" json:"availabilityDomain"` + + // If provided, specifies the ID of the volume backup policy to assign to the newly + // created volume. If omitted, no policy will be assigned. + BackupPolicyId *string `mandatory:"false" json:"backupPolicyId"` + + // The OCID of the compartment that contains the volume. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID of the Key Management key to assign as the master encryption key + // for the volume. + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` + + // The number of volume performance units (VPUs) that will be applied to this volume per GB, + // representing the Block Volume service's elastic performance options. + // See Block Volume Elastic Performance (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/blockvolumeelasticperformance.htm) for more information. + // Allowed values: + // * `0`: Represents Lower Cost option. + // * `10`: Represents Balanced option. + // * `20`: Represents Higher Performance option. + VpusPerGB *int64 `mandatory:"false" json:"vpusPerGB"` + + // The size of the volume in GBs. + SizeInGBs *int64 `mandatory:"false" json:"sizeInGBs"` + + SourceDetails InstanceConfigurationVolumeSourceDetails `mandatory:"false" json:"sourceDetails"` +} + +func (m InstanceConfigurationCreateVolumeDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *InstanceConfigurationCreateVolumeDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + AvailabilityDomain *string `json:"availabilityDomain"` + BackupPolicyId *string `json:"backupPolicyId"` + CompartmentId *string `json:"compartmentId"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + DisplayName *string `json:"displayName"` + FreeformTags map[string]string `json:"freeformTags"` + KmsKeyId *string `json:"kmsKeyId"` + VpusPerGB *int64 `json:"vpusPerGB"` + SizeInGBs *int64 `json:"sizeInGBs"` + SourceDetails instanceconfigurationvolumesourcedetails `json:"sourceDetails"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.AvailabilityDomain = model.AvailabilityDomain + + m.BackupPolicyId = model.BackupPolicyId + + m.CompartmentId = model.CompartmentId + + m.DefinedTags = model.DefinedTags + + m.DisplayName = model.DisplayName + + m.FreeformTags = model.FreeformTags + + m.KmsKeyId = model.KmsKeyId + + m.VpusPerGB = model.VpusPerGB + + m.SizeInGBs = model.SizeInGBs + + nn, e = model.SourceDetails.UnmarshalPolymorphicJSON(model.SourceDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.SourceDetails = nn.(InstanceConfigurationVolumeSourceDetails) + } else { + m.SourceDetails = nil + } + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_details.go new file mode 100644 index 000000000..d172d52a7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_details.go @@ -0,0 +1,66 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationInstanceDetails The representation of InstanceConfigurationInstanceDetails +type InstanceConfigurationInstanceDetails interface { +} + +type instanceconfigurationinstancedetails struct { + JsonData []byte + InstanceType string `json:"instanceType"` +} + +// UnmarshalJSON unmarshals json +func (m *instanceconfigurationinstancedetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerinstanceconfigurationinstancedetails instanceconfigurationinstancedetails + s := struct { + Model Unmarshalerinstanceconfigurationinstancedetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.InstanceType = s.Model.InstanceType + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *instanceconfigurationinstancedetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.InstanceType { + case "compute": + mm := ComputeInstanceDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +func (m instanceconfigurationinstancedetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_options.go new file mode 100644 index 000000000..4bd401c64 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_options.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationInstanceOptions Optional mutable instance options. As a part of Instance Metadata Service Security Header, This allows user to disable the legacy imds endpoints. +type InstanceConfigurationInstanceOptions struct { + + // Whether to disable the legacy (/v1) instance metadata service endpoints. + // Customers who have migrated to /v2 should set this to true for added security. + // Default is false. + AreLegacyImdsEndpointsDisabled *bool `mandatory:"false" json:"areLegacyImdsEndpointsDisabled"` +} + +func (m InstanceConfigurationInstanceOptions) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_source_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_source_details.go new file mode 100644 index 000000000..dfd489549 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_source_details.go @@ -0,0 +1,70 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationInstanceSourceDetails The representation of InstanceConfigurationInstanceSourceDetails +type InstanceConfigurationInstanceSourceDetails interface { +} + +type instanceconfigurationinstancesourcedetails struct { + JsonData []byte + SourceType string `json:"sourceType"` +} + +// UnmarshalJSON unmarshals json +func (m *instanceconfigurationinstancesourcedetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerinstanceconfigurationinstancesourcedetails instanceconfigurationinstancesourcedetails + s := struct { + Model Unmarshalerinstanceconfigurationinstancesourcedetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.SourceType = s.Model.SourceType + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *instanceconfigurationinstancesourcedetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.SourceType { + case "image": + mm := InstanceConfigurationInstanceSourceViaImageDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "bootVolume": + mm := InstanceConfigurationInstanceSourceViaBootVolumeDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +func (m instanceconfigurationinstancesourcedetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_source_via_boot_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_source_via_boot_volume_details.go new file mode 100644 index 000000000..3cc8d89bd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_source_via_boot_volume_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationInstanceSourceViaBootVolumeDetails The representation of InstanceConfigurationInstanceSourceViaBootVolumeDetails +type InstanceConfigurationInstanceSourceViaBootVolumeDetails struct { + + // The OCID of the boot volume used to boot the instance. + BootVolumeId *string `mandatory:"false" json:"bootVolumeId"` +} + +func (m InstanceConfigurationInstanceSourceViaBootVolumeDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m InstanceConfigurationInstanceSourceViaBootVolumeDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeInstanceConfigurationInstanceSourceViaBootVolumeDetails InstanceConfigurationInstanceSourceViaBootVolumeDetails + s := struct { + DiscriminatorParam string `json:"sourceType"` + MarshalTypeInstanceConfigurationInstanceSourceViaBootVolumeDetails + }{ + "bootVolume", + (MarshalTypeInstanceConfigurationInstanceSourceViaBootVolumeDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_source_via_image_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_source_via_image_details.go new file mode 100644 index 000000000..ebea17a46 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_instance_source_via_image_details.go @@ -0,0 +1,48 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationInstanceSourceViaImageDetails The representation of InstanceConfigurationInstanceSourceViaImageDetails +type InstanceConfigurationInstanceSourceViaImageDetails struct { + + // The size of the boot volume in GBs. The minimum value is 50 GB and the maximum + // value is 32,768 GB (32 TB). + BootVolumeSizeInGBs *int64 `mandatory:"false" json:"bootVolumeSizeInGBs"` + + // The OCID of the image used to boot the instance. + ImageId *string `mandatory:"false" json:"imageId"` +} + +func (m InstanceConfigurationInstanceSourceViaImageDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m InstanceConfigurationInstanceSourceViaImageDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeInstanceConfigurationInstanceSourceViaImageDetails InstanceConfigurationInstanceSourceViaImageDetails + s := struct { + DiscriminatorParam string `json:"sourceType"` + MarshalTypeInstanceConfigurationInstanceSourceViaImageDetails + }{ + "image", + (MarshalTypeInstanceConfigurationInstanceSourceViaImageDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_intel_skylake_bm_launch_instance_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_intel_skylake_bm_launch_instance_platform_config.go new file mode 100644 index 000000000..6c84859ed --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_intel_skylake_bm_launch_instance_platform_config.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationIntelSkylakeBmLaunchInstancePlatformConfig The platform configuration used when launching a bare metal instance with the Intel Skylake platform. +type InstanceConfigurationIntelSkylakeBmLaunchInstancePlatformConfig struct { + + // Whether Secure Boot is enabled on the instance. + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + + // Whether the Measured Boot feature is enabled on the instance. + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m InstanceConfigurationIntelSkylakeBmLaunchInstancePlatformConfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m InstanceConfigurationIntelSkylakeBmLaunchInstancePlatformConfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m InstanceConfigurationIntelSkylakeBmLaunchInstancePlatformConfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m InstanceConfigurationIntelSkylakeBmLaunchInstancePlatformConfig) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m InstanceConfigurationIntelSkylakeBmLaunchInstancePlatformConfig) MarshalJSON() (buff []byte, e error) { + type MarshalTypeInstanceConfigurationIntelSkylakeBmLaunchInstancePlatformConfig InstanceConfigurationIntelSkylakeBmLaunchInstancePlatformConfig + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeInstanceConfigurationIntelSkylakeBmLaunchInstancePlatformConfig + }{ + "INTEL_SKYLAKE_BM", + (MarshalTypeInstanceConfigurationIntelSkylakeBmLaunchInstancePlatformConfig)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_intel_vm_launch_instance_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_intel_vm_launch_instance_platform_config.go new file mode 100644 index 000000000..d5a0307d9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_intel_vm_launch_instance_platform_config.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationIntelVmLaunchInstancePlatformConfig The platform configuration used when launching a virtual machine instance with the Intel platform. +type InstanceConfigurationIntelVmLaunchInstancePlatformConfig struct { + + // Whether Secure Boot is enabled on the instance. + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + + // Whether the Measured Boot feature is enabled on the instance. + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m InstanceConfigurationIntelVmLaunchInstancePlatformConfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m InstanceConfigurationIntelVmLaunchInstancePlatformConfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m InstanceConfigurationIntelVmLaunchInstancePlatformConfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m InstanceConfigurationIntelVmLaunchInstancePlatformConfig) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m InstanceConfigurationIntelVmLaunchInstancePlatformConfig) MarshalJSON() (buff []byte, e error) { + type MarshalTypeInstanceConfigurationIntelVmLaunchInstancePlatformConfig InstanceConfigurationIntelVmLaunchInstancePlatformConfig + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeInstanceConfigurationIntelVmLaunchInstancePlatformConfig + }{ + "INTEL_VM", + (MarshalTypeInstanceConfigurationIntelVmLaunchInstancePlatformConfig)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_iscsi_attach_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_iscsi_attach_volume_details.go new file mode 100644 index 000000000..6d0883eff --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_iscsi_attach_volume_details.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationIscsiAttachVolumeDetails The representation of InstanceConfigurationIscsiAttachVolumeDetails +type InstanceConfigurationIscsiAttachVolumeDetails struct { + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Whether the attachment should be created in read-only mode. + IsReadOnly *bool `mandatory:"false" json:"isReadOnly"` + + // The device name. + Device *string `mandatory:"false" json:"device"` + + // Whether the attachment should be created in shareable mode. If an attachment + // is created in shareable mode, then other instances can attach the same volume, provided + // that they also create their attachments in shareable mode. Only certain volume types can + // be attached in shareable mode. Defaults to false if not specified. + IsShareable *bool `mandatory:"false" json:"isShareable"` + + // Whether to use CHAP authentication for the volume attachment. Defaults to false. + UseChap *bool `mandatory:"false" json:"useChap"` +} + +//GetDisplayName returns DisplayName +func (m InstanceConfigurationIscsiAttachVolumeDetails) GetDisplayName() *string { + return m.DisplayName +} + +//GetIsReadOnly returns IsReadOnly +func (m InstanceConfigurationIscsiAttachVolumeDetails) GetIsReadOnly() *bool { + return m.IsReadOnly +} + +//GetDevice returns Device +func (m InstanceConfigurationIscsiAttachVolumeDetails) GetDevice() *string { + return m.Device +} + +//GetIsShareable returns IsShareable +func (m InstanceConfigurationIscsiAttachVolumeDetails) GetIsShareable() *bool { + return m.IsShareable +} + +func (m InstanceConfigurationIscsiAttachVolumeDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m InstanceConfigurationIscsiAttachVolumeDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeInstanceConfigurationIscsiAttachVolumeDetails InstanceConfigurationIscsiAttachVolumeDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeInstanceConfigurationIscsiAttachVolumeDetails + }{ + "iscsi", + (MarshalTypeInstanceConfigurationIscsiAttachVolumeDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_agent_config_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_agent_config_details.go new file mode 100644 index 000000000..d646b6e3d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_agent_config_details.go @@ -0,0 +1,63 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationLaunchInstanceAgentConfigDetails Configuration options for the Oracle Cloud Agent software running on the instance. +type InstanceConfigurationLaunchInstanceAgentConfigDetails struct { + + // Whether Oracle Cloud Agent can gather performance metrics and monitor the instance using the + // monitoring plugins. Default value is false (monitoring plugins are enabled). + // These are the monitoring plugins: Compute Instance Monitoring + // and Custom Logs Monitoring. + // The monitoring plugins are controlled by this parameter and by the per-plugin + // configuration in the `pluginsConfig` object. + // - If `isMonitoringDisabled` is true, all of the monitoring plugins are disabled, regardless of + // the per-plugin configuration. + // - If `isMonitoringDisabled` is false, all of the monitoring plugins are enabled. You + // can optionally disable individual monitoring plugins by providing a value in the `pluginsConfig` + // object. + IsMonitoringDisabled *bool `mandatory:"false" json:"isMonitoringDisabled"` + + // Whether Oracle Cloud Agent can run all the available management plugins. + // Default value is false (management plugins are enabled). + // These are the management plugins: OS Management Service Agent and Compute Instance + // Run Command. + // The management plugins are controlled by this parameter and by the per-plugin + // configuration in the `pluginsConfig` object. + // - If `isManagementDisabled` is true, all of the management plugins are disabled, regardless of + // the per-plugin configuration. + // - If `isManagementDisabled` is false, all of the management plugins are enabled. You + // can optionally disable individual management plugins by providing a value in the `pluginsConfig` + // object. + IsManagementDisabled *bool `mandatory:"false" json:"isManagementDisabled"` + + // Whether Oracle Cloud Agent can run all the available plugins. + // This includes the management and monitoring plugins. + // To get a list of available plugins, use the + // ListInstanceagentAvailablePlugins + // operation in the Oracle Cloud Agent API. For more information about the available plugins, see + // Managing Plugins with Oracle Cloud Agent (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/manage-plugins.htm). + AreAllPluginsDisabled *bool `mandatory:"false" json:"areAllPluginsDisabled"` + + // The configuration of plugins associated with this instance. + PluginsConfig []InstanceAgentPluginConfigDetails `mandatory:"false" json:"pluginsConfig"` +} + +func (m InstanceConfigurationLaunchInstanceAgentConfigDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_details.go new file mode 100644 index 000000000..638f0b777 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_details.go @@ -0,0 +1,328 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationLaunchInstanceDetails Instance launch details for creating an instance from an instance configuration. Use the `sourceDetails` +// parameter to specify whether a boot volume or an image should be used to launch a new instance. +// See LaunchInstanceDetails for more information. +type InstanceConfigurationLaunchInstanceDetails struct { + + // The availability domain of the instance. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" json:"availabilityDomain"` + + // The OCID of the compute capacity reservation this instance is launched under. + CapacityReservationId *string `mandatory:"false" json:"capacityReservationId"` + + // The OCID of the compartment containing the instance. + // Instances created from instance configurations are placed in the same compartment + // as the instance that was used to create the instance configuration. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + CreateVnicDetails *InstanceConfigurationCreateVnicDetails `mandatory:"false" json:"createVnicDetails"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Additional metadata key/value pairs that you provide. They serve the same purpose and + // functionality as fields in the `metadata` object. + // They are distinguished from `metadata` fields in that these can be nested JSON objects + // (whereas `metadata` fields are string/string maps only). + // The combined size of the `metadata` and `extendedMetadata` objects can be a maximum of + // 32,000 bytes. + ExtendedMetadata map[string]interface{} `mandatory:"false" json:"extendedMetadata"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // This is an advanced option. + // When a bare metal or virtual machine + // instance boots, the iPXE firmware that runs on the instance is + // configured to run an iPXE script to continue the boot process. + // If you want more control over the boot process, you can provide + // your own custom iPXE script that will run when the instance boots; + // however, you should be aware that the same iPXE script will run + // every time an instance boots; not only after the initial + // LaunchInstance call. + // The default iPXE script connects to the instance's local boot + // volume over iSCSI and performs a network boot. If you use a custom iPXE + // script and want to network-boot from the instance's local boot volume + // over iSCSI the same way as the default iPXE script, you should use the + // following iSCSI IP address: 169.254.0.2, and boot volume IQN: + // iqn.2015-02.oracle.boot. + // For more information about the Bring Your Own Image feature of + // Oracle Cloud Infrastructure, see + // Bring Your Own Image (https://docs.cloud.oracle.com/iaas/Content/Compute/References/bringyourownimage.htm). + // For more information about iPXE, see http://ipxe.org. + IpxeScript *string `mandatory:"false" json:"ipxeScript"` + + // Custom metadata key/value pairs that you provide, such as the SSH public key + // required to connect to the instance. + // A metadata service runs on every launched instance. The service is an HTTP + // endpoint listening on 169.254.169.254. You can use the service to: + // * Provide information to Cloud-Init (https://cloudinit.readthedocs.org/en/latest/) + // to be used for various system initialization tasks. + // * Get information about the instance, including the custom metadata that you + // provide when you launch the instance. + // **Providing Cloud-Init Metadata** + // You can use the following metadata key names to provide information to + // Cloud-Init: + // **"ssh_authorized_keys"** - Provide one or more public SSH keys to be + // included in the `~/.ssh/authorized_keys` file for the default user on the + // instance. Use a newline character to separate multiple keys. The SSH + // keys must be in the format necessary for the `authorized_keys` file, as shown + // in the example below. + // **"user_data"** - Provide your own base64-encoded data to be used by + // Cloud-Init to run custom scripts or provide custom Cloud-Init configuration. For + // information about how to take advantage of user data, see the + // Cloud-Init Documentation (http://cloudinit.readthedocs.org/en/latest/topics/format.html). + // **Metadata Example** + // "metadata" : { + // "quake_bot_level" : "Severe", + // "ssh_authorized_keys" : "ssh-rsa == rsa-key-20160227", + // "user_data" : "==" + // } + // **Getting Metadata on the Instance** + // To get information about your instance, connect to the instance using SSH and issue any of the + // following GET requests: + // curl -H "Authorization: Bearer Oracle" http://169.254.169.254/opc/v2/instance/ + // curl -H "Authorization: Bearer Oracle" http://169.254.169.254/opc/v2/instance/metadata/ + // curl -H "Authorization: Bearer Oracle" http://169.254.169.254/opc/v2/instance/metadata/ + // You'll get back a response that includes all the instance information; only the metadata information; or + // the metadata information for the specified key name, respectively. + // The combined size of the `metadata` and `extendedMetadata` objects can be a maximum of 32,000 bytes. + Metadata map[string]string `mandatory:"false" json:"metadata"` + + // The shape of an instance. The shape determines the number of CPUs, amount of memory, + // and other resources allocated to the instance. + // You can enumerate all available shapes by calling ListShapes. + Shape *string `mandatory:"false" json:"shape"` + + ShapeConfig *InstanceConfigurationLaunchInstanceShapeConfigDetails `mandatory:"false" json:"shapeConfig"` + + PlatformConfig InstanceConfigurationLaunchInstancePlatformConfig `mandatory:"false" json:"platformConfig"` + + SourceDetails InstanceConfigurationInstanceSourceDetails `mandatory:"false" json:"sourceDetails"` + + // A fault domain is a grouping of hardware and infrastructure within an availability domain. + // Each availability domain contains three fault domains. Fault domains let you distribute your + // instances so that they are not on the same physical hardware within a single availability domain. + // A hardware failure or Compute hardware maintenance that affects one fault domain does not affect + // instances in other fault domains. + // If you do not specify the fault domain, the system selects one for you. + // + // To get a list of fault domains, use the + // ListFaultDomains operation in the + // Identity and Access Management Service API. + // Example: `FAULT-DOMAIN-1` + FaultDomain *string `mandatory:"false" json:"faultDomain"` + + // The OCID of dedicated VM host. + // Dedicated VM hosts can be used when launching individual instances from an instance configuration. They + // cannot be used to launch instance pools. + DedicatedVmHostId *string `mandatory:"false" json:"dedicatedVmHostId"` + + // Specifies the configuration mode for launching virtual machine (VM) instances. The configuration modes are: + // * `NATIVE` - VM instances launch with iSCSI boot and VFIO devices. The default value for platform images. + // * `EMULATED` - VM instances launch with emulated devices, such as the E1000 network driver and emulated SCSI disk controller. + // * `PARAVIRTUALIZED` - VM instances launch with paravirtualized devices using VirtIO drivers. + // * `CUSTOM` - VM instances launch with custom configuration settings specified in the `LaunchOptions` parameter. + LaunchMode InstanceConfigurationLaunchInstanceDetailsLaunchModeEnum `mandatory:"false" json:"launchMode,omitempty"` + + LaunchOptions *InstanceConfigurationLaunchOptions `mandatory:"false" json:"launchOptions"` + + AgentConfig *InstanceConfigurationLaunchInstanceAgentConfigDetails `mandatory:"false" json:"agentConfig"` + + // Whether to enable in-transit encryption for the data volume's paravirtualized attachment. The default value is false. + IsPvEncryptionInTransitEnabled *bool `mandatory:"false" json:"isPvEncryptionInTransitEnabled"` + + // The preferred maintenance action for an instance. The default is LIVE_MIGRATE, if live migration is supported. + // * `LIVE_MIGRATE` - Run maintenance using a live migration. + // * `REBOOT` - Run maintenance using a reboot. + PreferredMaintenanceAction InstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionEnum `mandatory:"false" json:"preferredMaintenanceAction,omitempty"` + + InstanceOptions *InstanceConfigurationInstanceOptions `mandatory:"false" json:"instanceOptions"` + + AvailabilityConfig *InstanceConfigurationAvailabilityConfig `mandatory:"false" json:"availabilityConfig"` + + PreemptibleInstanceConfig *PreemptibleInstanceConfigDetails `mandatory:"false" json:"preemptibleInstanceConfig"` +} + +func (m InstanceConfigurationLaunchInstanceDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *InstanceConfigurationLaunchInstanceDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + AvailabilityDomain *string `json:"availabilityDomain"` + CapacityReservationId *string `json:"capacityReservationId"` + CompartmentId *string `json:"compartmentId"` + CreateVnicDetails *InstanceConfigurationCreateVnicDetails `json:"createVnicDetails"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + DisplayName *string `json:"displayName"` + ExtendedMetadata map[string]interface{} `json:"extendedMetadata"` + FreeformTags map[string]string `json:"freeformTags"` + IpxeScript *string `json:"ipxeScript"` + Metadata map[string]string `json:"metadata"` + Shape *string `json:"shape"` + ShapeConfig *InstanceConfigurationLaunchInstanceShapeConfigDetails `json:"shapeConfig"` + PlatformConfig instanceconfigurationlaunchinstanceplatformconfig `json:"platformConfig"` + SourceDetails instanceconfigurationinstancesourcedetails `json:"sourceDetails"` + FaultDomain *string `json:"faultDomain"` + DedicatedVmHostId *string `json:"dedicatedVmHostId"` + LaunchMode InstanceConfigurationLaunchInstanceDetailsLaunchModeEnum `json:"launchMode"` + LaunchOptions *InstanceConfigurationLaunchOptions `json:"launchOptions"` + AgentConfig *InstanceConfigurationLaunchInstanceAgentConfigDetails `json:"agentConfig"` + IsPvEncryptionInTransitEnabled *bool `json:"isPvEncryptionInTransitEnabled"` + PreferredMaintenanceAction InstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionEnum `json:"preferredMaintenanceAction"` + InstanceOptions *InstanceConfigurationInstanceOptions `json:"instanceOptions"` + AvailabilityConfig *InstanceConfigurationAvailabilityConfig `json:"availabilityConfig"` + PreemptibleInstanceConfig *PreemptibleInstanceConfigDetails `json:"preemptibleInstanceConfig"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.AvailabilityDomain = model.AvailabilityDomain + + m.CapacityReservationId = model.CapacityReservationId + + m.CompartmentId = model.CompartmentId + + m.CreateVnicDetails = model.CreateVnicDetails + + m.DefinedTags = model.DefinedTags + + m.DisplayName = model.DisplayName + + m.ExtendedMetadata = model.ExtendedMetadata + + m.FreeformTags = model.FreeformTags + + m.IpxeScript = model.IpxeScript + + m.Metadata = model.Metadata + + m.Shape = model.Shape + + m.ShapeConfig = model.ShapeConfig + + nn, e = model.PlatformConfig.UnmarshalPolymorphicJSON(model.PlatformConfig.JsonData) + if e != nil { + return + } + if nn != nil { + m.PlatformConfig = nn.(InstanceConfigurationLaunchInstancePlatformConfig) + } else { + m.PlatformConfig = nil + } + + nn, e = model.SourceDetails.UnmarshalPolymorphicJSON(model.SourceDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.SourceDetails = nn.(InstanceConfigurationInstanceSourceDetails) + } else { + m.SourceDetails = nil + } + + m.FaultDomain = model.FaultDomain + + m.DedicatedVmHostId = model.DedicatedVmHostId + + m.LaunchMode = model.LaunchMode + + m.LaunchOptions = model.LaunchOptions + + m.AgentConfig = model.AgentConfig + + m.IsPvEncryptionInTransitEnabled = model.IsPvEncryptionInTransitEnabled + + m.PreferredMaintenanceAction = model.PreferredMaintenanceAction + + m.InstanceOptions = model.InstanceOptions + + m.AvailabilityConfig = model.AvailabilityConfig + + m.PreemptibleInstanceConfig = model.PreemptibleInstanceConfig + + return +} + +// InstanceConfigurationLaunchInstanceDetailsLaunchModeEnum Enum with underlying type: string +type InstanceConfigurationLaunchInstanceDetailsLaunchModeEnum string + +// Set of constants representing the allowable values for InstanceConfigurationLaunchInstanceDetailsLaunchModeEnum +const ( + InstanceConfigurationLaunchInstanceDetailsLaunchModeNative InstanceConfigurationLaunchInstanceDetailsLaunchModeEnum = "NATIVE" + InstanceConfigurationLaunchInstanceDetailsLaunchModeEmulated InstanceConfigurationLaunchInstanceDetailsLaunchModeEnum = "EMULATED" + InstanceConfigurationLaunchInstanceDetailsLaunchModeParavirtualized InstanceConfigurationLaunchInstanceDetailsLaunchModeEnum = "PARAVIRTUALIZED" + InstanceConfigurationLaunchInstanceDetailsLaunchModeCustom InstanceConfigurationLaunchInstanceDetailsLaunchModeEnum = "CUSTOM" +) + +var mappingInstanceConfigurationLaunchInstanceDetailsLaunchMode = map[string]InstanceConfigurationLaunchInstanceDetailsLaunchModeEnum{ + "NATIVE": InstanceConfigurationLaunchInstanceDetailsLaunchModeNative, + "EMULATED": InstanceConfigurationLaunchInstanceDetailsLaunchModeEmulated, + "PARAVIRTUALIZED": InstanceConfigurationLaunchInstanceDetailsLaunchModeParavirtualized, + "CUSTOM": InstanceConfigurationLaunchInstanceDetailsLaunchModeCustom, +} + +// GetInstanceConfigurationLaunchInstanceDetailsLaunchModeEnumValues Enumerates the set of values for InstanceConfigurationLaunchInstanceDetailsLaunchModeEnum +func GetInstanceConfigurationLaunchInstanceDetailsLaunchModeEnumValues() []InstanceConfigurationLaunchInstanceDetailsLaunchModeEnum { + values := make([]InstanceConfigurationLaunchInstanceDetailsLaunchModeEnum, 0) + for _, v := range mappingInstanceConfigurationLaunchInstanceDetailsLaunchMode { + values = append(values, v) + } + return values +} + +// InstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionEnum Enum with underlying type: string +type InstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionEnum string + +// Set of constants representing the allowable values for InstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionEnum +const ( + InstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionLiveMigrate InstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionEnum = "LIVE_MIGRATE" + InstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionReboot InstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionEnum = "REBOOT" +) + +var mappingInstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceAction = map[string]InstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionEnum{ + "LIVE_MIGRATE": InstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionLiveMigrate, + "REBOOT": InstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionReboot, +} + +// GetInstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionEnumValues Enumerates the set of values for InstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionEnum +func GetInstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionEnumValues() []InstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionEnum { + values := make([]InstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceActionEnum, 0) + for _, v := range mappingInstanceConfigurationLaunchInstanceDetailsPreferredMaintenanceAction { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_platform_config.go new file mode 100644 index 000000000..489c69399 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_platform_config.go @@ -0,0 +1,146 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationLaunchInstancePlatformConfig The platform configuration requested for the instance. +// If you provide the parameter, the instance is created with the platform configuration that you specify. +// For any values that you omit, the instance uses the default configuration values for the `shape` that you +// specify. If you don't provide the parameter, the default values for the `shape` are used. +// Each shape only supports certain configurable values. If the values that you provide are not valid for the +// specified `shape`, an error is returned. +type InstanceConfigurationLaunchInstancePlatformConfig interface { + + // Whether Secure Boot is enabled on the instance. + GetIsSecureBootEnabled() *bool + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + GetIsTrustedPlatformModuleEnabled() *bool + + // Whether the Measured Boot feature is enabled on the instance. + GetIsMeasuredBootEnabled() *bool +} + +type instanceconfigurationlaunchinstanceplatformconfig struct { + JsonData []byte + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *instanceconfigurationlaunchinstanceplatformconfig) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerinstanceconfigurationlaunchinstanceplatformconfig instanceconfigurationlaunchinstanceplatformconfig + s := struct { + Model Unmarshalerinstanceconfigurationlaunchinstanceplatformconfig + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.IsSecureBootEnabled = s.Model.IsSecureBootEnabled + m.IsTrustedPlatformModuleEnabled = s.Model.IsTrustedPlatformModuleEnabled + m.IsMeasuredBootEnabled = s.Model.IsMeasuredBootEnabled + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *instanceconfigurationlaunchinstanceplatformconfig) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "AMD_MILAN_BM": + mm := InstanceConfigurationAmdMilanBmLaunchInstancePlatformConfig{} + err = json.Unmarshal(data, &mm) + return mm, err + case "INTEL_VM": + mm := InstanceConfigurationIntelVmLaunchInstancePlatformConfig{} + err = json.Unmarshal(data, &mm) + return mm, err + case "AMD_ROME_BM": + mm := InstanceConfigurationAmdRomeBmLaunchInstancePlatformConfig{} + err = json.Unmarshal(data, &mm) + return mm, err + case "INTEL_SKYLAKE_BM": + mm := InstanceConfigurationIntelSkylakeBmLaunchInstancePlatformConfig{} + err = json.Unmarshal(data, &mm) + return mm, err + case "AMD_VM": + mm := InstanceConfigurationAmdVmLaunchInstancePlatformConfig{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m instanceconfigurationlaunchinstanceplatformconfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m instanceconfigurationlaunchinstanceplatformconfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m instanceconfigurationlaunchinstanceplatformconfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m instanceconfigurationlaunchinstanceplatformconfig) String() string { + return common.PointerString(m) +} + +// InstanceConfigurationLaunchInstancePlatformConfigTypeEnum Enum with underlying type: string +type InstanceConfigurationLaunchInstancePlatformConfigTypeEnum string + +// Set of constants representing the allowable values for InstanceConfigurationLaunchInstancePlatformConfigTypeEnum +const ( + InstanceConfigurationLaunchInstancePlatformConfigTypeAmdMilanBm InstanceConfigurationLaunchInstancePlatformConfigTypeEnum = "AMD_MILAN_BM" + InstanceConfigurationLaunchInstancePlatformConfigTypeAmdRomeBm InstanceConfigurationLaunchInstancePlatformConfigTypeEnum = "AMD_ROME_BM" + InstanceConfigurationLaunchInstancePlatformConfigTypeIntelSkylakeBm InstanceConfigurationLaunchInstancePlatformConfigTypeEnum = "INTEL_SKYLAKE_BM" + InstanceConfigurationLaunchInstancePlatformConfigTypeAmdVm InstanceConfigurationLaunchInstancePlatformConfigTypeEnum = "AMD_VM" + InstanceConfigurationLaunchInstancePlatformConfigTypeIntelVm InstanceConfigurationLaunchInstancePlatformConfigTypeEnum = "INTEL_VM" +) + +var mappingInstanceConfigurationLaunchInstancePlatformConfigType = map[string]InstanceConfigurationLaunchInstancePlatformConfigTypeEnum{ + "AMD_MILAN_BM": InstanceConfigurationLaunchInstancePlatformConfigTypeAmdMilanBm, + "AMD_ROME_BM": InstanceConfigurationLaunchInstancePlatformConfigTypeAmdRomeBm, + "INTEL_SKYLAKE_BM": InstanceConfigurationLaunchInstancePlatformConfigTypeIntelSkylakeBm, + "AMD_VM": InstanceConfigurationLaunchInstancePlatformConfigTypeAmdVm, + "INTEL_VM": InstanceConfigurationLaunchInstancePlatformConfigTypeIntelVm, +} + +// GetInstanceConfigurationLaunchInstancePlatformConfigTypeEnumValues Enumerates the set of values for InstanceConfigurationLaunchInstancePlatformConfigTypeEnum +func GetInstanceConfigurationLaunchInstancePlatformConfigTypeEnumValues() []InstanceConfigurationLaunchInstancePlatformConfigTypeEnum { + values := make([]InstanceConfigurationLaunchInstancePlatformConfigTypeEnum, 0) + for _, v := range mappingInstanceConfigurationLaunchInstancePlatformConfigType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_shape_config_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_shape_config_details.go new file mode 100644 index 000000000..d86935441 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_instance_shape_config_details.go @@ -0,0 +1,71 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationLaunchInstanceShapeConfigDetails The shape configuration requested for the instance. +// If the parameter is provided, the instance is created +// with the resources that you specify. If some properties are missing or +// the entire parameter is not provided, the instance is created with the default +// configuration values for the `shape` that you specify. +// Each shape only supports certain configurable values. If the values that you provide are not valid for the +// specified `shape`, an error is returned. +type InstanceConfigurationLaunchInstanceShapeConfigDetails struct { + + // The total number of OCPUs available to the instance. + Ocpus *float32 `mandatory:"false" json:"ocpus"` + + // The total amount of memory available to the instance, in gigabytes. + MemoryInGBs *float32 `mandatory:"false" json:"memoryInGBs"` + + // The baseline OCPU utilization for a subcore burstable VM instance. Leave this attribute blank for a + // non-burstable instance, or explicitly specify non-burstable with `BASELINE_1_1`. + // The following values are supported: + // - `BASELINE_1_8` - baseline usage is 1/8 of an OCPU. + // - `BASELINE_1_2` - baseline usage is 1/2 of an OCPU. + // - `BASELINE_1_1` - baseline usage is an entire OCPU. This represents a non-burstable instance. + BaselineOcpuUtilization InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum `mandatory:"false" json:"baselineOcpuUtilization,omitempty"` +} + +func (m InstanceConfigurationLaunchInstanceShapeConfigDetails) String() string { + return common.PointerString(m) +} + +// InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum Enum with underlying type: string +type InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum string + +// Set of constants representing the allowable values for InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum +const ( + InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilization8 InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum = "BASELINE_1_8" + InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilization2 InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum = "BASELINE_1_2" + InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilization1 InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum = "BASELINE_1_1" +) + +var mappingInstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilization = map[string]InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum{ + "BASELINE_1_8": InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilization8, + "BASELINE_1_2": InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilization2, + "BASELINE_1_1": InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilization1, +} + +// GetInstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnumValues Enumerates the set of values for InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum +func GetInstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnumValues() []InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum { + values := make([]InstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum, 0) + for _, v := range mappingInstanceConfigurationLaunchInstanceShapeConfigDetailsBaselineOcpuUtilization { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_options.go new file mode 100644 index 000000000..c0b205f11 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_launch_options.go @@ -0,0 +1,174 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationLaunchOptions Options for tuning the compatibility and performance of VM shapes. The values that you specify override any +// default values. +type InstanceConfigurationLaunchOptions struct { + + // Emulation type for the boot volume. + // * `ISCSI` - ISCSI attached block storage device. + // * `SCSI` - Emulated SCSI disk. + // * `IDE` - Emulated IDE disk. + // * `VFIO` - Direct attached Virtual Function storage. This is the default option for local data + // volumes on platform images. + // * `PARAVIRTUALIZED` - Paravirtualized disk. This is the default for boot volumes and remote block + // storage volumes on platform images. + BootVolumeType InstanceConfigurationLaunchOptionsBootVolumeTypeEnum `mandatory:"false" json:"bootVolumeType,omitempty"` + + // Firmware used to boot VM. Select the option that matches your operating system. + // * `BIOS` - Boot VM using BIOS style firmware. This is compatible with both 32 bit and 64 bit operating + // systems that boot using MBR style bootloaders. + // * `UEFI_64` - Boot VM using UEFI style firmware compatible with 64 bit operating systems. This is the + // default for platform images. + Firmware InstanceConfigurationLaunchOptionsFirmwareEnum `mandatory:"false" json:"firmware,omitempty"` + + // Emulation type for the physical network interface card (NIC). + // * `E1000` - Emulated Gigabit ethernet controller. Compatible with Linux e1000 network driver. + // * `VFIO` - Direct attached Virtual Function network controller. This is the networking type + // when you launch an instance using hardware-assisted (SR-IOV) networking. + // * `PARAVIRTUALIZED` - VM instances launch with paravirtualized devices using VirtIO drivers. + NetworkType InstanceConfigurationLaunchOptionsNetworkTypeEnum `mandatory:"false" json:"networkType,omitempty"` + + // Emulation type for volume. + // * `ISCSI` - ISCSI attached block storage device. + // * `SCSI` - Emulated SCSI disk. + // * `IDE` - Emulated IDE disk. + // * `VFIO` - Direct attached Virtual Function storage. This is the default option for local data + // volumes on platform images. + // * `PARAVIRTUALIZED` - Paravirtualized disk. This is the default for boot volumes and remote block + // storage volumes on platform images. + RemoteDataVolumeType InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeEnum `mandatory:"false" json:"remoteDataVolumeType,omitempty"` + + // Deprecated. Instead use `isPvEncryptionInTransitEnabled` in + // InstanceConfigurationLaunchInstanceDetails. + IsPvEncryptionInTransitEnabled *bool `mandatory:"false" json:"isPvEncryptionInTransitEnabled"` + + // Whether to enable consistent volume naming feature. Defaults to false. + IsConsistentVolumeNamingEnabled *bool `mandatory:"false" json:"isConsistentVolumeNamingEnabled"` +} + +func (m InstanceConfigurationLaunchOptions) String() string { + return common.PointerString(m) +} + +// InstanceConfigurationLaunchOptionsBootVolumeTypeEnum Enum with underlying type: string +type InstanceConfigurationLaunchOptionsBootVolumeTypeEnum string + +// Set of constants representing the allowable values for InstanceConfigurationLaunchOptionsBootVolumeTypeEnum +const ( + InstanceConfigurationLaunchOptionsBootVolumeTypeIscsi InstanceConfigurationLaunchOptionsBootVolumeTypeEnum = "ISCSI" + InstanceConfigurationLaunchOptionsBootVolumeTypeScsi InstanceConfigurationLaunchOptionsBootVolumeTypeEnum = "SCSI" + InstanceConfigurationLaunchOptionsBootVolumeTypeIde InstanceConfigurationLaunchOptionsBootVolumeTypeEnum = "IDE" + InstanceConfigurationLaunchOptionsBootVolumeTypeVfio InstanceConfigurationLaunchOptionsBootVolumeTypeEnum = "VFIO" + InstanceConfigurationLaunchOptionsBootVolumeTypeParavirtualized InstanceConfigurationLaunchOptionsBootVolumeTypeEnum = "PARAVIRTUALIZED" +) + +var mappingInstanceConfigurationLaunchOptionsBootVolumeType = map[string]InstanceConfigurationLaunchOptionsBootVolumeTypeEnum{ + "ISCSI": InstanceConfigurationLaunchOptionsBootVolumeTypeIscsi, + "SCSI": InstanceConfigurationLaunchOptionsBootVolumeTypeScsi, + "IDE": InstanceConfigurationLaunchOptionsBootVolumeTypeIde, + "VFIO": InstanceConfigurationLaunchOptionsBootVolumeTypeVfio, + "PARAVIRTUALIZED": InstanceConfigurationLaunchOptionsBootVolumeTypeParavirtualized, +} + +// GetInstanceConfigurationLaunchOptionsBootVolumeTypeEnumValues Enumerates the set of values for InstanceConfigurationLaunchOptionsBootVolumeTypeEnum +func GetInstanceConfigurationLaunchOptionsBootVolumeTypeEnumValues() []InstanceConfigurationLaunchOptionsBootVolumeTypeEnum { + values := make([]InstanceConfigurationLaunchOptionsBootVolumeTypeEnum, 0) + for _, v := range mappingInstanceConfigurationLaunchOptionsBootVolumeType { + values = append(values, v) + } + return values +} + +// InstanceConfigurationLaunchOptionsFirmwareEnum Enum with underlying type: string +type InstanceConfigurationLaunchOptionsFirmwareEnum string + +// Set of constants representing the allowable values for InstanceConfigurationLaunchOptionsFirmwareEnum +const ( + InstanceConfigurationLaunchOptionsFirmwareBios InstanceConfigurationLaunchOptionsFirmwareEnum = "BIOS" + InstanceConfigurationLaunchOptionsFirmwareUefi64 InstanceConfigurationLaunchOptionsFirmwareEnum = "UEFI_64" +) + +var mappingInstanceConfigurationLaunchOptionsFirmware = map[string]InstanceConfigurationLaunchOptionsFirmwareEnum{ + "BIOS": InstanceConfigurationLaunchOptionsFirmwareBios, + "UEFI_64": InstanceConfigurationLaunchOptionsFirmwareUefi64, +} + +// GetInstanceConfigurationLaunchOptionsFirmwareEnumValues Enumerates the set of values for InstanceConfigurationLaunchOptionsFirmwareEnum +func GetInstanceConfigurationLaunchOptionsFirmwareEnumValues() []InstanceConfigurationLaunchOptionsFirmwareEnum { + values := make([]InstanceConfigurationLaunchOptionsFirmwareEnum, 0) + for _, v := range mappingInstanceConfigurationLaunchOptionsFirmware { + values = append(values, v) + } + return values +} + +// InstanceConfigurationLaunchOptionsNetworkTypeEnum Enum with underlying type: string +type InstanceConfigurationLaunchOptionsNetworkTypeEnum string + +// Set of constants representing the allowable values for InstanceConfigurationLaunchOptionsNetworkTypeEnum +const ( + InstanceConfigurationLaunchOptionsNetworkTypeE1000 InstanceConfigurationLaunchOptionsNetworkTypeEnum = "E1000" + InstanceConfigurationLaunchOptionsNetworkTypeVfio InstanceConfigurationLaunchOptionsNetworkTypeEnum = "VFIO" + InstanceConfigurationLaunchOptionsNetworkTypeParavirtualized InstanceConfigurationLaunchOptionsNetworkTypeEnum = "PARAVIRTUALIZED" +) + +var mappingInstanceConfigurationLaunchOptionsNetworkType = map[string]InstanceConfigurationLaunchOptionsNetworkTypeEnum{ + "E1000": InstanceConfigurationLaunchOptionsNetworkTypeE1000, + "VFIO": InstanceConfigurationLaunchOptionsNetworkTypeVfio, + "PARAVIRTUALIZED": InstanceConfigurationLaunchOptionsNetworkTypeParavirtualized, +} + +// GetInstanceConfigurationLaunchOptionsNetworkTypeEnumValues Enumerates the set of values for InstanceConfigurationLaunchOptionsNetworkTypeEnum +func GetInstanceConfigurationLaunchOptionsNetworkTypeEnumValues() []InstanceConfigurationLaunchOptionsNetworkTypeEnum { + values := make([]InstanceConfigurationLaunchOptionsNetworkTypeEnum, 0) + for _, v := range mappingInstanceConfigurationLaunchOptionsNetworkType { + values = append(values, v) + } + return values +} + +// InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeEnum Enum with underlying type: string +type InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeEnum string + +// Set of constants representing the allowable values for InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeEnum +const ( + InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeIscsi InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeEnum = "ISCSI" + InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeScsi InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeEnum = "SCSI" + InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeIde InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeEnum = "IDE" + InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeVfio InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeEnum = "VFIO" + InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeParavirtualized InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeEnum = "PARAVIRTUALIZED" +) + +var mappingInstanceConfigurationLaunchOptionsRemoteDataVolumeType = map[string]InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeEnum{ + "ISCSI": InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeIscsi, + "SCSI": InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeScsi, + "IDE": InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeIde, + "VFIO": InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeVfio, + "PARAVIRTUALIZED": InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeParavirtualized, +} + +// GetInstanceConfigurationLaunchOptionsRemoteDataVolumeTypeEnumValues Enumerates the set of values for InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeEnum +func GetInstanceConfigurationLaunchOptionsRemoteDataVolumeTypeEnumValues() []InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeEnum { + values := make([]InstanceConfigurationLaunchOptionsRemoteDataVolumeTypeEnum, 0) + for _, v := range mappingInstanceConfigurationLaunchOptionsRemoteDataVolumeType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_paravirtualized_attach_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_paravirtualized_attach_volume_details.go new file mode 100644 index 000000000..ba6da1c75 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_paravirtualized_attach_volume_details.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationParavirtualizedAttachVolumeDetails The representation of InstanceConfigurationParavirtualizedAttachVolumeDetails +type InstanceConfigurationParavirtualizedAttachVolumeDetails struct { + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Whether the attachment should be created in read-only mode. + IsReadOnly *bool `mandatory:"false" json:"isReadOnly"` + + // The device name. + Device *string `mandatory:"false" json:"device"` + + // Whether the attachment should be created in shareable mode. If an attachment + // is created in shareable mode, then other instances can attach the same volume, provided + // that they also create their attachments in shareable mode. Only certain volume types can + // be attached in shareable mode. Defaults to false if not specified. + IsShareable *bool `mandatory:"false" json:"isShareable"` + + // Whether to enable in-transit encryption for the data volume's paravirtualized attachment. The default value is false. + IsPvEncryptionInTransitEnabled *bool `mandatory:"false" json:"isPvEncryptionInTransitEnabled"` +} + +//GetDisplayName returns DisplayName +func (m InstanceConfigurationParavirtualizedAttachVolumeDetails) GetDisplayName() *string { + return m.DisplayName +} + +//GetIsReadOnly returns IsReadOnly +func (m InstanceConfigurationParavirtualizedAttachVolumeDetails) GetIsReadOnly() *bool { + return m.IsReadOnly +} + +//GetDevice returns Device +func (m InstanceConfigurationParavirtualizedAttachVolumeDetails) GetDevice() *string { + return m.Device +} + +//GetIsShareable returns IsShareable +func (m InstanceConfigurationParavirtualizedAttachVolumeDetails) GetIsShareable() *bool { + return m.IsShareable +} + +func (m InstanceConfigurationParavirtualizedAttachVolumeDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m InstanceConfigurationParavirtualizedAttachVolumeDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeInstanceConfigurationParavirtualizedAttachVolumeDetails InstanceConfigurationParavirtualizedAttachVolumeDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeInstanceConfigurationParavirtualizedAttachVolumeDetails + }{ + "paravirtualized", + (MarshalTypeInstanceConfigurationParavirtualizedAttachVolumeDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_summary.go new file mode 100644 index 000000000..011abb1c3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_summary.go @@ -0,0 +1,50 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationSummary Summary information for an instance configuration. +type InstanceConfigurationSummary struct { + + // The OCID of the compartment containing the instance configuration. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the instance configuration. + Id *string `mandatory:"true" json:"id"` + + // The date and time the instance configuration was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m InstanceConfigurationSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_volume_source_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_volume_source_details.go new file mode 100644 index 000000000..57e9ac24d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_volume_source_details.go @@ -0,0 +1,70 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationVolumeSourceDetails The representation of InstanceConfigurationVolumeSourceDetails +type InstanceConfigurationVolumeSourceDetails interface { +} + +type instanceconfigurationvolumesourcedetails struct { + JsonData []byte + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *instanceconfigurationvolumesourcedetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerinstanceconfigurationvolumesourcedetails instanceconfigurationvolumesourcedetails + s := struct { + Model Unmarshalerinstanceconfigurationvolumesourcedetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *instanceconfigurationvolumesourcedetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "volumeBackup": + mm := InstanceConfigurationVolumeSourceFromVolumeBackupDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "volume": + mm := InstanceConfigurationVolumeSourceFromVolumeDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +func (m instanceconfigurationvolumesourcedetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_volume_source_from_volume_backup_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_volume_source_from_volume_backup_details.go new file mode 100644 index 000000000..01deccc59 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_volume_source_from_volume_backup_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationVolumeSourceFromVolumeBackupDetails Specifies the volume backup. +type InstanceConfigurationVolumeSourceFromVolumeBackupDetails struct { + + // The OCID of the volume backup. + Id *string `mandatory:"false" json:"id"` +} + +func (m InstanceConfigurationVolumeSourceFromVolumeBackupDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m InstanceConfigurationVolumeSourceFromVolumeBackupDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeInstanceConfigurationVolumeSourceFromVolumeBackupDetails InstanceConfigurationVolumeSourceFromVolumeBackupDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeInstanceConfigurationVolumeSourceFromVolumeBackupDetails + }{ + "volumeBackup", + (MarshalTypeInstanceConfigurationVolumeSourceFromVolumeBackupDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_volume_source_from_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_volume_source_from_volume_details.go new file mode 100644 index 000000000..564477555 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_configuration_volume_source_from_volume_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConfigurationVolumeSourceFromVolumeDetails Specifies the source volume. +type InstanceConfigurationVolumeSourceFromVolumeDetails struct { + + // The OCID of the volume. + Id *string `mandatory:"false" json:"id"` +} + +func (m InstanceConfigurationVolumeSourceFromVolumeDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m InstanceConfigurationVolumeSourceFromVolumeDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeInstanceConfigurationVolumeSourceFromVolumeDetails InstanceConfigurationVolumeSourceFromVolumeDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeInstanceConfigurationVolumeSourceFromVolumeDetails + }{ + "volume", + (MarshalTypeInstanceConfigurationVolumeSourceFromVolumeDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_console_connection.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_console_connection.go new file mode 100644 index 000000000..765da7630 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_console_connection.go @@ -0,0 +1,92 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceConsoleConnection The `InstanceConsoleConnection` API provides you with console access to Compute instances, +// enabling you to troubleshoot malfunctioning instances remotely. +// For more information about instance console connections, see Troubleshooting Instances Using Instance Console Connections (https://docs.cloud.oracle.com/iaas/Content/Compute/References/serialconsole.htm). +type InstanceConsoleConnection struct { + + // The OCID of the compartment to contain the console connection. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The SSH connection string for the console connection. + ConnectionString *string `mandatory:"false" json:"connectionString"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // The SSH public key's fingerprint for client authentication to the console connection. + Fingerprint *string `mandatory:"false" json:"fingerprint"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID of the console connection. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the instance the console connection connects to. + InstanceId *string `mandatory:"false" json:"instanceId"` + + // The current state of the console connection. + LifecycleState InstanceConsoleConnectionLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The SSH public key's fingerprint for the console connection service host. + ServiceHostKeyFingerprint *string `mandatory:"false" json:"serviceHostKeyFingerprint"` + + // The SSH connection string for the SSH tunnel used to + // connect to the console connection over VNC. + VncConnectionString *string `mandatory:"false" json:"vncConnectionString"` +} + +func (m InstanceConsoleConnection) String() string { + return common.PointerString(m) +} + +// InstanceConsoleConnectionLifecycleStateEnum Enum with underlying type: string +type InstanceConsoleConnectionLifecycleStateEnum string + +// Set of constants representing the allowable values for InstanceConsoleConnectionLifecycleStateEnum +const ( + InstanceConsoleConnectionLifecycleStateActive InstanceConsoleConnectionLifecycleStateEnum = "ACTIVE" + InstanceConsoleConnectionLifecycleStateCreating InstanceConsoleConnectionLifecycleStateEnum = "CREATING" + InstanceConsoleConnectionLifecycleStateDeleted InstanceConsoleConnectionLifecycleStateEnum = "DELETED" + InstanceConsoleConnectionLifecycleStateDeleting InstanceConsoleConnectionLifecycleStateEnum = "DELETING" + InstanceConsoleConnectionLifecycleStateFailed InstanceConsoleConnectionLifecycleStateEnum = "FAILED" +) + +var mappingInstanceConsoleConnectionLifecycleState = map[string]InstanceConsoleConnectionLifecycleStateEnum{ + "ACTIVE": InstanceConsoleConnectionLifecycleStateActive, + "CREATING": InstanceConsoleConnectionLifecycleStateCreating, + "DELETED": InstanceConsoleConnectionLifecycleStateDeleted, + "DELETING": InstanceConsoleConnectionLifecycleStateDeleting, + "FAILED": InstanceConsoleConnectionLifecycleStateFailed, +} + +// GetInstanceConsoleConnectionLifecycleStateEnumValues Enumerates the set of values for InstanceConsoleConnectionLifecycleStateEnum +func GetInstanceConsoleConnectionLifecycleStateEnumValues() []InstanceConsoleConnectionLifecycleStateEnum { + values := make([]InstanceConsoleConnectionLifecycleStateEnum, 0) + for _, v := range mappingInstanceConsoleConnectionLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_credentials.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_credentials.go new file mode 100644 index 000000000..c979343ec --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_credentials.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceCredentials The credentials for a particular instance. +type InstanceCredentials struct { + + // The password for the username. + Password *string `mandatory:"true" json:"password"` + + // The username. + Username *string `mandatory:"true" json:"username"` +} + +func (m InstanceCredentials) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_options.go new file mode 100644 index 000000000..b9556c808 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_options.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceOptions Optional mutable instance options +type InstanceOptions struct { + + // Whether to disable the legacy (/v1) instance metadata service endpoints. + // Customers who have migrated to /v2 should set this to true for added security. + // Default is false. + AreLegacyImdsEndpointsDisabled *bool `mandatory:"false" json:"areLegacyImdsEndpointsDisabled"` +} + +func (m InstanceOptions) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool.go new file mode 100644 index 000000000..5b8c49f54 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool.go @@ -0,0 +1,104 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstancePool An instance pool is a set of instances within the same region that are managed as a group. +// For more information about instance pools and instance configurations, see +// Managing Compute Instances (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/instancemanagement.htm). +type InstancePool struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + Id *string `mandatory:"true" json:"id"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the instance + // pool. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance configuration associated + // with the instance pool. + InstanceConfigurationId *string `mandatory:"true" json:"instanceConfigurationId"` + + // The current state of the instance pool. + LifecycleState InstancePoolLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The placement configurations for the instance pool. + PlacementConfigurations []InstancePoolPlacementConfiguration `mandatory:"true" json:"placementConfigurations"` + + // The number of instances that should be in the instance pool. + Size *int `mandatory:"true" json:"size"` + + // The date and time the instance pool was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The load balancers attached to the instance pool. + LoadBalancers []InstancePoolLoadBalancerAttachment `mandatory:"false" json:"loadBalancers"` +} + +func (m InstancePool) String() string { + return common.PointerString(m) +} + +// InstancePoolLifecycleStateEnum Enum with underlying type: string +type InstancePoolLifecycleStateEnum string + +// Set of constants representing the allowable values for InstancePoolLifecycleStateEnum +const ( + InstancePoolLifecycleStateProvisioning InstancePoolLifecycleStateEnum = "PROVISIONING" + InstancePoolLifecycleStateScaling InstancePoolLifecycleStateEnum = "SCALING" + InstancePoolLifecycleStateStarting InstancePoolLifecycleStateEnum = "STARTING" + InstancePoolLifecycleStateStopping InstancePoolLifecycleStateEnum = "STOPPING" + InstancePoolLifecycleStateTerminating InstancePoolLifecycleStateEnum = "TERMINATING" + InstancePoolLifecycleStateStopped InstancePoolLifecycleStateEnum = "STOPPED" + InstancePoolLifecycleStateTerminated InstancePoolLifecycleStateEnum = "TERMINATED" + InstancePoolLifecycleStateRunning InstancePoolLifecycleStateEnum = "RUNNING" +) + +var mappingInstancePoolLifecycleState = map[string]InstancePoolLifecycleStateEnum{ + "PROVISIONING": InstancePoolLifecycleStateProvisioning, + "SCALING": InstancePoolLifecycleStateScaling, + "STARTING": InstancePoolLifecycleStateStarting, + "STOPPING": InstancePoolLifecycleStateStopping, + "TERMINATING": InstancePoolLifecycleStateTerminating, + "STOPPED": InstancePoolLifecycleStateStopped, + "TERMINATED": InstancePoolLifecycleStateTerminated, + "RUNNING": InstancePoolLifecycleStateRunning, +} + +// GetInstancePoolLifecycleStateEnumValues Enumerates the set of values for InstancePoolLifecycleStateEnum +func GetInstancePoolLifecycleStateEnumValues() []InstancePoolLifecycleStateEnum { + values := make([]InstancePoolLifecycleStateEnum, 0) + for _, v := range mappingInstancePoolLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_instance.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_instance.go new file mode 100644 index 000000000..37ffc70b3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_instance.go @@ -0,0 +1,95 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstancePoolInstance Information about an instance that belongs to an instance pool. +type InstancePoolInstance struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance. + Id *string `mandatory:"true" json:"id"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" json:"instancePoolId"` + + // The availability domain the instance is running in. + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The attachment state of the instance in relation to the instance pool. + LifecycleState InstancePoolInstanceLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment that contains the + // instance. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance configuration + // used to create the instance. + InstanceConfigurationId *string `mandatory:"true" json:"instanceConfigurationId"` + + // The region that contains the availability domain the instance is running in. + Region *string `mandatory:"true" json:"region"` + + // The shape of the instance. The shape determines the number of CPUs, amount of memory, + // and other resources allocated to the instance. + Shape *string `mandatory:"true" json:"shape"` + + // The lifecycle state of the instance. Refer to `lifecycleState` in the Instance resource. + State *string `mandatory:"true" json:"state"` + + // The date and time the instance pool instance was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The fault domain the instance is running in. + FaultDomain *string `mandatory:"false" json:"faultDomain"` + + // The load balancer backends that are configured for the instance. + LoadBalancerBackends []InstancePoolInstanceLoadBalancerBackend `mandatory:"false" json:"loadBalancerBackends"` +} + +func (m InstancePoolInstance) String() string { + return common.PointerString(m) +} + +// InstancePoolInstanceLifecycleStateEnum Enum with underlying type: string +type InstancePoolInstanceLifecycleStateEnum string + +// Set of constants representing the allowable values for InstancePoolInstanceLifecycleStateEnum +const ( + InstancePoolInstanceLifecycleStateAttaching InstancePoolInstanceLifecycleStateEnum = "ATTACHING" + InstancePoolInstanceLifecycleStateActive InstancePoolInstanceLifecycleStateEnum = "ACTIVE" + InstancePoolInstanceLifecycleStateDetaching InstancePoolInstanceLifecycleStateEnum = "DETACHING" +) + +var mappingInstancePoolInstanceLifecycleState = map[string]InstancePoolInstanceLifecycleStateEnum{ + "ATTACHING": InstancePoolInstanceLifecycleStateAttaching, + "ACTIVE": InstancePoolInstanceLifecycleStateActive, + "DETACHING": InstancePoolInstanceLifecycleStateDetaching, +} + +// GetInstancePoolInstanceLifecycleStateEnumValues Enumerates the set of values for InstancePoolInstanceLifecycleStateEnum +func GetInstancePoolInstanceLifecycleStateEnumValues() []InstancePoolInstanceLifecycleStateEnum { + values := make([]InstancePoolInstanceLifecycleStateEnum, 0) + for _, v := range mappingInstancePoolInstanceLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_instance_load_balancer_backend.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_instance_load_balancer_backend.go new file mode 100644 index 000000000..954666e7e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_instance_load_balancer_backend.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstancePoolInstanceLoadBalancerBackend Represents the load balancer Backend that is configured for an instance pool instance. +type InstancePoolInstanceLoadBalancerBackend struct { + + // The OCID of the load balancer attached to the instance pool. + LoadBalancerId *string `mandatory:"true" json:"loadBalancerId"` + + // The name of the backend set on the load balancer. + BackendSetName *string `mandatory:"true" json:"backendSetName"` + + // The name of the backend in the backend set. + BackendName *string `mandatory:"true" json:"backendName"` + + // The health of the backend as observed by the load balancer. + BackendHealthStatus InstancePoolInstanceLoadBalancerBackendBackendHealthStatusEnum `mandatory:"true" json:"backendHealthStatus"` +} + +func (m InstancePoolInstanceLoadBalancerBackend) String() string { + return common.PointerString(m) +} + +// InstancePoolInstanceLoadBalancerBackendBackendHealthStatusEnum Enum with underlying type: string +type InstancePoolInstanceLoadBalancerBackendBackendHealthStatusEnum string + +// Set of constants representing the allowable values for InstancePoolInstanceLoadBalancerBackendBackendHealthStatusEnum +const ( + InstancePoolInstanceLoadBalancerBackendBackendHealthStatusOk InstancePoolInstanceLoadBalancerBackendBackendHealthStatusEnum = "OK" + InstancePoolInstanceLoadBalancerBackendBackendHealthStatusWarning InstancePoolInstanceLoadBalancerBackendBackendHealthStatusEnum = "WARNING" + InstancePoolInstanceLoadBalancerBackendBackendHealthStatusCritical InstancePoolInstanceLoadBalancerBackendBackendHealthStatusEnum = "CRITICAL" + InstancePoolInstanceLoadBalancerBackendBackendHealthStatusUnknown InstancePoolInstanceLoadBalancerBackendBackendHealthStatusEnum = "UNKNOWN" +) + +var mappingInstancePoolInstanceLoadBalancerBackendBackendHealthStatus = map[string]InstancePoolInstanceLoadBalancerBackendBackendHealthStatusEnum{ + "OK": InstancePoolInstanceLoadBalancerBackendBackendHealthStatusOk, + "WARNING": InstancePoolInstanceLoadBalancerBackendBackendHealthStatusWarning, + "CRITICAL": InstancePoolInstanceLoadBalancerBackendBackendHealthStatusCritical, + "UNKNOWN": InstancePoolInstanceLoadBalancerBackendBackendHealthStatusUnknown, +} + +// GetInstancePoolInstanceLoadBalancerBackendBackendHealthStatusEnumValues Enumerates the set of values for InstancePoolInstanceLoadBalancerBackendBackendHealthStatusEnum +func GetInstancePoolInstanceLoadBalancerBackendBackendHealthStatusEnumValues() []InstancePoolInstanceLoadBalancerBackendBackendHealthStatusEnum { + values := make([]InstancePoolInstanceLoadBalancerBackendBackendHealthStatusEnum, 0) + for _, v := range mappingInstancePoolInstanceLoadBalancerBackendBackendHealthStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_load_balancer_attachment.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_load_balancer_attachment.go new file mode 100644 index 000000000..6427ad31a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_load_balancer_attachment.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstancePoolLoadBalancerAttachment Represents a load balancer that is attached to an instance pool. +type InstancePoolLoadBalancerAttachment struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the load balancer attachment. + Id *string `mandatory:"true" json:"id"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool of the load balancer attachment. + InstancePoolId *string `mandatory:"true" json:"instancePoolId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the load balancer attached to the instance pool. + LoadBalancerId *string `mandatory:"true" json:"loadBalancerId"` + + // The name of the backend set on the load balancer. + BackendSetName *string `mandatory:"true" json:"backendSetName"` + + // The port value used for the backends. + Port *int `mandatory:"true" json:"port"` + + // Indicates which VNIC on each instance in the instance pool should be used to associate with the load balancer. + // Possible values are "PrimaryVnic" or the displayName of one of the secondary VNICs on the instance configuration + // that is associated with the instance pool. + VnicSelection *string `mandatory:"true" json:"vnicSelection"` + + // The status of the interaction between the instance pool and the load balancer. + LifecycleState InstancePoolLoadBalancerAttachmentLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` +} + +func (m InstancePoolLoadBalancerAttachment) String() string { + return common.PointerString(m) +} + +// InstancePoolLoadBalancerAttachmentLifecycleStateEnum Enum with underlying type: string +type InstancePoolLoadBalancerAttachmentLifecycleStateEnum string + +// Set of constants representing the allowable values for InstancePoolLoadBalancerAttachmentLifecycleStateEnum +const ( + InstancePoolLoadBalancerAttachmentLifecycleStateAttaching InstancePoolLoadBalancerAttachmentLifecycleStateEnum = "ATTACHING" + InstancePoolLoadBalancerAttachmentLifecycleStateAttached InstancePoolLoadBalancerAttachmentLifecycleStateEnum = "ATTACHED" + InstancePoolLoadBalancerAttachmentLifecycleStateDetaching InstancePoolLoadBalancerAttachmentLifecycleStateEnum = "DETACHING" + InstancePoolLoadBalancerAttachmentLifecycleStateDetached InstancePoolLoadBalancerAttachmentLifecycleStateEnum = "DETACHED" +) + +var mappingInstancePoolLoadBalancerAttachmentLifecycleState = map[string]InstancePoolLoadBalancerAttachmentLifecycleStateEnum{ + "ATTACHING": InstancePoolLoadBalancerAttachmentLifecycleStateAttaching, + "ATTACHED": InstancePoolLoadBalancerAttachmentLifecycleStateAttached, + "DETACHING": InstancePoolLoadBalancerAttachmentLifecycleStateDetaching, + "DETACHED": InstancePoolLoadBalancerAttachmentLifecycleStateDetached, +} + +// GetInstancePoolLoadBalancerAttachmentLifecycleStateEnumValues Enumerates the set of values for InstancePoolLoadBalancerAttachmentLifecycleStateEnum +func GetInstancePoolLoadBalancerAttachmentLifecycleStateEnumValues() []InstancePoolLoadBalancerAttachmentLifecycleStateEnum { + values := make([]InstancePoolLoadBalancerAttachmentLifecycleStateEnum, 0) + for _, v := range mappingInstancePoolLoadBalancerAttachmentLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_placement_configuration.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_placement_configuration.go new file mode 100644 index 000000000..9dc8d1c57 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_placement_configuration.go @@ -0,0 +1,48 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstancePoolPlacementConfiguration The location for where an instance pool will place instances. +type InstancePoolPlacementConfiguration struct { + + // The availability domain to place instances. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the primary subnet to place instances. + PrimarySubnetId *string `mandatory:"true" json:"primarySubnetId"` + + // The fault domains to place instances. + // If you don't provide any values, the system makes a best effort to distribute + // instances across all fault domains based on capacity. + // To distribute the instances evenly across selected fault domains, provide a + // set of fault domains. For example, you might want instances to be evenly + // distributed if your applications require high availability. + // To get a list of fault domains, use the + // ListFaultDomains operation + // in the Identity and Access Management Service API. + // Example: `[FAULT-DOMAIN-1, FAULT-DOMAIN-2, FAULT-DOMAIN-3]` + FaultDomains []string `mandatory:"false" json:"faultDomains"` + + // The set of secondary VNIC data for instances in the pool. + SecondaryVnicSubnets []InstancePoolPlacementSecondaryVnicSubnet `mandatory:"false" json:"secondaryVnicSubnets"` +} + +func (m InstancePoolPlacementConfiguration) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_placement_secondary_vnic_subnet.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_placement_secondary_vnic_subnet.go new file mode 100644 index 000000000..063989e02 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_placement_secondary_vnic_subnet.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstancePoolPlacementSecondaryVnicSubnet The secondary VNIC object for the placement configuration for an instance pool. +type InstancePoolPlacementSecondaryVnicSubnet struct { + + // The subnet OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) for the secondary VNIC. + SubnetId *string `mandatory:"true" json:"subnetId"` + + // The display name of the VNIC. This is also use to match against the instance configuration defined + // secondary VNIC. + DisplayName *string `mandatory:"false" json:"displayName"` +} + +func (m InstancePoolPlacementSecondaryVnicSubnet) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_summary.go new file mode 100644 index 000000000..ea9c30720 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_pool_summary.go @@ -0,0 +1,97 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstancePoolSummary Summary information for an instance pool. +type InstancePoolSummary struct { + + // The OCID of the instance pool. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the compartment containing the instance pool. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the instance configuration associated with the instance pool. + InstanceConfigurationId *string `mandatory:"true" json:"instanceConfigurationId"` + + // The current state of the instance pool. + LifecycleState InstancePoolSummaryLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The availability domains for the instance pool. + AvailabilityDomains []string `mandatory:"true" json:"availabilityDomains"` + + // The number of instances that should be in the instance pool. + Size *int `mandatory:"true" json:"size"` + + // The date and time the instance pool was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m InstancePoolSummary) String() string { + return common.PointerString(m) +} + +// InstancePoolSummaryLifecycleStateEnum Enum with underlying type: string +type InstancePoolSummaryLifecycleStateEnum string + +// Set of constants representing the allowable values for InstancePoolSummaryLifecycleStateEnum +const ( + InstancePoolSummaryLifecycleStateProvisioning InstancePoolSummaryLifecycleStateEnum = "PROVISIONING" + InstancePoolSummaryLifecycleStateScaling InstancePoolSummaryLifecycleStateEnum = "SCALING" + InstancePoolSummaryLifecycleStateStarting InstancePoolSummaryLifecycleStateEnum = "STARTING" + InstancePoolSummaryLifecycleStateStopping InstancePoolSummaryLifecycleStateEnum = "STOPPING" + InstancePoolSummaryLifecycleStateTerminating InstancePoolSummaryLifecycleStateEnum = "TERMINATING" + InstancePoolSummaryLifecycleStateStopped InstancePoolSummaryLifecycleStateEnum = "STOPPED" + InstancePoolSummaryLifecycleStateTerminated InstancePoolSummaryLifecycleStateEnum = "TERMINATED" + InstancePoolSummaryLifecycleStateRunning InstancePoolSummaryLifecycleStateEnum = "RUNNING" +) + +var mappingInstancePoolSummaryLifecycleState = map[string]InstancePoolSummaryLifecycleStateEnum{ + "PROVISIONING": InstancePoolSummaryLifecycleStateProvisioning, + "SCALING": InstancePoolSummaryLifecycleStateScaling, + "STARTING": InstancePoolSummaryLifecycleStateStarting, + "STOPPING": InstancePoolSummaryLifecycleStateStopping, + "TERMINATING": InstancePoolSummaryLifecycleStateTerminating, + "STOPPED": InstancePoolSummaryLifecycleStateStopped, + "TERMINATED": InstancePoolSummaryLifecycleStateTerminated, + "RUNNING": InstancePoolSummaryLifecycleStateRunning, +} + +// GetInstancePoolSummaryLifecycleStateEnumValues Enumerates the set of values for InstancePoolSummaryLifecycleStateEnum +func GetInstancePoolSummaryLifecycleStateEnumValues() []InstancePoolSummaryLifecycleStateEnum { + values := make([]InstancePoolSummaryLifecycleStateEnum, 0) + for _, v := range mappingInstancePoolSummaryLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_reservation_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_reservation_config.go new file mode 100644 index 000000000..05d54dd21 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_reservation_config.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceReservationConfig Data that defines the capacity configuration. +type InstanceReservationConfig struct { + + // The shape to use when launching instances using compute capacity reservations. The shape determines the number of CPUs, the amount of memory, + // and other resources allocated to the instance. + // You can list all available shapes by calling ListComputeCapacityReservationInstanceShapes. + InstanceShape *string `mandatory:"true" json:"instanceShape"` + + // The total number of instances that can be launched from the capacity configuration. + ReservedCount *int64 `mandatory:"true" json:"reservedCount"` + + // The amount of capacity in use out of the total capacity reserved in this capacity configuration. + UsedCount *int64 `mandatory:"true" json:"usedCount"` + + // The fault domain of this capacity configuration. + // If a value is not supplied, this capacity configuration is applicable to all fault domains in the specified availability domain. + // For more information, see Capacity Reservations (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/reserve-capacity.htm). + FaultDomain *string `mandatory:"false" json:"faultDomain"` + + InstanceShapeConfig *InstanceReservationShapeConfigDetails `mandatory:"false" json:"instanceShapeConfig"` +} + +func (m InstanceReservationConfig) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_reservation_config_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_reservation_config_details.go new file mode 100644 index 000000000..167dc95ce --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_reservation_config_details.go @@ -0,0 +1,47 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceReservationConfigDetails A template that contains the settings to use when defining the instance capacity configuration. +type InstanceReservationConfigDetails struct { + + // The shape requested when launching instances using reserved capacity. + // The shape determines the number of CPUs, amount of memory, + // and other resources allocated to the instance. + // You can list all available shapes by calling ListComputeCapacityReservationInstanceShapes. + InstanceShape *string `mandatory:"true" json:"instanceShape"` + + // The total number of instances that can be launched from the capacity configuration. + ReservedCount *int64 `mandatory:"true" json:"reservedCount"` + + InstanceShapeConfig *InstanceReservationShapeConfigDetails `mandatory:"false" json:"instanceShapeConfig"` + + // The fault domain to use for instances created using this capacity configuration. + // For more information, see Fault Domains (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/regions.htm#fault). + // If you do not specify the fault domain, the capacity is available for an instance + // that does not specify a fault domain. To change the fault domain for a reservation, + // delete the reservation and create a new one in the preferred fault domain. + // To retrieve a list of fault domains, use the `ListFaultDomains` operation in + // the Identity and Access Management Service API (https://docs.cloud.oracle.com/iaas/api/#/en/identity/20160918/). + // Example: `FAULT-DOMAIN-1` + FaultDomain *string `mandatory:"false" json:"faultDomain"` +} + +func (m InstanceReservationConfigDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_reservation_shape_config_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_reservation_shape_config_details.go new file mode 100644 index 000000000..535055f3e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_reservation_shape_config_details.go @@ -0,0 +1,39 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceReservationShapeConfigDetails The shape configuration requested when launching instances in a compute capacity reservation. +// If the parameter is provided, the reservation is created with the resources that you specify. If some +// properties are missing or the parameter is not provided, the reservation is created +// with the default configuration values for the `shape` that you specify. +// Each shape only supports certain configurable values. If the values that you provide are not valid for the +// specified `shape`, an error is returned. +// For more information about customizing the resources that are allocated to flexible shapes, +// see Flexible Shapes (https://docs.cloud.oracle.com/iaas/Content/Compute/References/computeshapes.htm#flexible). +type InstanceReservationShapeConfigDetails struct { + + // The total number of OCPUs available to the instance. + Ocpus *float32 `mandatory:"false" json:"ocpus"` + + // The total amount of memory available to the instance, in gigabytes. + MemoryInGBs *float32 `mandatory:"false" json:"memoryInGBs"` +} + +func (m InstanceReservationShapeConfigDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_shape_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_shape_config.go new file mode 100644 index 000000000..b360e729e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_shape_config.go @@ -0,0 +1,93 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceShapeConfig The shape configuration for an instance. The shape configuration determines +// the resources allocated to an instance. +type InstanceShapeConfig struct { + + // The total number of OCPUs available to the instance. + Ocpus *float32 `mandatory:"false" json:"ocpus"` + + // The total amount of memory available to the instance, in gigabytes. + MemoryInGBs *float32 `mandatory:"false" json:"memoryInGBs"` + + // The baseline OCPU utilization for a subcore burstable VM instance. Leave this attribute blank for a + // non-burstable instance, or explicitly specify non-burstable with `BASELINE_1_1`. + // The following values are supported: + // - `BASELINE_1_8` - baseline usage is 1/8 of an OCPU. + // - `BASELINE_1_2` - baseline usage is 1/2 of an OCPU. + // - `BASELINE_1_1` - baseline usage is the entire OCPU. This represents a non-burstable instance. + BaselineOcpuUtilization InstanceShapeConfigBaselineOcpuUtilizationEnum `mandatory:"false" json:"baselineOcpuUtilization,omitempty"` + + // A short description of the instance's processor (CPU). + ProcessorDescription *string `mandatory:"false" json:"processorDescription"` + + // The networking bandwidth available to the instance, in gigabits per second. + NetworkingBandwidthInGbps *float32 `mandatory:"false" json:"networkingBandwidthInGbps"` + + // The maximum number of VNIC attachments for the instance. + MaxVnicAttachments *int `mandatory:"false" json:"maxVnicAttachments"` + + // The number of GPUs available to the instance. + Gpus *int `mandatory:"false" json:"gpus"` + + // A short description of the instance's graphics processing unit (GPU). + // If the instance does not have any GPUs, this field is `null`. + GpuDescription *string `mandatory:"false" json:"gpuDescription"` + + // The number of local disks available to the instance. + LocalDisks *int `mandatory:"false" json:"localDisks"` + + // The aggregate size of all local disks, in gigabytes. + // If the instance does not have any local disks, this field is `null`. + LocalDisksTotalSizeInGBs *float32 `mandatory:"false" json:"localDisksTotalSizeInGBs"` + + // A short description of the local disks available to this instance. + // If the instance does not have any local disks, this field is `null`. + LocalDiskDescription *string `mandatory:"false" json:"localDiskDescription"` +} + +func (m InstanceShapeConfig) String() string { + return common.PointerString(m) +} + +// InstanceShapeConfigBaselineOcpuUtilizationEnum Enum with underlying type: string +type InstanceShapeConfigBaselineOcpuUtilizationEnum string + +// Set of constants representing the allowable values for InstanceShapeConfigBaselineOcpuUtilizationEnum +const ( + InstanceShapeConfigBaselineOcpuUtilization8 InstanceShapeConfigBaselineOcpuUtilizationEnum = "BASELINE_1_8" + InstanceShapeConfigBaselineOcpuUtilization2 InstanceShapeConfigBaselineOcpuUtilizationEnum = "BASELINE_1_2" + InstanceShapeConfigBaselineOcpuUtilization1 InstanceShapeConfigBaselineOcpuUtilizationEnum = "BASELINE_1_1" +) + +var mappingInstanceShapeConfigBaselineOcpuUtilization = map[string]InstanceShapeConfigBaselineOcpuUtilizationEnum{ + "BASELINE_1_8": InstanceShapeConfigBaselineOcpuUtilization8, + "BASELINE_1_2": InstanceShapeConfigBaselineOcpuUtilization2, + "BASELINE_1_1": InstanceShapeConfigBaselineOcpuUtilization1, +} + +// GetInstanceShapeConfigBaselineOcpuUtilizationEnumValues Enumerates the set of values for InstanceShapeConfigBaselineOcpuUtilizationEnum +func GetInstanceShapeConfigBaselineOcpuUtilizationEnumValues() []InstanceShapeConfigBaselineOcpuUtilizationEnum { + values := make([]InstanceShapeConfigBaselineOcpuUtilizationEnum, 0) + for _, v := range mappingInstanceShapeConfigBaselineOcpuUtilization { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_source_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_source_details.go new file mode 100644 index 000000000..1347eb737 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_source_details.go @@ -0,0 +1,70 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceSourceDetails The representation of InstanceSourceDetails +type InstanceSourceDetails interface { +} + +type instancesourcedetails struct { + JsonData []byte + SourceType string `json:"sourceType"` +} + +// UnmarshalJSON unmarshals json +func (m *instancesourcedetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerinstancesourcedetails instancesourcedetails + s := struct { + Model Unmarshalerinstancesourcedetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.SourceType = s.Model.SourceType + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *instancesourcedetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.SourceType { + case "image": + mm := InstanceSourceViaImageDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "bootVolume": + mm := InstanceSourceViaBootVolumeDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +func (m instancesourcedetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_source_via_boot_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_source_via_boot_volume_details.go new file mode 100644 index 000000000..d3172ca97 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_source_via_boot_volume_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceSourceViaBootVolumeDetails The representation of InstanceSourceViaBootVolumeDetails +type InstanceSourceViaBootVolumeDetails struct { + + // The OCID of the boot volume used to boot the instance. + BootVolumeId *string `mandatory:"true" json:"bootVolumeId"` +} + +func (m InstanceSourceViaBootVolumeDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m InstanceSourceViaBootVolumeDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeInstanceSourceViaBootVolumeDetails InstanceSourceViaBootVolumeDetails + s := struct { + DiscriminatorParam string `json:"sourceType"` + MarshalTypeInstanceSourceViaBootVolumeDetails + }{ + "bootVolume", + (MarshalTypeInstanceSourceViaBootVolumeDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_source_via_image_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_source_via_image_details.go new file mode 100644 index 000000000..bb681bd3b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_source_via_image_details.go @@ -0,0 +1,50 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceSourceViaImageDetails The representation of InstanceSourceViaImageDetails +type InstanceSourceViaImageDetails struct { + + // The OCID of the image used to boot the instance. + ImageId *string `mandatory:"true" json:"imageId"` + + // The size of the boot volume in GBs. Minimum value is 50 GB and maximum value is 32,768 GB (32 TB). + BootVolumeSizeInGBs *int64 `mandatory:"false" json:"bootVolumeSizeInGBs"` + + // The OCID of the Key Management key to assign as the master encryption key for the boot volume. + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` +} + +func (m InstanceSourceViaImageDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m InstanceSourceViaImageDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeInstanceSourceViaImageDetails InstanceSourceViaImageDetails + s := struct { + DiscriminatorParam string `json:"sourceType"` + MarshalTypeInstanceSourceViaImageDetails + }{ + "image", + (MarshalTypeInstanceSourceViaImageDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_summary.go new file mode 100644 index 000000000..39f9b4b46 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/instance_summary.go @@ -0,0 +1,63 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InstanceSummary Condensed instance data when listing instances in an instance pool. +type InstanceSummary struct { + + // The OCID of the instance. + Id *string `mandatory:"true" json:"id"` + + // The availability domain the instance is running in. + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment that contains the instance. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the instance confgiuration used to create the instance. + InstanceConfigurationId *string `mandatory:"true" json:"instanceConfigurationId"` + + // The region that contains the availability domain the instance is running in. + Region *string `mandatory:"true" json:"region"` + + // The current state of the instance pool instance. + State *string `mandatory:"true" json:"state"` + + // The date and time the instance pool instance was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The fault domain the instance is running in. + FaultDomain *string `mandatory:"false" json:"faultDomain"` + + // The shape of an instance. The shape determines the number of CPUs, amount of memory, + // and other resources allocated to the instance. + // You can enumerate all available shapes by calling ListShapes. + Shape *string `mandatory:"false" json:"shape"` + + // The load balancer backends that are configured for the instance pool instance. + LoadBalancerBackends []InstancePoolInstanceLoadBalancerBackend `mandatory:"false" json:"loadBalancerBackends"` +} + +func (m InstanceSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/intel_skylake_bm_launch_instance_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/intel_skylake_bm_launch_instance_platform_config.go new file mode 100644 index 000000000..cd16cf4ed --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/intel_skylake_bm_launch_instance_platform_config.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IntelSkylakeBmLaunchInstancePlatformConfig The platform configuration used when launching a bare metal instance with the Intel Skylake platform. +type IntelSkylakeBmLaunchInstancePlatformConfig struct { + + // Whether Secure Boot is enabled on the instance. + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + + // Whether the Measured Boot feature is enabled on the instance. + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m IntelSkylakeBmLaunchInstancePlatformConfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m IntelSkylakeBmLaunchInstancePlatformConfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m IntelSkylakeBmLaunchInstancePlatformConfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m IntelSkylakeBmLaunchInstancePlatformConfig) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m IntelSkylakeBmLaunchInstancePlatformConfig) MarshalJSON() (buff []byte, e error) { + type MarshalTypeIntelSkylakeBmLaunchInstancePlatformConfig IntelSkylakeBmLaunchInstancePlatformConfig + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeIntelSkylakeBmLaunchInstancePlatformConfig + }{ + "INTEL_SKYLAKE_BM", + (MarshalTypeIntelSkylakeBmLaunchInstancePlatformConfig)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/intel_skylake_bm_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/intel_skylake_bm_platform_config.go new file mode 100644 index 000000000..51842e806 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/intel_skylake_bm_platform_config.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IntelSkylakeBmPlatformConfig The platform configuration of a bare metal instance that uses the Intel Skylake platform. +type IntelSkylakeBmPlatformConfig struct { + + // Whether Secure Boot is enabled on the instance. + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + + // Whether the Measured Boot feature is enabled on the instance. + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m IntelSkylakeBmPlatformConfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m IntelSkylakeBmPlatformConfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m IntelSkylakeBmPlatformConfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m IntelSkylakeBmPlatformConfig) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m IntelSkylakeBmPlatformConfig) MarshalJSON() (buff []byte, e error) { + type MarshalTypeIntelSkylakeBmPlatformConfig IntelSkylakeBmPlatformConfig + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeIntelSkylakeBmPlatformConfig + }{ + "INTEL_SKYLAKE_BM", + (MarshalTypeIntelSkylakeBmPlatformConfig)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/intel_vm_launch_instance_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/intel_vm_launch_instance_platform_config.go new file mode 100644 index 000000000..5481b788e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/intel_vm_launch_instance_platform_config.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IntelVmLaunchInstancePlatformConfig The platform configuration used when launching a virtual machine instance with the Intel platform. +type IntelVmLaunchInstancePlatformConfig struct { + + // Whether Secure Boot is enabled on the instance. + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + + // Whether the Measured Boot feature is enabled on the instance. + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m IntelVmLaunchInstancePlatformConfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m IntelVmLaunchInstancePlatformConfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m IntelVmLaunchInstancePlatformConfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m IntelVmLaunchInstancePlatformConfig) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m IntelVmLaunchInstancePlatformConfig) MarshalJSON() (buff []byte, e error) { + type MarshalTypeIntelVmLaunchInstancePlatformConfig IntelVmLaunchInstancePlatformConfig + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeIntelVmLaunchInstancePlatformConfig + }{ + "INTEL_VM", + (MarshalTypeIntelVmLaunchInstancePlatformConfig)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/intel_vm_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/intel_vm_platform_config.go new file mode 100644 index 000000000..6f7b95382 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/intel_vm_platform_config.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IntelVmPlatformConfig The platform configuration of a virtual machine instance that uses the Intel platform. +type IntelVmPlatformConfig struct { + + // Whether Secure Boot is enabled on the instance. + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + + // Whether the Measured Boot feature is enabled on the instance. + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m IntelVmPlatformConfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m IntelVmPlatformConfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m IntelVmPlatformConfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m IntelVmPlatformConfig) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m IntelVmPlatformConfig) MarshalJSON() (buff []byte, e error) { + type MarshalTypeIntelVmPlatformConfig IntelVmPlatformConfig + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeIntelVmPlatformConfig + }{ + "INTEL_VM", + (MarshalTypeIntelVmPlatformConfig)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/internet_gateway.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/internet_gateway.go new file mode 100644 index 000000000..4b79cd034 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/internet_gateway.go @@ -0,0 +1,92 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// InternetGateway Represents a router that connects the edge of a VCN with the Internet. For an example scenario +// that uses an internet gateway, see +// Typical Networking Service Scenarios (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm#scenarios). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type InternetGateway struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the internet gateway. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The internet gateway's Oracle ID (OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"true" json:"id"` + + // The internet gateway's current state. + LifecycleState InternetGatewayLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN the internet gateway belongs to. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Whether the gateway is enabled. When the gateway is disabled, traffic is not + // routed to/from the Internet, regardless of route rules. + IsEnabled *bool `mandatory:"false" json:"isEnabled"` + + // The date and time the internet gateway was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` +} + +func (m InternetGateway) String() string { + return common.PointerString(m) +} + +// InternetGatewayLifecycleStateEnum Enum with underlying type: string +type InternetGatewayLifecycleStateEnum string + +// Set of constants representing the allowable values for InternetGatewayLifecycleStateEnum +const ( + InternetGatewayLifecycleStateProvisioning InternetGatewayLifecycleStateEnum = "PROVISIONING" + InternetGatewayLifecycleStateAvailable InternetGatewayLifecycleStateEnum = "AVAILABLE" + InternetGatewayLifecycleStateTerminating InternetGatewayLifecycleStateEnum = "TERMINATING" + InternetGatewayLifecycleStateTerminated InternetGatewayLifecycleStateEnum = "TERMINATED" +) + +var mappingInternetGatewayLifecycleState = map[string]InternetGatewayLifecycleStateEnum{ + "PROVISIONING": InternetGatewayLifecycleStateProvisioning, + "AVAILABLE": InternetGatewayLifecycleStateAvailable, + "TERMINATING": InternetGatewayLifecycleStateTerminating, + "TERMINATED": InternetGatewayLifecycleStateTerminated, +} + +// GetInternetGatewayLifecycleStateEnumValues Enumerates the set of values for InternetGatewayLifecycleStateEnum +func GetInternetGatewayLifecycleStateEnumValues() []InternetGatewayLifecycleStateEnum { + values := make([]InternetGatewayLifecycleStateEnum, 0) + for _, v := range mappingInternetGatewayLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection.go new file mode 100644 index 000000000..532b61657 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection.go @@ -0,0 +1,153 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IpSecConnection A connection between a DRG and CPE. This connection consists of multiple IPSec +// tunnels. Creating this connection is one of the steps required when setting up +// a Site-to-Site VPN. +// **Important:** Each tunnel in an IPSec connection can use either static routing or BGP dynamic +// routing (see the IPSecConnectionTunnel object's +// `routing` attribute). Originally only static routing was supported and +// every IPSec connection was required to have at least one static route configured. +// To maintain backward compatibility in the API when support for BPG dynamic routing was introduced, +// the API accepts an empty list of static routes if you configure both of the IPSec tunnels to use +// BGP dynamic routing. If you switch a tunnel's routing from `BGP` to `STATIC`, you must first +// ensure that the IPSec connection is configured with at least one valid CIDR block static route. +// Oracle uses the IPSec connection's static routes when routing a tunnel's traffic *only* +// if that tunnel's `routing` attribute = `STATIC`. Otherwise the static routes are ignored. +// For more information about the workflow for setting up an IPSec connection, see +// Site-to-Site VPN Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/overviewIPsec.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type IpSecConnection struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the IPSec connection. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the Cpe object. + CpeId *string `mandatory:"true" json:"cpeId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"true" json:"drgId"` + + // The IPSec connection's Oracle ID (OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"true" json:"id"` + + // The IPSec connection's current state. + LifecycleState IpSecConnectionLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // Static routes to the CPE. The CIDR must not be a + // multicast address or class E address. + // Used for routing a given IPSec tunnel's traffic only if the tunnel + // is using static routing. If you configure at least one tunnel to use static routing, then + // you must provide at least one valid static route. If you configure both + // tunnels to use BGP dynamic routing, you can provide an empty list for the static routes. + // The CIDR can be either IPv4 or IPv6. IPv6 addressing is supported for all commercial and government regions. + // See IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // Example: `10.0.1.0/24` + // Example: `2001:db8::/32` + StaticRoutes []string `mandatory:"true" json:"staticRoutes"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Your identifier for your CPE device. Can be either an IP address or a hostname (specifically, + // the fully qualified domain name (FQDN)). The type of identifier here must correspond + // to the value for `cpeLocalIdentifierType`. + // If you don't provide a value when creating the IPSec connection, the `ipAddress` attribute + // for the Cpe object specified by `cpeId` is used as the `cpeLocalIdentifier`. + // For information about why you'd provide this value, see + // If Your CPE Is Behind a NAT Device (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/overviewIPsec.htm#nat). + // Example IP address: `10.0.3.3` + // Example hostname: `cpe.example.com` + CpeLocalIdentifier *string `mandatory:"false" json:"cpeLocalIdentifier"` + + // The type of identifier for your CPE device. The value here must correspond to the value + // for `cpeLocalIdentifier`. + CpeLocalIdentifierType IpSecConnectionCpeLocalIdentifierTypeEnum `mandatory:"false" json:"cpeLocalIdentifierType,omitempty"` + + // The date and time the IPSec connection was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` +} + +func (m IpSecConnection) String() string { + return common.PointerString(m) +} + +// IpSecConnectionLifecycleStateEnum Enum with underlying type: string +type IpSecConnectionLifecycleStateEnum string + +// Set of constants representing the allowable values for IpSecConnectionLifecycleStateEnum +const ( + IpSecConnectionLifecycleStateProvisioning IpSecConnectionLifecycleStateEnum = "PROVISIONING" + IpSecConnectionLifecycleStateAvailable IpSecConnectionLifecycleStateEnum = "AVAILABLE" + IpSecConnectionLifecycleStateTerminating IpSecConnectionLifecycleStateEnum = "TERMINATING" + IpSecConnectionLifecycleStateTerminated IpSecConnectionLifecycleStateEnum = "TERMINATED" +) + +var mappingIpSecConnectionLifecycleState = map[string]IpSecConnectionLifecycleStateEnum{ + "PROVISIONING": IpSecConnectionLifecycleStateProvisioning, + "AVAILABLE": IpSecConnectionLifecycleStateAvailable, + "TERMINATING": IpSecConnectionLifecycleStateTerminating, + "TERMINATED": IpSecConnectionLifecycleStateTerminated, +} + +// GetIpSecConnectionLifecycleStateEnumValues Enumerates the set of values for IpSecConnectionLifecycleStateEnum +func GetIpSecConnectionLifecycleStateEnumValues() []IpSecConnectionLifecycleStateEnum { + values := make([]IpSecConnectionLifecycleStateEnum, 0) + for _, v := range mappingIpSecConnectionLifecycleState { + values = append(values, v) + } + return values +} + +// IpSecConnectionCpeLocalIdentifierTypeEnum Enum with underlying type: string +type IpSecConnectionCpeLocalIdentifierTypeEnum string + +// Set of constants representing the allowable values for IpSecConnectionCpeLocalIdentifierTypeEnum +const ( + IpSecConnectionCpeLocalIdentifierTypeIpAddress IpSecConnectionCpeLocalIdentifierTypeEnum = "IP_ADDRESS" + IpSecConnectionCpeLocalIdentifierTypeHostname IpSecConnectionCpeLocalIdentifierTypeEnum = "HOSTNAME" +) + +var mappingIpSecConnectionCpeLocalIdentifierType = map[string]IpSecConnectionCpeLocalIdentifierTypeEnum{ + "IP_ADDRESS": IpSecConnectionCpeLocalIdentifierTypeIpAddress, + "HOSTNAME": IpSecConnectionCpeLocalIdentifierTypeHostname, +} + +// GetIpSecConnectionCpeLocalIdentifierTypeEnumValues Enumerates the set of values for IpSecConnectionCpeLocalIdentifierTypeEnum +func GetIpSecConnectionCpeLocalIdentifierTypeEnumValues() []IpSecConnectionCpeLocalIdentifierTypeEnum { + values := make([]IpSecConnectionCpeLocalIdentifierTypeEnum, 0) + for _, v := range mappingIpSecConnectionCpeLocalIdentifierType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_device_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_device_config.go new file mode 100644 index 000000000..27e930289 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_device_config.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IpSecConnectionDeviceConfig Deprecated. For tunnel information, instead see: +// * IPSecConnectionTunnel +// * IPSecConnectionTunnelSharedSecret +type IpSecConnectionDeviceConfig struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the IPSec connection. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The IPSec connection's Oracle ID (OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"true" json:"id"` + + // The date and time the IPSec connection was created. + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // Two TunnelConfig objects. + Tunnels []TunnelConfig `mandatory:"false" json:"tunnels"` +} + +func (m IpSecConnectionDeviceConfig) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_device_status.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_device_status.go new file mode 100644 index 000000000..003ec07b8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_device_status.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IpSecConnectionDeviceStatus Deprecated. For tunnel information, instead see +// IPSecConnectionTunnel. +type IpSecConnectionDeviceStatus struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the IPSec connection. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The IPSec connection's Oracle ID (OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"true" json:"id"` + + // The date and time the IPSec connection was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // Two TunnelStatus objects. + Tunnels []TunnelStatus `mandatory:"false" json:"tunnels"` +} + +func (m IpSecConnectionDeviceStatus) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_tunnel.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_tunnel.go new file mode 100644 index 000000000..6177bbe36 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_tunnel.go @@ -0,0 +1,259 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IpSecConnectionTunnel Information about a single tunnel in an IPSec connection. This object does not include the tunnel's +// shared secret (pre-shared key). That is in the +// IPSecConnectionTunnelSharedSecret object. +type IpSecConnectionTunnel struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the tunnel. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the tunnel. + Id *string `mandatory:"true" json:"id"` + + // The tunnel's lifecycle state. + LifecycleState IpSecConnectionTunnelLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The IP address of Oracle's VPN headend. + // Example: `203.0.113.21` + VpnIp *string `mandatory:"false" json:"vpnIp"` + + // The IP address of the CPE's VPN headend. + // Example: `203.0.113.22` + CpeIp *string `mandatory:"false" json:"cpeIp"` + + // The status of the tunnel based on IPSec protocol characteristics. + Status IpSecConnectionTunnelStatusEnum `mandatory:"false" json:"status,omitempty"` + + // Internet Key Exchange protocol version. + IkeVersion IpSecConnectionTunnelIkeVersionEnum `mandatory:"false" json:"ikeVersion,omitempty"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + BgpSessionInfo *BgpSessionInfo `mandatory:"false" json:"bgpSessionInfo"` + + EncryptionDomainConfig *EncryptionDomainConfig `mandatory:"false" json:"encryptionDomainConfig"` + + // The type of routing used for this tunnel (either BGP dynamic routing or static routing). + Routing IpSecConnectionTunnelRoutingEnum `mandatory:"false" json:"routing,omitempty"` + + // The date and time the IPSec connection tunnel was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // When the status of the tunnel last changed, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeStatusUpdated *common.SDKTime `mandatory:"false" json:"timeStatusUpdated"` + + // Indicates whether Oracle can either initiate the tunnel or respond, or respond only. + OracleCanInitiate IpSecConnectionTunnelOracleCanInitiateEnum `mandatory:"false" json:"oracleCanInitiate,omitempty"` + + // Whether NAT-T Enabled on the tunnel + NatTranslationEnabled IpSecConnectionTunnelNatTranslationEnabledEnum `mandatory:"false" json:"natTranslationEnabled,omitempty"` + + // dpd mode + DpdMode IpSecConnectionTunnelDpdModeEnum `mandatory:"false" json:"dpdMode,omitempty"` + + // Dead peer detection (DPD) timeout in seconds. + DpdTimeoutInSec *int `mandatory:"false" json:"dpdTimeoutInSec"` + + PhaseOneDetails *TunnelPhaseOneDetails `mandatory:"false" json:"phaseOneDetails"` + + PhaseTwoDetails *TunnelPhaseTwoDetails `mandatory:"false" json:"phaseTwoDetails"` +} + +func (m IpSecConnectionTunnel) String() string { + return common.PointerString(m) +} + +// IpSecConnectionTunnelStatusEnum Enum with underlying type: string +type IpSecConnectionTunnelStatusEnum string + +// Set of constants representing the allowable values for IpSecConnectionTunnelStatusEnum +const ( + IpSecConnectionTunnelStatusUp IpSecConnectionTunnelStatusEnum = "UP" + IpSecConnectionTunnelStatusDown IpSecConnectionTunnelStatusEnum = "DOWN" + IpSecConnectionTunnelStatusDownForMaintenance IpSecConnectionTunnelStatusEnum = "DOWN_FOR_MAINTENANCE" + IpSecConnectionTunnelStatusPartialUp IpSecConnectionTunnelStatusEnum = "PARTIAL_UP" +) + +var mappingIpSecConnectionTunnelStatus = map[string]IpSecConnectionTunnelStatusEnum{ + "UP": IpSecConnectionTunnelStatusUp, + "DOWN": IpSecConnectionTunnelStatusDown, + "DOWN_FOR_MAINTENANCE": IpSecConnectionTunnelStatusDownForMaintenance, + "PARTIAL_UP": IpSecConnectionTunnelStatusPartialUp, +} + +// GetIpSecConnectionTunnelStatusEnumValues Enumerates the set of values for IpSecConnectionTunnelStatusEnum +func GetIpSecConnectionTunnelStatusEnumValues() []IpSecConnectionTunnelStatusEnum { + values := make([]IpSecConnectionTunnelStatusEnum, 0) + for _, v := range mappingIpSecConnectionTunnelStatus { + values = append(values, v) + } + return values +} + +// IpSecConnectionTunnelIkeVersionEnum Enum with underlying type: string +type IpSecConnectionTunnelIkeVersionEnum string + +// Set of constants representing the allowable values for IpSecConnectionTunnelIkeVersionEnum +const ( + IpSecConnectionTunnelIkeVersionV1 IpSecConnectionTunnelIkeVersionEnum = "V1" + IpSecConnectionTunnelIkeVersionV2 IpSecConnectionTunnelIkeVersionEnum = "V2" +) + +var mappingIpSecConnectionTunnelIkeVersion = map[string]IpSecConnectionTunnelIkeVersionEnum{ + "V1": IpSecConnectionTunnelIkeVersionV1, + "V2": IpSecConnectionTunnelIkeVersionV2, +} + +// GetIpSecConnectionTunnelIkeVersionEnumValues Enumerates the set of values for IpSecConnectionTunnelIkeVersionEnum +func GetIpSecConnectionTunnelIkeVersionEnumValues() []IpSecConnectionTunnelIkeVersionEnum { + values := make([]IpSecConnectionTunnelIkeVersionEnum, 0) + for _, v := range mappingIpSecConnectionTunnelIkeVersion { + values = append(values, v) + } + return values +} + +// IpSecConnectionTunnelLifecycleStateEnum Enum with underlying type: string +type IpSecConnectionTunnelLifecycleStateEnum string + +// Set of constants representing the allowable values for IpSecConnectionTunnelLifecycleStateEnum +const ( + IpSecConnectionTunnelLifecycleStateProvisioning IpSecConnectionTunnelLifecycleStateEnum = "PROVISIONING" + IpSecConnectionTunnelLifecycleStateAvailable IpSecConnectionTunnelLifecycleStateEnum = "AVAILABLE" + IpSecConnectionTunnelLifecycleStateTerminating IpSecConnectionTunnelLifecycleStateEnum = "TERMINATING" + IpSecConnectionTunnelLifecycleStateTerminated IpSecConnectionTunnelLifecycleStateEnum = "TERMINATED" +) + +var mappingIpSecConnectionTunnelLifecycleState = map[string]IpSecConnectionTunnelLifecycleStateEnum{ + "PROVISIONING": IpSecConnectionTunnelLifecycleStateProvisioning, + "AVAILABLE": IpSecConnectionTunnelLifecycleStateAvailable, + "TERMINATING": IpSecConnectionTunnelLifecycleStateTerminating, + "TERMINATED": IpSecConnectionTunnelLifecycleStateTerminated, +} + +// GetIpSecConnectionTunnelLifecycleStateEnumValues Enumerates the set of values for IpSecConnectionTunnelLifecycleStateEnum +func GetIpSecConnectionTunnelLifecycleStateEnumValues() []IpSecConnectionTunnelLifecycleStateEnum { + values := make([]IpSecConnectionTunnelLifecycleStateEnum, 0) + for _, v := range mappingIpSecConnectionTunnelLifecycleState { + values = append(values, v) + } + return values +} + +// IpSecConnectionTunnelRoutingEnum Enum with underlying type: string +type IpSecConnectionTunnelRoutingEnum string + +// Set of constants representing the allowable values for IpSecConnectionTunnelRoutingEnum +const ( + IpSecConnectionTunnelRoutingBgp IpSecConnectionTunnelRoutingEnum = "BGP" + IpSecConnectionTunnelRoutingStatic IpSecConnectionTunnelRoutingEnum = "STATIC" + IpSecConnectionTunnelRoutingPolicy IpSecConnectionTunnelRoutingEnum = "POLICY" +) + +var mappingIpSecConnectionTunnelRouting = map[string]IpSecConnectionTunnelRoutingEnum{ + "BGP": IpSecConnectionTunnelRoutingBgp, + "STATIC": IpSecConnectionTunnelRoutingStatic, + "POLICY": IpSecConnectionTunnelRoutingPolicy, +} + +// GetIpSecConnectionTunnelRoutingEnumValues Enumerates the set of values for IpSecConnectionTunnelRoutingEnum +func GetIpSecConnectionTunnelRoutingEnumValues() []IpSecConnectionTunnelRoutingEnum { + values := make([]IpSecConnectionTunnelRoutingEnum, 0) + for _, v := range mappingIpSecConnectionTunnelRouting { + values = append(values, v) + } + return values +} + +// IpSecConnectionTunnelOracleCanInitiateEnum Enum with underlying type: string +type IpSecConnectionTunnelOracleCanInitiateEnum string + +// Set of constants representing the allowable values for IpSecConnectionTunnelOracleCanInitiateEnum +const ( + IpSecConnectionTunnelOracleCanInitiateInitiatorOrResponder IpSecConnectionTunnelOracleCanInitiateEnum = "INITIATOR_OR_RESPONDER" + IpSecConnectionTunnelOracleCanInitiateResponderOnly IpSecConnectionTunnelOracleCanInitiateEnum = "RESPONDER_ONLY" +) + +var mappingIpSecConnectionTunnelOracleCanInitiate = map[string]IpSecConnectionTunnelOracleCanInitiateEnum{ + "INITIATOR_OR_RESPONDER": IpSecConnectionTunnelOracleCanInitiateInitiatorOrResponder, + "RESPONDER_ONLY": IpSecConnectionTunnelOracleCanInitiateResponderOnly, +} + +// GetIpSecConnectionTunnelOracleCanInitiateEnumValues Enumerates the set of values for IpSecConnectionTunnelOracleCanInitiateEnum +func GetIpSecConnectionTunnelOracleCanInitiateEnumValues() []IpSecConnectionTunnelOracleCanInitiateEnum { + values := make([]IpSecConnectionTunnelOracleCanInitiateEnum, 0) + for _, v := range mappingIpSecConnectionTunnelOracleCanInitiate { + values = append(values, v) + } + return values +} + +// IpSecConnectionTunnelNatTranslationEnabledEnum Enum with underlying type: string +type IpSecConnectionTunnelNatTranslationEnabledEnum string + +// Set of constants representing the allowable values for IpSecConnectionTunnelNatTranslationEnabledEnum +const ( + IpSecConnectionTunnelNatTranslationEnabledEnabled IpSecConnectionTunnelNatTranslationEnabledEnum = "ENABLED" + IpSecConnectionTunnelNatTranslationEnabledDisabled IpSecConnectionTunnelNatTranslationEnabledEnum = "DISABLED" + IpSecConnectionTunnelNatTranslationEnabledAuto IpSecConnectionTunnelNatTranslationEnabledEnum = "AUTO" +) + +var mappingIpSecConnectionTunnelNatTranslationEnabled = map[string]IpSecConnectionTunnelNatTranslationEnabledEnum{ + "ENABLED": IpSecConnectionTunnelNatTranslationEnabledEnabled, + "DISABLED": IpSecConnectionTunnelNatTranslationEnabledDisabled, + "AUTO": IpSecConnectionTunnelNatTranslationEnabledAuto, +} + +// GetIpSecConnectionTunnelNatTranslationEnabledEnumValues Enumerates the set of values for IpSecConnectionTunnelNatTranslationEnabledEnum +func GetIpSecConnectionTunnelNatTranslationEnabledEnumValues() []IpSecConnectionTunnelNatTranslationEnabledEnum { + values := make([]IpSecConnectionTunnelNatTranslationEnabledEnum, 0) + for _, v := range mappingIpSecConnectionTunnelNatTranslationEnabled { + values = append(values, v) + } + return values +} + +// IpSecConnectionTunnelDpdModeEnum Enum with underlying type: string +type IpSecConnectionTunnelDpdModeEnum string + +// Set of constants representing the allowable values for IpSecConnectionTunnelDpdModeEnum +const ( + IpSecConnectionTunnelDpdModeInitiateAndRespond IpSecConnectionTunnelDpdModeEnum = "INITIATE_AND_RESPOND" + IpSecConnectionTunnelDpdModeRespondOnly IpSecConnectionTunnelDpdModeEnum = "RESPOND_ONLY" +) + +var mappingIpSecConnectionTunnelDpdMode = map[string]IpSecConnectionTunnelDpdModeEnum{ + "INITIATE_AND_RESPOND": IpSecConnectionTunnelDpdModeInitiateAndRespond, + "RESPOND_ONLY": IpSecConnectionTunnelDpdModeRespondOnly, +} + +// GetIpSecConnectionTunnelDpdModeEnumValues Enumerates the set of values for IpSecConnectionTunnelDpdModeEnum +func GetIpSecConnectionTunnelDpdModeEnumValues() []IpSecConnectionTunnelDpdModeEnum { + values := make([]IpSecConnectionTunnelDpdModeEnum, 0) + for _, v := range mappingIpSecConnectionTunnelDpdMode { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_tunnel_error_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_tunnel_error_details.go new file mode 100644 index 000000000..c133aa59f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_tunnel_error_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IpSecConnectionTunnelErrorDetails Ipsec tunnels error details +type IpSecConnectionTunnelErrorDetails struct { + + // unique id generated for each error report + Id *string `mandatory:"true" json:"id"` + + // unique code describes error type + ErrorCode *string `mandatory:"true" json:"errorCode"` + + // detailed description of the error + ErrorDescription *string `mandatory:"true" json:"errorDescription"` + + // how to resolve the error + Solution *string `mandatory:"true" json:"solution"` + + // link to oracle resources + OciResourcesLink *string `mandatory:"true" json:"ociResourcesLink"` + + // timestamp when error occurred. + Timestamp *common.SDKTime `mandatory:"true" json:"timestamp"` +} + +func (m IpSecConnectionTunnelErrorDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_tunnel_shared_secret.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_tunnel_shared_secret.go new file mode 100644 index 000000000..51386021b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/ip_sec_connection_tunnel_shared_secret.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IpSecConnectionTunnelSharedSecret The tunnel's shared secret (pre-shared key). +type IpSecConnectionTunnelSharedSecret struct { + + // The tunnel's shared secret (pre-shared key). + SharedSecret *string `mandatory:"true" json:"sharedSecret"` +} + +func (m IpSecConnectionTunnelSharedSecret) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/ipsec_tunnel_drg_attachment_network_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/ipsec_tunnel_drg_attachment_network_details.go new file mode 100644 index 000000000..4a4e33275 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/ipsec_tunnel_drg_attachment_network_details.go @@ -0,0 +1,52 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IpsecTunnelDrgAttachmentNetworkDetails Specifies the IPSec tunnel attached to the DRG. +type IpsecTunnelDrgAttachmentNetworkDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network attached to the DRG. + Id *string `mandatory:"true" json:"id"` + + // The IPSec connection that contains the attached IPSec tunnel. + IpsecConnectionId *string `mandatory:"false" json:"ipsecConnectionId"` +} + +//GetId returns Id +func (m IpsecTunnelDrgAttachmentNetworkDetails) GetId() *string { + return m.Id +} + +func (m IpsecTunnelDrgAttachmentNetworkDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m IpsecTunnelDrgAttachmentNetworkDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeIpsecTunnelDrgAttachmentNetworkDetails IpsecTunnelDrgAttachmentNetworkDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeIpsecTunnelDrgAttachmentNetworkDetails + }{ + "IPSEC_TUNNEL", + (MarshalTypeIpsecTunnelDrgAttachmentNetworkDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/ipv6.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/ipv6.go new file mode 100644 index 000000000..89c80a2b3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/ipv6.go @@ -0,0 +1,98 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Ipv6 An *IPv6* is a conceptual term that refers to an IPv6 address and related properties. +// The `IPv6` object is the API representation of an IPv6. +// You can create and assign an IPv6 to any VNIC that is in an IPv6-enabled subnet in an +// IPv6-enabled VCN. +// **Note:** IPv6 addressing is supported for all commercial and government regions. For important +// details about IPv6 addressing in a VCN, see IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). +type Ipv6 struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the IPv6. + // This is the same as the VNIC's compartment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the IPv6. + Id *string `mandatory:"true" json:"id"` + + // The IPv6 address of the `IPv6` object. The address is within the IPv6 CIDR block of the VNIC's subnet + // (see the `ipv6CidrBlock` attribute for the Subnet object. + // Example: `2001:0db8:0123:1111:abcd:ef01:2345:6789` + IpAddress *string `mandatory:"true" json:"ipAddress"` + + // The IPv6's current state. + LifecycleState Ipv6LifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the subnet the VNIC is in. + SubnetId *string `mandatory:"true" json:"subnetId"` + + // The date and time the IPv6 was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VNIC the IPv6 is assigned to. + // The VNIC and IPv6 must be in the same subnet. + VnicId *string `mandatory:"true" json:"vnicId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m Ipv6) String() string { + return common.PointerString(m) +} + +// Ipv6LifecycleStateEnum Enum with underlying type: string +type Ipv6LifecycleStateEnum string + +// Set of constants representing the allowable values for Ipv6LifecycleStateEnum +const ( + Ipv6LifecycleStateProvisioning Ipv6LifecycleStateEnum = "PROVISIONING" + Ipv6LifecycleStateAvailable Ipv6LifecycleStateEnum = "AVAILABLE" + Ipv6LifecycleStateTerminating Ipv6LifecycleStateEnum = "TERMINATING" + Ipv6LifecycleStateTerminated Ipv6LifecycleStateEnum = "TERMINATED" +) + +var mappingIpv6LifecycleState = map[string]Ipv6LifecycleStateEnum{ + "PROVISIONING": Ipv6LifecycleStateProvisioning, + "AVAILABLE": Ipv6LifecycleStateAvailable, + "TERMINATING": Ipv6LifecycleStateTerminating, + "TERMINATED": Ipv6LifecycleStateTerminated, +} + +// GetIpv6LifecycleStateEnumValues Enumerates the set of values for Ipv6LifecycleStateEnum +func GetIpv6LifecycleStateEnumValues() []Ipv6LifecycleStateEnum { + values := make([]Ipv6LifecycleStateEnum, 0) + for _, v := range mappingIpv6LifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_agent_config_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_agent_config_details.go new file mode 100644 index 000000000..7e82dda2e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_agent_config_details.go @@ -0,0 +1,63 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// LaunchInstanceAgentConfigDetails Configuration options for the Oracle Cloud Agent software running on the instance. +type LaunchInstanceAgentConfigDetails struct { + + // Whether Oracle Cloud Agent can gather performance metrics and monitor the instance using the + // monitoring plugins. Default value is false (monitoring plugins are enabled). + // These are the monitoring plugins: Compute Instance Monitoring + // and Custom Logs Monitoring. + // The monitoring plugins are controlled by this parameter and by the per-plugin + // configuration in the `pluginsConfig` object. + // - If `isMonitoringDisabled` is true, all of the monitoring plugins are disabled, regardless of + // the per-plugin configuration. + // - If `isMonitoringDisabled` is false, all of the monitoring plugins are enabled. You + // can optionally disable individual monitoring plugins by providing a value in the `pluginsConfig` + // object. + IsMonitoringDisabled *bool `mandatory:"false" json:"isMonitoringDisabled"` + + // Whether Oracle Cloud Agent can run all the available management plugins. + // Default value is false (management plugins are enabled). + // These are the management plugins: OS Management Service Agent and Compute Instance + // Run Command. + // The management plugins are controlled by this parameter and by the per-plugin + // configuration in the `pluginsConfig` object. + // - If `isManagementDisabled` is true, all of the management plugins are disabled, regardless of + // the per-plugin configuration. + // - If `isManagementDisabled` is false, all of the management plugins are enabled. You + // can optionally disable individual management plugins by providing a value in the `pluginsConfig` + // object. + IsManagementDisabled *bool `mandatory:"false" json:"isManagementDisabled"` + + // Whether Oracle Cloud Agent can run all the available plugins. + // This includes the management and monitoring plugins. + // To get a list of available plugins, use the + // ListInstanceagentAvailablePlugins + // operation in the Oracle Cloud Agent API. For more information about the available plugins, see + // Managing Plugins with Oracle Cloud Agent (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/manage-plugins.htm). + AreAllPluginsDisabled *bool `mandatory:"false" json:"areAllPluginsDisabled"` + + // The configuration of plugins associated with this instance. + PluginsConfig []InstanceAgentPluginConfigDetails `mandatory:"false" json:"pluginsConfig"` +} + +func (m LaunchInstanceAgentConfigDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_availability_config_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_availability_config_details.go new file mode 100644 index 000000000..3267efe24 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_availability_config_details.go @@ -0,0 +1,61 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// LaunchInstanceAvailabilityConfigDetails Options for VM migration during infrastructure maintenance events and for defining +// the availability of a VM instance after a maintenance event that impacts the underlying hardware. +type LaunchInstanceAvailabilityConfigDetails struct { + + // Whether to live migrate supported VM instances to a healthy physical VM host without + // disrupting running instances during infrastructure maintenance events. If null, Oracle + // chooses the best option for migrating the VM during infrastructure maintenance events. + IsLiveMigrationPreferred *bool `mandatory:"false" json:"isLiveMigrationPreferred"` + + // The lifecycle state for an instance when it is recovered after infrastructure maintenance. + // * `RESTORE_INSTANCE` - The instance is restored to the lifecycle state it was in before the maintenance event. + // If the instance was running, it is automatically rebooted. This is the default action when a value is not set. + // * `STOP_INSTANCE` - The instance is recovered in the stopped state. + RecoveryAction LaunchInstanceAvailabilityConfigDetailsRecoveryActionEnum `mandatory:"false" json:"recoveryAction,omitempty"` +} + +func (m LaunchInstanceAvailabilityConfigDetails) String() string { + return common.PointerString(m) +} + +// LaunchInstanceAvailabilityConfigDetailsRecoveryActionEnum Enum with underlying type: string +type LaunchInstanceAvailabilityConfigDetailsRecoveryActionEnum string + +// Set of constants representing the allowable values for LaunchInstanceAvailabilityConfigDetailsRecoveryActionEnum +const ( + LaunchInstanceAvailabilityConfigDetailsRecoveryActionRestoreInstance LaunchInstanceAvailabilityConfigDetailsRecoveryActionEnum = "RESTORE_INSTANCE" + LaunchInstanceAvailabilityConfigDetailsRecoveryActionStopInstance LaunchInstanceAvailabilityConfigDetailsRecoveryActionEnum = "STOP_INSTANCE" +) + +var mappingLaunchInstanceAvailabilityConfigDetailsRecoveryAction = map[string]LaunchInstanceAvailabilityConfigDetailsRecoveryActionEnum{ + "RESTORE_INSTANCE": LaunchInstanceAvailabilityConfigDetailsRecoveryActionRestoreInstance, + "STOP_INSTANCE": LaunchInstanceAvailabilityConfigDetailsRecoveryActionStopInstance, +} + +// GetLaunchInstanceAvailabilityConfigDetailsRecoveryActionEnumValues Enumerates the set of values for LaunchInstanceAvailabilityConfigDetailsRecoveryActionEnum +func GetLaunchInstanceAvailabilityConfigDetailsRecoveryActionEnumValues() []LaunchInstanceAvailabilityConfigDetailsRecoveryActionEnum { + values := make([]LaunchInstanceAvailabilityConfigDetailsRecoveryActionEnum, 0) + for _, v := range mappingLaunchInstanceAvailabilityConfigDetailsRecoveryAction { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_configuration_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_configuration_request_response.go new file mode 100644 index 000000000..da9612288 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_configuration_request_response.go @@ -0,0 +1,91 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// LaunchInstanceConfigurationRequest wrapper for the LaunchInstanceConfiguration operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/LaunchInstanceConfiguration.go.html to see an example of how to use LaunchInstanceConfigurationRequest. +type LaunchInstanceConfigurationRequest struct { + + // The OCID of the instance configuration. + InstanceConfigurationId *string `mandatory:"true" contributesTo:"path" name:"instanceConfigurationId"` + + // Instance configuration Instance Details + InstanceConfiguration InstanceConfigurationInstanceDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request LaunchInstanceConfigurationRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request LaunchInstanceConfigurationRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request LaunchInstanceConfigurationRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request LaunchInstanceConfigurationRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// LaunchInstanceConfigurationResponse wrapper for the LaunchInstanceConfiguration operation +type LaunchInstanceConfigurationResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Instance instance + Instance `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response LaunchInstanceConfigurationResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response LaunchInstanceConfigurationResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_details.go new file mode 100644 index 000000000..642e1f026 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_details.go @@ -0,0 +1,285 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// LaunchInstanceDetails Instance launch details. +// Use the `sourceDetails` parameter to specify whether a boot volume or an image should be used to launch a new instance. +type LaunchInstanceDetails struct { + + // The availability domain of the instance. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The shape of an instance. The shape determines the number of CPUs, amount of memory, + // and other resources allocated to the instance. + // You can enumerate all available shapes by calling ListShapes. + Shape *string `mandatory:"true" json:"shape"` + + // The OCID of the compute capacity reservation this instance is launched under. + // You can opt out of all default reservations by specifying an empty string as input for this field. + // For more information, see Capacity Reservations (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/reserve-capacity.htm#default). + CapacityReservationId *string `mandatory:"false" json:"capacityReservationId"` + + CreateVnicDetails *CreateVnicDetails `mandatory:"false" json:"createVnicDetails"` + + // The OCID of the dedicated VM host. + DedicatedVmHostId *string `mandatory:"false" json:"dedicatedVmHostId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Additional metadata key/value pairs that you provide. They serve the same purpose and + // functionality as fields in the `metadata` object. + // They are distinguished from `metadata` fields in that these can be nested JSON objects + // (whereas `metadata` fields are string/string maps only). + // The combined size of the `metadata` and `extendedMetadata` objects can be a maximum of + // 32,000 bytes. + ExtendedMetadata map[string]interface{} `mandatory:"false" json:"extendedMetadata"` + + // A fault domain is a grouping of hardware and infrastructure within an availability domain. + // Each availability domain contains three fault domains. Fault domains let you distribute your + // instances so that they are not on the same physical hardware within a single availability domain. + // A hardware failure or Compute hardware maintenance that affects one fault domain does not affect + // instances in other fault domains. + // If you do not specify the fault domain, the system selects one for you. + // + // To get a list of fault domains, use the + // ListFaultDomains operation in the + // Identity and Access Management Service API. + // Example: `FAULT-DOMAIN-1` + FaultDomain *string `mandatory:"false" json:"faultDomain"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Deprecated. Instead use `hostnameLabel` in + // CreateVnicDetails. + // If you provide both, the values must match. + HostnameLabel *string `mandatory:"false" json:"hostnameLabel"` + + // Deprecated. Use `sourceDetails` with InstanceSourceViaImageDetails + // source type instead. If you specify values for both, the values must match. + ImageId *string `mandatory:"false" json:"imageId"` + + // This is an advanced option. + // When a bare metal or virtual machine + // instance boots, the iPXE firmware that runs on the instance is + // configured to run an iPXE script to continue the boot process. + // If you want more control over the boot process, you can provide + // your own custom iPXE script that will run when the instance boots. + // Be aware that the same iPXE script will run + // every time an instance boots, not only after the initial + // LaunchInstance call. + // The default iPXE script connects to the instance's local boot + // volume over iSCSI and performs a network boot. If you use a custom iPXE + // script and want to network-boot from the instance's local boot volume + // over iSCSI the same way as the default iPXE script, use the + // following iSCSI IP address: 169.254.0.2, and boot volume IQN: + // iqn.2015-02.oracle.boot. + // If your instance boot volume type is paravirtualized, + // the boot volume is attached to the instance through virtio-scsi and no iPXE script is used. + // If your instance boot volume type is paravirtualized + // and you use custom iPXE to network boot into your instance, + // the primary boot volume is attached as a data volume through virtio-scsi drive. + // For more information about the Bring Your Own Image feature of + // Oracle Cloud Infrastructure, see + // Bring Your Own Image (https://docs.cloud.oracle.com/iaas/Content/Compute/References/bringyourownimage.htm). + // For more information about iPXE, see http://ipxe.org. + IpxeScript *string `mandatory:"false" json:"ipxeScript"` + + LaunchOptions *LaunchOptions `mandatory:"false" json:"launchOptions"` + + InstanceOptions *InstanceOptions `mandatory:"false" json:"instanceOptions"` + + AvailabilityConfig *LaunchInstanceAvailabilityConfigDetails `mandatory:"false" json:"availabilityConfig"` + + PreemptibleInstanceConfig *PreemptibleInstanceConfigDetails `mandatory:"false" json:"preemptibleInstanceConfig"` + + // Custom metadata key/value pairs that you provide, such as the SSH public key + // required to connect to the instance. + // A metadata service runs on every launched instance. The service is an HTTP + // endpoint listening on 169.254.169.254. You can use the service to: + // * Provide information to Cloud-Init (https://cloudinit.readthedocs.org/en/latest/) + // to be used for various system initialization tasks. + // * Get information about the instance, including the custom metadata that you + // provide when you launch the instance. + // **Providing Cloud-Init Metadata** + // You can use the following metadata key names to provide information to + // Cloud-Init: + // **"ssh_authorized_keys"** - Provide one or more public SSH keys to be + // included in the `~/.ssh/authorized_keys` file for the default user on the + // instance. Use a newline character to separate multiple keys. The SSH + // keys must be in the format necessary for the `authorized_keys` file, as shown + // in the example below. + // **"user_data"** - Provide your own base64-encoded data to be used by + // Cloud-Init to run custom scripts or provide custom Cloud-Init configuration. For + // information about how to take advantage of user data, see the + // Cloud-Init Documentation (http://cloudinit.readthedocs.org/en/latest/topics/format.html). + // **Metadata Example** + // "metadata" : { + // "quake_bot_level" : "Severe", + // "ssh_authorized_keys" : "ssh-rsa == rsa-key-20160227", + // "user_data" : "==" + // } + // **Getting Metadata on the Instance** + // To get information about your instance, connect to the instance using SSH and issue any of the + // following GET requests: + // curl -H "Authorization: Bearer Oracle" http://169.254.169.254/opc/v2/instance/ + // curl -H "Authorization: Bearer Oracle" http://169.254.169.254/opc/v2/instance/metadata/ + // curl -H "Authorization: Bearer Oracle" http://169.254.169.254/opc/v2/instance/metadata/ + // You'll get back a response that includes all the instance information; only the metadata information; or + // the metadata information for the specified key name, respectively. + // The combined size of the `metadata` and `extendedMetadata` objects can be a maximum of 32,000 bytes. + Metadata map[string]string `mandatory:"false" json:"metadata"` + + AgentConfig *LaunchInstanceAgentConfigDetails `mandatory:"false" json:"agentConfig"` + + ShapeConfig *LaunchInstanceShapeConfigDetails `mandatory:"false" json:"shapeConfig"` + + SourceDetails InstanceSourceDetails `mandatory:"false" json:"sourceDetails"` + + // Deprecated. Instead use `subnetId` in + // CreateVnicDetails. + // At least one of them is required; if you provide both, the values must match. + SubnetId *string `mandatory:"false" json:"subnetId"` + + // Whether to enable in-transit encryption for the data volume's paravirtualized attachment. This field applies to both block volumes and boot volumes. The default value is false. + IsPvEncryptionInTransitEnabled *bool `mandatory:"false" json:"isPvEncryptionInTransitEnabled"` + + PlatformConfig LaunchInstancePlatformConfig `mandatory:"false" json:"platformConfig"` +} + +func (m LaunchInstanceDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *LaunchInstanceDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + CapacityReservationId *string `json:"capacityReservationId"` + CreateVnicDetails *CreateVnicDetails `json:"createVnicDetails"` + DedicatedVmHostId *string `json:"dedicatedVmHostId"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + DisplayName *string `json:"displayName"` + ExtendedMetadata map[string]interface{} `json:"extendedMetadata"` + FaultDomain *string `json:"faultDomain"` + FreeformTags map[string]string `json:"freeformTags"` + HostnameLabel *string `json:"hostnameLabel"` + ImageId *string `json:"imageId"` + IpxeScript *string `json:"ipxeScript"` + LaunchOptions *LaunchOptions `json:"launchOptions"` + InstanceOptions *InstanceOptions `json:"instanceOptions"` + AvailabilityConfig *LaunchInstanceAvailabilityConfigDetails `json:"availabilityConfig"` + PreemptibleInstanceConfig *PreemptibleInstanceConfigDetails `json:"preemptibleInstanceConfig"` + Metadata map[string]string `json:"metadata"` + AgentConfig *LaunchInstanceAgentConfigDetails `json:"agentConfig"` + ShapeConfig *LaunchInstanceShapeConfigDetails `json:"shapeConfig"` + SourceDetails instancesourcedetails `json:"sourceDetails"` + SubnetId *string `json:"subnetId"` + IsPvEncryptionInTransitEnabled *bool `json:"isPvEncryptionInTransitEnabled"` + PlatformConfig launchinstanceplatformconfig `json:"platformConfig"` + AvailabilityDomain *string `json:"availabilityDomain"` + CompartmentId *string `json:"compartmentId"` + Shape *string `json:"shape"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.CapacityReservationId = model.CapacityReservationId + + m.CreateVnicDetails = model.CreateVnicDetails + + m.DedicatedVmHostId = model.DedicatedVmHostId + + m.DefinedTags = model.DefinedTags + + m.DisplayName = model.DisplayName + + m.ExtendedMetadata = model.ExtendedMetadata + + m.FaultDomain = model.FaultDomain + + m.FreeformTags = model.FreeformTags + + m.HostnameLabel = model.HostnameLabel + + m.ImageId = model.ImageId + + m.IpxeScript = model.IpxeScript + + m.LaunchOptions = model.LaunchOptions + + m.InstanceOptions = model.InstanceOptions + + m.AvailabilityConfig = model.AvailabilityConfig + + m.PreemptibleInstanceConfig = model.PreemptibleInstanceConfig + + m.Metadata = model.Metadata + + m.AgentConfig = model.AgentConfig + + m.ShapeConfig = model.ShapeConfig + + nn, e = model.SourceDetails.UnmarshalPolymorphicJSON(model.SourceDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.SourceDetails = nn.(InstanceSourceDetails) + } else { + m.SourceDetails = nil + } + + m.SubnetId = model.SubnetId + + m.IsPvEncryptionInTransitEnabled = model.IsPvEncryptionInTransitEnabled + + nn, e = model.PlatformConfig.UnmarshalPolymorphicJSON(model.PlatformConfig.JsonData) + if e != nil { + return + } + if nn != nil { + m.PlatformConfig = nn.(LaunchInstancePlatformConfig) + } else { + m.PlatformConfig = nil + } + + m.AvailabilityDomain = model.AvailabilityDomain + + m.CompartmentId = model.CompartmentId + + m.Shape = model.Shape + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_platform_config.go new file mode 100644 index 000000000..612268bb0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_platform_config.go @@ -0,0 +1,146 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// LaunchInstancePlatformConfig The platform configuration requested for the instance. +// If you provide the parameter, the instance is created with the platform configuration that you specify. +// For any values that you omit, the instance uses the default configuration values for the `shape` that you +// specify. If you don't provide the parameter, the default values for the `shape` are used. +// Each shape only supports certain configurable values. If the values that you provide are not valid for the +// specified `shape`, an error is returned. +type LaunchInstancePlatformConfig interface { + + // Whether Secure Boot is enabled on the instance. + GetIsSecureBootEnabled() *bool + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + GetIsTrustedPlatformModuleEnabled() *bool + + // Whether the Measured Boot feature is enabled on the instance. + GetIsMeasuredBootEnabled() *bool +} + +type launchinstanceplatformconfig struct { + JsonData []byte + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *launchinstanceplatformconfig) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerlaunchinstanceplatformconfig launchinstanceplatformconfig + s := struct { + Model Unmarshalerlaunchinstanceplatformconfig + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.IsSecureBootEnabled = s.Model.IsSecureBootEnabled + m.IsTrustedPlatformModuleEnabled = s.Model.IsTrustedPlatformModuleEnabled + m.IsMeasuredBootEnabled = s.Model.IsMeasuredBootEnabled + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *launchinstanceplatformconfig) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "AMD_ROME_BM": + mm := AmdRomeBmLaunchInstancePlatformConfig{} + err = json.Unmarshal(data, &mm) + return mm, err + case "AMD_VM": + mm := AmdVmLaunchInstancePlatformConfig{} + err = json.Unmarshal(data, &mm) + return mm, err + case "INTEL_VM": + mm := IntelVmLaunchInstancePlatformConfig{} + err = json.Unmarshal(data, &mm) + return mm, err + case "INTEL_SKYLAKE_BM": + mm := IntelSkylakeBmLaunchInstancePlatformConfig{} + err = json.Unmarshal(data, &mm) + return mm, err + case "AMD_MILAN_BM": + mm := AmdMilanBmLaunchInstancePlatformConfig{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m launchinstanceplatformconfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m launchinstanceplatformconfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m launchinstanceplatformconfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m launchinstanceplatformconfig) String() string { + return common.PointerString(m) +} + +// LaunchInstancePlatformConfigTypeEnum Enum with underlying type: string +type LaunchInstancePlatformConfigTypeEnum string + +// Set of constants representing the allowable values for LaunchInstancePlatformConfigTypeEnum +const ( + LaunchInstancePlatformConfigTypeAmdMilanBm LaunchInstancePlatformConfigTypeEnum = "AMD_MILAN_BM" + LaunchInstancePlatformConfigTypeAmdRomeBm LaunchInstancePlatformConfigTypeEnum = "AMD_ROME_BM" + LaunchInstancePlatformConfigTypeIntelSkylakeBm LaunchInstancePlatformConfigTypeEnum = "INTEL_SKYLAKE_BM" + LaunchInstancePlatformConfigTypeAmdVm LaunchInstancePlatformConfigTypeEnum = "AMD_VM" + LaunchInstancePlatformConfigTypeIntelVm LaunchInstancePlatformConfigTypeEnum = "INTEL_VM" +) + +var mappingLaunchInstancePlatformConfigType = map[string]LaunchInstancePlatformConfigTypeEnum{ + "AMD_MILAN_BM": LaunchInstancePlatformConfigTypeAmdMilanBm, + "AMD_ROME_BM": LaunchInstancePlatformConfigTypeAmdRomeBm, + "INTEL_SKYLAKE_BM": LaunchInstancePlatformConfigTypeIntelSkylakeBm, + "AMD_VM": LaunchInstancePlatformConfigTypeAmdVm, + "INTEL_VM": LaunchInstancePlatformConfigTypeIntelVm, +} + +// GetLaunchInstancePlatformConfigTypeEnumValues Enumerates the set of values for LaunchInstancePlatformConfigTypeEnum +func GetLaunchInstancePlatformConfigTypeEnumValues() []LaunchInstancePlatformConfigTypeEnum { + values := make([]LaunchInstancePlatformConfigTypeEnum, 0) + for _, v := range mappingLaunchInstancePlatformConfigType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_request_response.go new file mode 100644 index 000000000..65e27d43a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// LaunchInstanceRequest wrapper for the LaunchInstance operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/LaunchInstance.go.html to see an example of how to use LaunchInstanceRequest. +type LaunchInstanceRequest struct { + + // Instance details + LaunchInstanceDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request LaunchInstanceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request LaunchInstanceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request LaunchInstanceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request LaunchInstanceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// LaunchInstanceResponse wrapper for the LaunchInstance operation +type LaunchInstanceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Instance instance + Instance `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response LaunchInstanceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response LaunchInstanceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_shape_config_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_shape_config_details.go new file mode 100644 index 000000000..14b9b0163 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_instance_shape_config_details.go @@ -0,0 +1,70 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// LaunchInstanceShapeConfigDetails The shape configuration requested for the instance. +// If the parameter is provided, the instance is created with the resources that you specify. If some +// properties are missing or the entire parameter is not provided, the instance is created +// with the default configuration values for the `shape` that you specify. +// Each shape only supports certain configurable values. If the values that you provide are not valid for the +// specified `shape`, an error is returned. +type LaunchInstanceShapeConfigDetails struct { + + // The total number of OCPUs available to the instance. + Ocpus *float32 `mandatory:"false" json:"ocpus"` + + // The total amount of memory available to the instance, in gigabytes. + MemoryInGBs *float32 `mandatory:"false" json:"memoryInGBs"` + + // The baseline OCPU utilization for a subcore burstable VM instance. Leave this attribute blank for a + // non-burstable instance, or explicitly specify non-burstable with `BASELINE_1_1`. + // The following values are supported: + // - `BASELINE_1_8` - baseline usage is 1/8 of an OCPU. + // - `BASELINE_1_2` - baseline usage is 1/2 of an OCPU. + // - `BASELINE_1_1` - baseline usage is an entire OCPU. This represents a non-burstable instance. + BaselineOcpuUtilization LaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum `mandatory:"false" json:"baselineOcpuUtilization,omitempty"` +} + +func (m LaunchInstanceShapeConfigDetails) String() string { + return common.PointerString(m) +} + +// LaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum Enum with underlying type: string +type LaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum string + +// Set of constants representing the allowable values for LaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum +const ( + LaunchInstanceShapeConfigDetailsBaselineOcpuUtilization8 LaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum = "BASELINE_1_8" + LaunchInstanceShapeConfigDetailsBaselineOcpuUtilization2 LaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum = "BASELINE_1_2" + LaunchInstanceShapeConfigDetailsBaselineOcpuUtilization1 LaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum = "BASELINE_1_1" +) + +var mappingLaunchInstanceShapeConfigDetailsBaselineOcpuUtilization = map[string]LaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum{ + "BASELINE_1_8": LaunchInstanceShapeConfigDetailsBaselineOcpuUtilization8, + "BASELINE_1_2": LaunchInstanceShapeConfigDetailsBaselineOcpuUtilization2, + "BASELINE_1_1": LaunchInstanceShapeConfigDetailsBaselineOcpuUtilization1, +} + +// GetLaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnumValues Enumerates the set of values for LaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum +func GetLaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnumValues() []LaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum { + values := make([]LaunchInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum, 0) + for _, v := range mappingLaunchInstanceShapeConfigDetailsBaselineOcpuUtilization { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_options.go new file mode 100644 index 000000000..0e9e19f52 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/launch_options.go @@ -0,0 +1,174 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// LaunchOptions Options for tuning the compatibility and performance of VM shapes. The values that you specify override any +// default values. +type LaunchOptions struct { + + // Emulation type for the boot volume. + // * `ISCSI` - ISCSI attached block storage device. + // * `SCSI` - Emulated SCSI disk. + // * `IDE` - Emulated IDE disk. + // * `VFIO` - Direct attached Virtual Function storage. This is the default option for local data + // volumes on platform images. + // * `PARAVIRTUALIZED` - Paravirtualized disk. This is the default for boot volumes and remote block + // storage volumes on platform images. + BootVolumeType LaunchOptionsBootVolumeTypeEnum `mandatory:"false" json:"bootVolumeType,omitempty"` + + // Firmware used to boot VM. Select the option that matches your operating system. + // * `BIOS` - Boot VM using BIOS style firmware. This is compatible with both 32 bit and 64 bit operating + // systems that boot using MBR style bootloaders. + // * `UEFI_64` - Boot VM using UEFI style firmware compatible with 64 bit operating systems. This is the + // default for platform images. + Firmware LaunchOptionsFirmwareEnum `mandatory:"false" json:"firmware,omitempty"` + + // Emulation type for the physical network interface card (NIC). + // * `E1000` - Emulated Gigabit ethernet controller. Compatible with Linux e1000 network driver. + // * `VFIO` - Direct attached Virtual Function network controller. This is the networking type + // when you launch an instance using hardware-assisted (SR-IOV) networking. + // * `PARAVIRTUALIZED` - VM instances launch with paravirtualized devices using VirtIO drivers. + NetworkType LaunchOptionsNetworkTypeEnum `mandatory:"false" json:"networkType,omitempty"` + + // Emulation type for volume. + // * `ISCSI` - ISCSI attached block storage device. + // * `SCSI` - Emulated SCSI disk. + // * `IDE` - Emulated IDE disk. + // * `VFIO` - Direct attached Virtual Function storage. This is the default option for local data + // volumes on platform images. + // * `PARAVIRTUALIZED` - Paravirtualized disk. This is the default for boot volumes and remote block + // storage volumes on platform images. + RemoteDataVolumeType LaunchOptionsRemoteDataVolumeTypeEnum `mandatory:"false" json:"remoteDataVolumeType,omitempty"` + + // Deprecated. Instead use `isPvEncryptionInTransitEnabled` in + // LaunchInstanceDetails. + IsPvEncryptionInTransitEnabled *bool `mandatory:"false" json:"isPvEncryptionInTransitEnabled"` + + // Whether to enable consistent volume naming feature. Defaults to false. + IsConsistentVolumeNamingEnabled *bool `mandatory:"false" json:"isConsistentVolumeNamingEnabled"` +} + +func (m LaunchOptions) String() string { + return common.PointerString(m) +} + +// LaunchOptionsBootVolumeTypeEnum Enum with underlying type: string +type LaunchOptionsBootVolumeTypeEnum string + +// Set of constants representing the allowable values for LaunchOptionsBootVolumeTypeEnum +const ( + LaunchOptionsBootVolumeTypeIscsi LaunchOptionsBootVolumeTypeEnum = "ISCSI" + LaunchOptionsBootVolumeTypeScsi LaunchOptionsBootVolumeTypeEnum = "SCSI" + LaunchOptionsBootVolumeTypeIde LaunchOptionsBootVolumeTypeEnum = "IDE" + LaunchOptionsBootVolumeTypeVfio LaunchOptionsBootVolumeTypeEnum = "VFIO" + LaunchOptionsBootVolumeTypeParavirtualized LaunchOptionsBootVolumeTypeEnum = "PARAVIRTUALIZED" +) + +var mappingLaunchOptionsBootVolumeType = map[string]LaunchOptionsBootVolumeTypeEnum{ + "ISCSI": LaunchOptionsBootVolumeTypeIscsi, + "SCSI": LaunchOptionsBootVolumeTypeScsi, + "IDE": LaunchOptionsBootVolumeTypeIde, + "VFIO": LaunchOptionsBootVolumeTypeVfio, + "PARAVIRTUALIZED": LaunchOptionsBootVolumeTypeParavirtualized, +} + +// GetLaunchOptionsBootVolumeTypeEnumValues Enumerates the set of values for LaunchOptionsBootVolumeTypeEnum +func GetLaunchOptionsBootVolumeTypeEnumValues() []LaunchOptionsBootVolumeTypeEnum { + values := make([]LaunchOptionsBootVolumeTypeEnum, 0) + for _, v := range mappingLaunchOptionsBootVolumeType { + values = append(values, v) + } + return values +} + +// LaunchOptionsFirmwareEnum Enum with underlying type: string +type LaunchOptionsFirmwareEnum string + +// Set of constants representing the allowable values for LaunchOptionsFirmwareEnum +const ( + LaunchOptionsFirmwareBios LaunchOptionsFirmwareEnum = "BIOS" + LaunchOptionsFirmwareUefi64 LaunchOptionsFirmwareEnum = "UEFI_64" +) + +var mappingLaunchOptionsFirmware = map[string]LaunchOptionsFirmwareEnum{ + "BIOS": LaunchOptionsFirmwareBios, + "UEFI_64": LaunchOptionsFirmwareUefi64, +} + +// GetLaunchOptionsFirmwareEnumValues Enumerates the set of values for LaunchOptionsFirmwareEnum +func GetLaunchOptionsFirmwareEnumValues() []LaunchOptionsFirmwareEnum { + values := make([]LaunchOptionsFirmwareEnum, 0) + for _, v := range mappingLaunchOptionsFirmware { + values = append(values, v) + } + return values +} + +// LaunchOptionsNetworkTypeEnum Enum with underlying type: string +type LaunchOptionsNetworkTypeEnum string + +// Set of constants representing the allowable values for LaunchOptionsNetworkTypeEnum +const ( + LaunchOptionsNetworkTypeE1000 LaunchOptionsNetworkTypeEnum = "E1000" + LaunchOptionsNetworkTypeVfio LaunchOptionsNetworkTypeEnum = "VFIO" + LaunchOptionsNetworkTypeParavirtualized LaunchOptionsNetworkTypeEnum = "PARAVIRTUALIZED" +) + +var mappingLaunchOptionsNetworkType = map[string]LaunchOptionsNetworkTypeEnum{ + "E1000": LaunchOptionsNetworkTypeE1000, + "VFIO": LaunchOptionsNetworkTypeVfio, + "PARAVIRTUALIZED": LaunchOptionsNetworkTypeParavirtualized, +} + +// GetLaunchOptionsNetworkTypeEnumValues Enumerates the set of values for LaunchOptionsNetworkTypeEnum +func GetLaunchOptionsNetworkTypeEnumValues() []LaunchOptionsNetworkTypeEnum { + values := make([]LaunchOptionsNetworkTypeEnum, 0) + for _, v := range mappingLaunchOptionsNetworkType { + values = append(values, v) + } + return values +} + +// LaunchOptionsRemoteDataVolumeTypeEnum Enum with underlying type: string +type LaunchOptionsRemoteDataVolumeTypeEnum string + +// Set of constants representing the allowable values for LaunchOptionsRemoteDataVolumeTypeEnum +const ( + LaunchOptionsRemoteDataVolumeTypeIscsi LaunchOptionsRemoteDataVolumeTypeEnum = "ISCSI" + LaunchOptionsRemoteDataVolumeTypeScsi LaunchOptionsRemoteDataVolumeTypeEnum = "SCSI" + LaunchOptionsRemoteDataVolumeTypeIde LaunchOptionsRemoteDataVolumeTypeEnum = "IDE" + LaunchOptionsRemoteDataVolumeTypeVfio LaunchOptionsRemoteDataVolumeTypeEnum = "VFIO" + LaunchOptionsRemoteDataVolumeTypeParavirtualized LaunchOptionsRemoteDataVolumeTypeEnum = "PARAVIRTUALIZED" +) + +var mappingLaunchOptionsRemoteDataVolumeType = map[string]LaunchOptionsRemoteDataVolumeTypeEnum{ + "ISCSI": LaunchOptionsRemoteDataVolumeTypeIscsi, + "SCSI": LaunchOptionsRemoteDataVolumeTypeScsi, + "IDE": LaunchOptionsRemoteDataVolumeTypeIde, + "VFIO": LaunchOptionsRemoteDataVolumeTypeVfio, + "PARAVIRTUALIZED": LaunchOptionsRemoteDataVolumeTypeParavirtualized, +} + +// GetLaunchOptionsRemoteDataVolumeTypeEnumValues Enumerates the set of values for LaunchOptionsRemoteDataVolumeTypeEnum +func GetLaunchOptionsRemoteDataVolumeTypeEnumValues() []LaunchOptionsRemoteDataVolumeTypeEnum { + values := make([]LaunchOptionsRemoteDataVolumeTypeEnum, 0) + for _, v := range mappingLaunchOptionsRemoteDataVolumeType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/letter_of_authority.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/letter_of_authority.go new file mode 100644 index 000000000..bb1b9df01 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/letter_of_authority.go @@ -0,0 +1,72 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// LetterOfAuthority The Letter of Authority for the cross-connect. You must submit this letter when +// requesting cabling for the cross-connect at the FastConnect location. +type LetterOfAuthority struct { + + // The name of the entity authorized by this Letter of Authority. + AuthorizedEntityName *string `mandatory:"false" json:"authorizedEntityName"` + + // The type of cross-connect fiber, termination, and optical specification. + CircuitType LetterOfAuthorityCircuitTypeEnum `mandatory:"false" json:"circuitType,omitempty"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the cross-connect. + CrossConnectId *string `mandatory:"false" json:"crossConnectId"` + + // The address of the FastConnect location. + FacilityLocation *string `mandatory:"false" json:"facilityLocation"` + + // The meet-me room port for this cross-connect. + PortName *string `mandatory:"false" json:"portName"` + + // The date and time when the Letter of Authority expires, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeExpires *common.SDKTime `mandatory:"false" json:"timeExpires"` + + // The date and time the Letter of Authority was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeIssued *common.SDKTime `mandatory:"false" json:"timeIssued"` +} + +func (m LetterOfAuthority) String() string { + return common.PointerString(m) +} + +// LetterOfAuthorityCircuitTypeEnum Enum with underlying type: string +type LetterOfAuthorityCircuitTypeEnum string + +// Set of constants representing the allowable values for LetterOfAuthorityCircuitTypeEnum +const ( + LetterOfAuthorityCircuitTypeLc LetterOfAuthorityCircuitTypeEnum = "Single_mode_LC" + LetterOfAuthorityCircuitTypeSc LetterOfAuthorityCircuitTypeEnum = "Single_mode_SC" +) + +var mappingLetterOfAuthorityCircuitType = map[string]LetterOfAuthorityCircuitTypeEnum{ + "Single_mode_LC": LetterOfAuthorityCircuitTypeLc, + "Single_mode_SC": LetterOfAuthorityCircuitTypeSc, +} + +// GetLetterOfAuthorityCircuitTypeEnumValues Enumerates the set of values for LetterOfAuthorityCircuitTypeEnum +func GetLetterOfAuthorityCircuitTypeEnumValues() []LetterOfAuthorityCircuitTypeEnum { + values := make([]LetterOfAuthorityCircuitTypeEnum, 0) + for _, v := range mappingLetterOfAuthorityCircuitType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_allowed_peer_regions_for_remote_peering_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_allowed_peer_regions_for_remote_peering_request_response.go new file mode 100644 index 000000000..9093da4a8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_allowed_peer_regions_for_remote_peering_request_response.go @@ -0,0 +1,71 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListAllowedPeerRegionsForRemotePeeringRequest wrapper for the ListAllowedPeerRegionsForRemotePeering operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListAllowedPeerRegionsForRemotePeering.go.html to see an example of how to use ListAllowedPeerRegionsForRemotePeeringRequest. +type ListAllowedPeerRegionsForRemotePeeringRequest struct { + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListAllowedPeerRegionsForRemotePeeringRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListAllowedPeerRegionsForRemotePeeringRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListAllowedPeerRegionsForRemotePeeringRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListAllowedPeerRegionsForRemotePeeringRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListAllowedPeerRegionsForRemotePeeringResponse wrapper for the ListAllowedPeerRegionsForRemotePeering operation +type ListAllowedPeerRegionsForRemotePeeringResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []PeerRegionForRemotePeering instance + Items []PeerRegionForRemotePeering `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListAllowedPeerRegionsForRemotePeeringResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListAllowedPeerRegionsForRemotePeeringResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_app_catalog_listing_resource_versions_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_app_catalog_listing_resource_versions_request_response.go new file mode 100644 index 000000000..46cbd2c2e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_app_catalog_listing_resource_versions_request_response.go @@ -0,0 +1,117 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListAppCatalogListingResourceVersionsRequest wrapper for the ListAppCatalogListingResourceVersions operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListAppCatalogListingResourceVersions.go.html to see an example of how to use ListAppCatalogListingResourceVersionsRequest. +type ListAppCatalogListingResourceVersionsRequest struct { + + // The OCID of the listing. + ListingId *string `mandatory:"true" contributesTo:"path" name:"listingId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListAppCatalogListingResourceVersionsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListAppCatalogListingResourceVersionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListAppCatalogListingResourceVersionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListAppCatalogListingResourceVersionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListAppCatalogListingResourceVersionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListAppCatalogListingResourceVersionsResponse wrapper for the ListAppCatalogListingResourceVersions operation +type ListAppCatalogListingResourceVersionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []AppCatalogListingResourceVersionSummary instances + Items []AppCatalogListingResourceVersionSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListAppCatalogListingResourceVersionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListAppCatalogListingResourceVersionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListAppCatalogListingResourceVersionsSortOrderEnum Enum with underlying type: string +type ListAppCatalogListingResourceVersionsSortOrderEnum string + +// Set of constants representing the allowable values for ListAppCatalogListingResourceVersionsSortOrderEnum +const ( + ListAppCatalogListingResourceVersionsSortOrderAsc ListAppCatalogListingResourceVersionsSortOrderEnum = "ASC" + ListAppCatalogListingResourceVersionsSortOrderDesc ListAppCatalogListingResourceVersionsSortOrderEnum = "DESC" +) + +var mappingListAppCatalogListingResourceVersionsSortOrder = map[string]ListAppCatalogListingResourceVersionsSortOrderEnum{ + "ASC": ListAppCatalogListingResourceVersionsSortOrderAsc, + "DESC": ListAppCatalogListingResourceVersionsSortOrderDesc, +} + +// GetListAppCatalogListingResourceVersionsSortOrderEnumValues Enumerates the set of values for ListAppCatalogListingResourceVersionsSortOrderEnum +func GetListAppCatalogListingResourceVersionsSortOrderEnumValues() []ListAppCatalogListingResourceVersionsSortOrderEnum { + values := make([]ListAppCatalogListingResourceVersionsSortOrderEnum, 0) + for _, v := range mappingListAppCatalogListingResourceVersionsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_app_catalog_listings_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_app_catalog_listings_request_response.go new file mode 100644 index 000000000..ba584e91f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_app_catalog_listings_request_response.go @@ -0,0 +1,123 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListAppCatalogListingsRequest wrapper for the ListAppCatalogListings operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListAppCatalogListings.go.html to see an example of how to use ListAppCatalogListingsRequest. +type ListAppCatalogListingsRequest struct { + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListAppCatalogListingsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to return only the publisher that matches the given publisher name exactly. + PublisherName *string `mandatory:"false" contributesTo:"query" name:"publisherName"` + + // A filter to return only publishers that match the given publisher type exactly. Valid types are OCI, ORACLE, TRUSTED, STANDARD. + PublisherType *string `mandatory:"false" contributesTo:"query" name:"publisherType"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListAppCatalogListingsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListAppCatalogListingsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListAppCatalogListingsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListAppCatalogListingsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListAppCatalogListingsResponse wrapper for the ListAppCatalogListings operation +type ListAppCatalogListingsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []AppCatalogListingSummary instances + Items []AppCatalogListingSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListAppCatalogListingsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListAppCatalogListingsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListAppCatalogListingsSortOrderEnum Enum with underlying type: string +type ListAppCatalogListingsSortOrderEnum string + +// Set of constants representing the allowable values for ListAppCatalogListingsSortOrderEnum +const ( + ListAppCatalogListingsSortOrderAsc ListAppCatalogListingsSortOrderEnum = "ASC" + ListAppCatalogListingsSortOrderDesc ListAppCatalogListingsSortOrderEnum = "DESC" +) + +var mappingListAppCatalogListingsSortOrder = map[string]ListAppCatalogListingsSortOrderEnum{ + "ASC": ListAppCatalogListingsSortOrderAsc, + "DESC": ListAppCatalogListingsSortOrderDesc, +} + +// GetListAppCatalogListingsSortOrderEnumValues Enumerates the set of values for ListAppCatalogListingsSortOrderEnum +func GetListAppCatalogListingsSortOrderEnumValues() []ListAppCatalogListingsSortOrderEnum { + values := make([]ListAppCatalogListingsSortOrderEnum, 0) + for _, v := range mappingListAppCatalogListingsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_app_catalog_subscriptions_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_app_catalog_subscriptions_request_response.go new file mode 100644 index 000000000..8199e6074 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_app_catalog_subscriptions_request_response.go @@ -0,0 +1,152 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListAppCatalogSubscriptionsRequest wrapper for the ListAppCatalogSubscriptions operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListAppCatalogSubscriptions.go.html to see an example of how to use ListAppCatalogSubscriptionsRequest. +type ListAppCatalogSubscriptionsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListAppCatalogSubscriptionsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListAppCatalogSubscriptionsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to return only the listings that matches the given listing id. + ListingId *string `mandatory:"false" contributesTo:"query" name:"listingId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListAppCatalogSubscriptionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListAppCatalogSubscriptionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListAppCatalogSubscriptionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListAppCatalogSubscriptionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListAppCatalogSubscriptionsResponse wrapper for the ListAppCatalogSubscriptions operation +type ListAppCatalogSubscriptionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []AppCatalogSubscriptionSummary instances + Items []AppCatalogSubscriptionSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListAppCatalogSubscriptionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListAppCatalogSubscriptionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListAppCatalogSubscriptionsSortByEnum Enum with underlying type: string +type ListAppCatalogSubscriptionsSortByEnum string + +// Set of constants representing the allowable values for ListAppCatalogSubscriptionsSortByEnum +const ( + ListAppCatalogSubscriptionsSortByTimecreated ListAppCatalogSubscriptionsSortByEnum = "TIMECREATED" + ListAppCatalogSubscriptionsSortByDisplayname ListAppCatalogSubscriptionsSortByEnum = "DISPLAYNAME" +) + +var mappingListAppCatalogSubscriptionsSortBy = map[string]ListAppCatalogSubscriptionsSortByEnum{ + "TIMECREATED": ListAppCatalogSubscriptionsSortByTimecreated, + "DISPLAYNAME": ListAppCatalogSubscriptionsSortByDisplayname, +} + +// GetListAppCatalogSubscriptionsSortByEnumValues Enumerates the set of values for ListAppCatalogSubscriptionsSortByEnum +func GetListAppCatalogSubscriptionsSortByEnumValues() []ListAppCatalogSubscriptionsSortByEnum { + values := make([]ListAppCatalogSubscriptionsSortByEnum, 0) + for _, v := range mappingListAppCatalogSubscriptionsSortBy { + values = append(values, v) + } + return values +} + +// ListAppCatalogSubscriptionsSortOrderEnum Enum with underlying type: string +type ListAppCatalogSubscriptionsSortOrderEnum string + +// Set of constants representing the allowable values for ListAppCatalogSubscriptionsSortOrderEnum +const ( + ListAppCatalogSubscriptionsSortOrderAsc ListAppCatalogSubscriptionsSortOrderEnum = "ASC" + ListAppCatalogSubscriptionsSortOrderDesc ListAppCatalogSubscriptionsSortOrderEnum = "DESC" +) + +var mappingListAppCatalogSubscriptionsSortOrder = map[string]ListAppCatalogSubscriptionsSortOrderEnum{ + "ASC": ListAppCatalogSubscriptionsSortOrderAsc, + "DESC": ListAppCatalogSubscriptionsSortOrderDesc, +} + +// GetListAppCatalogSubscriptionsSortOrderEnumValues Enumerates the set of values for ListAppCatalogSubscriptionsSortOrderEnum +func GetListAppCatalogSubscriptionsSortOrderEnumValues() []ListAppCatalogSubscriptionsSortOrderEnum { + values := make([]ListAppCatalogSubscriptionsSortOrderEnum, 0) + for _, v := range mappingListAppCatalogSubscriptionsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_block_volume_replicas_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_block_volume_replicas_request_response.go new file mode 100644 index 000000000..58695fea6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_block_volume_replicas_request_response.go @@ -0,0 +1,159 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListBlockVolumeReplicasRequest wrapper for the ListBlockVolumeReplicas operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListBlockVolumeReplicas.go.html to see an example of how to use ListBlockVolumeReplicasRequest. +type ListBlockVolumeReplicasRequest struct { + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" contributesTo:"query" name:"availabilityDomain"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListBlockVolumeReplicasSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListBlockVolumeReplicasSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState BlockVolumeReplicaLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListBlockVolumeReplicasRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListBlockVolumeReplicasRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListBlockVolumeReplicasRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListBlockVolumeReplicasRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListBlockVolumeReplicasResponse wrapper for the ListBlockVolumeReplicas operation +type ListBlockVolumeReplicasResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []BlockVolumeReplica instances + Items []BlockVolumeReplica `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListBlockVolumeReplicasResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListBlockVolumeReplicasResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListBlockVolumeReplicasSortByEnum Enum with underlying type: string +type ListBlockVolumeReplicasSortByEnum string + +// Set of constants representing the allowable values for ListBlockVolumeReplicasSortByEnum +const ( + ListBlockVolumeReplicasSortByTimecreated ListBlockVolumeReplicasSortByEnum = "TIMECREATED" + ListBlockVolumeReplicasSortByDisplayname ListBlockVolumeReplicasSortByEnum = "DISPLAYNAME" +) + +var mappingListBlockVolumeReplicasSortBy = map[string]ListBlockVolumeReplicasSortByEnum{ + "TIMECREATED": ListBlockVolumeReplicasSortByTimecreated, + "DISPLAYNAME": ListBlockVolumeReplicasSortByDisplayname, +} + +// GetListBlockVolumeReplicasSortByEnumValues Enumerates the set of values for ListBlockVolumeReplicasSortByEnum +func GetListBlockVolumeReplicasSortByEnumValues() []ListBlockVolumeReplicasSortByEnum { + values := make([]ListBlockVolumeReplicasSortByEnum, 0) + for _, v := range mappingListBlockVolumeReplicasSortBy { + values = append(values, v) + } + return values +} + +// ListBlockVolumeReplicasSortOrderEnum Enum with underlying type: string +type ListBlockVolumeReplicasSortOrderEnum string + +// Set of constants representing the allowable values for ListBlockVolumeReplicasSortOrderEnum +const ( + ListBlockVolumeReplicasSortOrderAsc ListBlockVolumeReplicasSortOrderEnum = "ASC" + ListBlockVolumeReplicasSortOrderDesc ListBlockVolumeReplicasSortOrderEnum = "DESC" +) + +var mappingListBlockVolumeReplicasSortOrder = map[string]ListBlockVolumeReplicasSortOrderEnum{ + "ASC": ListBlockVolumeReplicasSortOrderAsc, + "DESC": ListBlockVolumeReplicasSortOrderDesc, +} + +// GetListBlockVolumeReplicasSortOrderEnumValues Enumerates the set of values for ListBlockVolumeReplicasSortOrderEnum +func GetListBlockVolumeReplicasSortOrderEnumValues() []ListBlockVolumeReplicasSortOrderEnum { + values := make([]ListBlockVolumeReplicasSortOrderEnum, 0) + for _, v := range mappingListBlockVolumeReplicasSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volume_attachments_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volume_attachments_request_response.go new file mode 100644 index 000000000..115fadf02 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volume_attachments_request_response.go @@ -0,0 +1,100 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListBootVolumeAttachmentsRequest wrapper for the ListBootVolumeAttachments operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListBootVolumeAttachments.go.html to see an example of how to use ListBootVolumeAttachmentsRequest. +type ListBootVolumeAttachmentsRequest struct { + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" contributesTo:"query" name:"availabilityDomain"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The OCID of the instance. + InstanceId *string `mandatory:"false" contributesTo:"query" name:"instanceId"` + + // The OCID of the boot volume. + BootVolumeId *string `mandatory:"false" contributesTo:"query" name:"bootVolumeId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListBootVolumeAttachmentsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListBootVolumeAttachmentsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListBootVolumeAttachmentsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListBootVolumeAttachmentsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListBootVolumeAttachmentsResponse wrapper for the ListBootVolumeAttachments operation +type ListBootVolumeAttachmentsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []BootVolumeAttachment instances + Items []BootVolumeAttachment `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListBootVolumeAttachmentsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListBootVolumeAttachmentsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volume_backups_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volume_backups_request_response.go new file mode 100644 index 000000000..169280949 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volume_backups_request_response.go @@ -0,0 +1,162 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListBootVolumeBackupsRequest wrapper for the ListBootVolumeBackups operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListBootVolumeBackups.go.html to see an example of how to use ListBootVolumeBackupsRequest. +type ListBootVolumeBackupsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID of the boot volume. + BootVolumeId *string `mandatory:"false" contributesTo:"query" name:"bootVolumeId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // A filter to return only resources that originated from the given source boot volume backup. + SourceBootVolumeBackupId *string `mandatory:"false" contributesTo:"query" name:"sourceBootVolumeBackupId"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListBootVolumeBackupsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListBootVolumeBackupsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state value is + // case-insensitive. + LifecycleState BootVolumeBackupLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListBootVolumeBackupsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListBootVolumeBackupsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListBootVolumeBackupsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListBootVolumeBackupsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListBootVolumeBackupsResponse wrapper for the ListBootVolumeBackups operation +type ListBootVolumeBackupsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []BootVolumeBackup instances + Items []BootVolumeBackup `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListBootVolumeBackupsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListBootVolumeBackupsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListBootVolumeBackupsSortByEnum Enum with underlying type: string +type ListBootVolumeBackupsSortByEnum string + +// Set of constants representing the allowable values for ListBootVolumeBackupsSortByEnum +const ( + ListBootVolumeBackupsSortByTimecreated ListBootVolumeBackupsSortByEnum = "TIMECREATED" + ListBootVolumeBackupsSortByDisplayname ListBootVolumeBackupsSortByEnum = "DISPLAYNAME" +) + +var mappingListBootVolumeBackupsSortBy = map[string]ListBootVolumeBackupsSortByEnum{ + "TIMECREATED": ListBootVolumeBackupsSortByTimecreated, + "DISPLAYNAME": ListBootVolumeBackupsSortByDisplayname, +} + +// GetListBootVolumeBackupsSortByEnumValues Enumerates the set of values for ListBootVolumeBackupsSortByEnum +func GetListBootVolumeBackupsSortByEnumValues() []ListBootVolumeBackupsSortByEnum { + values := make([]ListBootVolumeBackupsSortByEnum, 0) + for _, v := range mappingListBootVolumeBackupsSortBy { + values = append(values, v) + } + return values +} + +// ListBootVolumeBackupsSortOrderEnum Enum with underlying type: string +type ListBootVolumeBackupsSortOrderEnum string + +// Set of constants representing the allowable values for ListBootVolumeBackupsSortOrderEnum +const ( + ListBootVolumeBackupsSortOrderAsc ListBootVolumeBackupsSortOrderEnum = "ASC" + ListBootVolumeBackupsSortOrderDesc ListBootVolumeBackupsSortOrderEnum = "DESC" +) + +var mappingListBootVolumeBackupsSortOrder = map[string]ListBootVolumeBackupsSortOrderEnum{ + "ASC": ListBootVolumeBackupsSortOrderAsc, + "DESC": ListBootVolumeBackupsSortOrderDesc, +} + +// GetListBootVolumeBackupsSortOrderEnumValues Enumerates the set of values for ListBootVolumeBackupsSortOrderEnum +func GetListBootVolumeBackupsSortOrderEnumValues() []ListBootVolumeBackupsSortOrderEnum { + values := make([]ListBootVolumeBackupsSortOrderEnum, 0) + for _, v := range mappingListBootVolumeBackupsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volume_replicas_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volume_replicas_request_response.go new file mode 100644 index 000000000..d359ff47f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volume_replicas_request_response.go @@ -0,0 +1,159 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListBootVolumeReplicasRequest wrapper for the ListBootVolumeReplicas operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListBootVolumeReplicas.go.html to see an example of how to use ListBootVolumeReplicasRequest. +type ListBootVolumeReplicasRequest struct { + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" contributesTo:"query" name:"availabilityDomain"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListBootVolumeReplicasSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListBootVolumeReplicasSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState BootVolumeReplicaLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListBootVolumeReplicasRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListBootVolumeReplicasRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListBootVolumeReplicasRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListBootVolumeReplicasRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListBootVolumeReplicasResponse wrapper for the ListBootVolumeReplicas operation +type ListBootVolumeReplicasResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []BootVolumeReplica instances + Items []BootVolumeReplica `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListBootVolumeReplicasResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListBootVolumeReplicasResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListBootVolumeReplicasSortByEnum Enum with underlying type: string +type ListBootVolumeReplicasSortByEnum string + +// Set of constants representing the allowable values for ListBootVolumeReplicasSortByEnum +const ( + ListBootVolumeReplicasSortByTimecreated ListBootVolumeReplicasSortByEnum = "TIMECREATED" + ListBootVolumeReplicasSortByDisplayname ListBootVolumeReplicasSortByEnum = "DISPLAYNAME" +) + +var mappingListBootVolumeReplicasSortBy = map[string]ListBootVolumeReplicasSortByEnum{ + "TIMECREATED": ListBootVolumeReplicasSortByTimecreated, + "DISPLAYNAME": ListBootVolumeReplicasSortByDisplayname, +} + +// GetListBootVolumeReplicasSortByEnumValues Enumerates the set of values for ListBootVolumeReplicasSortByEnum +func GetListBootVolumeReplicasSortByEnumValues() []ListBootVolumeReplicasSortByEnum { + values := make([]ListBootVolumeReplicasSortByEnum, 0) + for _, v := range mappingListBootVolumeReplicasSortBy { + values = append(values, v) + } + return values +} + +// ListBootVolumeReplicasSortOrderEnum Enum with underlying type: string +type ListBootVolumeReplicasSortOrderEnum string + +// Set of constants representing the allowable values for ListBootVolumeReplicasSortOrderEnum +const ( + ListBootVolumeReplicasSortOrderAsc ListBootVolumeReplicasSortOrderEnum = "ASC" + ListBootVolumeReplicasSortOrderDesc ListBootVolumeReplicasSortOrderEnum = "DESC" +) + +var mappingListBootVolumeReplicasSortOrder = map[string]ListBootVolumeReplicasSortOrderEnum{ + "ASC": ListBootVolumeReplicasSortOrderAsc, + "DESC": ListBootVolumeReplicasSortOrderDesc, +} + +// GetListBootVolumeReplicasSortOrderEnumValues Enumerates the set of values for ListBootVolumeReplicasSortOrderEnum +func GetListBootVolumeReplicasSortOrderEnumValues() []ListBootVolumeReplicasSortOrderEnum { + values := make([]ListBootVolumeReplicasSortOrderEnum, 0) + for _, v := range mappingListBootVolumeReplicasSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volumes_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volumes_request_response.go new file mode 100644 index 000000000..6c0007c98 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_boot_volumes_request_response.go @@ -0,0 +1,97 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListBootVolumesRequest wrapper for the ListBootVolumes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListBootVolumes.go.html to see an example of how to use ListBootVolumesRequest. +type ListBootVolumesRequest struct { + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" contributesTo:"query" name:"availabilityDomain"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The OCID of the volume group. + VolumeGroupId *string `mandatory:"false" contributesTo:"query" name:"volumeGroupId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListBootVolumesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListBootVolumesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListBootVolumesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListBootVolumesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListBootVolumesResponse wrapper for the ListBootVolumes operation +type ListBootVolumesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []BootVolume instances + Items []BootVolume `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListBootVolumesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListBootVolumesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_byoip_allocated_ranges_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_byoip_allocated_ranges_request_response.go new file mode 100644 index 000000000..02a91b865 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_byoip_allocated_ranges_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListByoipAllocatedRangesRequest wrapper for the ListByoipAllocatedRanges operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListByoipAllocatedRanges.go.html to see an example of how to use ListByoipAllocatedRangesRequest. +type ListByoipAllocatedRangesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the `ByoipRange` resource containing the BYOIP CIDR block. + ByoipRangeId *string `mandatory:"true" contributesTo:"path" name:"byoipRangeId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListByoipAllocatedRangesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListByoipAllocatedRangesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListByoipAllocatedRangesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListByoipAllocatedRangesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListByoipAllocatedRangesResponse wrapper for the ListByoipAllocatedRanges operation +type ListByoipAllocatedRangesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of ByoipAllocatedRangeCollection instances + ByoipAllocatedRangeCollection `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListByoipAllocatedRangesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListByoipAllocatedRangesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_byoip_ranges_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_byoip_ranges_request_response.go new file mode 100644 index 000000000..d41dba621 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_byoip_ranges_request_response.go @@ -0,0 +1,155 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListByoipRangesRequest wrapper for the ListByoipRanges operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListByoipRanges.go.html to see an example of how to use ListByoipRangesRequest. +type ListByoipRangesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // A filter to return only resources that match the given lifecycle state name exactly. + LifecycleState *string `mandatory:"false" contributesTo:"query" name:"lifecycleState"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListByoipRangesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListByoipRangesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListByoipRangesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListByoipRangesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListByoipRangesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListByoipRangesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListByoipRangesResponse wrapper for the ListByoipRanges operation +type ListByoipRangesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of ByoipRangeCollection instances + ByoipRangeCollection `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListByoipRangesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListByoipRangesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListByoipRangesSortByEnum Enum with underlying type: string +type ListByoipRangesSortByEnum string + +// Set of constants representing the allowable values for ListByoipRangesSortByEnum +const ( + ListByoipRangesSortByTimecreated ListByoipRangesSortByEnum = "TIMECREATED" + ListByoipRangesSortByDisplayname ListByoipRangesSortByEnum = "DISPLAYNAME" +) + +var mappingListByoipRangesSortBy = map[string]ListByoipRangesSortByEnum{ + "TIMECREATED": ListByoipRangesSortByTimecreated, + "DISPLAYNAME": ListByoipRangesSortByDisplayname, +} + +// GetListByoipRangesSortByEnumValues Enumerates the set of values for ListByoipRangesSortByEnum +func GetListByoipRangesSortByEnumValues() []ListByoipRangesSortByEnum { + values := make([]ListByoipRangesSortByEnum, 0) + for _, v := range mappingListByoipRangesSortBy { + values = append(values, v) + } + return values +} + +// ListByoipRangesSortOrderEnum Enum with underlying type: string +type ListByoipRangesSortOrderEnum string + +// Set of constants representing the allowable values for ListByoipRangesSortOrderEnum +const ( + ListByoipRangesSortOrderAsc ListByoipRangesSortOrderEnum = "ASC" + ListByoipRangesSortOrderDesc ListByoipRangesSortOrderEnum = "DESC" +) + +var mappingListByoipRangesSortOrder = map[string]ListByoipRangesSortOrderEnum{ + "ASC": ListByoipRangesSortOrderAsc, + "DESC": ListByoipRangesSortOrderDesc, +} + +// GetListByoipRangesSortOrderEnumValues Enumerates the set of values for ListByoipRangesSortOrderEnum +func GetListByoipRangesSortOrderEnumValues() []ListByoipRangesSortOrderEnum { + values := make([]ListByoipRangesSortOrderEnum, 0) + for _, v := range mappingListByoipRangesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cluster_network_instances_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cluster_network_instances_request_response.go new file mode 100644 index 000000000..ea857a520 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cluster_network_instances_request_response.go @@ -0,0 +1,155 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListClusterNetworkInstancesRequest wrapper for the ListClusterNetworkInstances operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListClusterNetworkInstances.go.html to see an example of how to use ListClusterNetworkInstancesRequest. +type ListClusterNetworkInstancesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the cluster network. + ClusterNetworkId *string `mandatory:"true" contributesTo:"path" name:"clusterNetworkId"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListClusterNetworkInstancesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListClusterNetworkInstancesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListClusterNetworkInstancesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListClusterNetworkInstancesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListClusterNetworkInstancesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListClusterNetworkInstancesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListClusterNetworkInstancesResponse wrapper for the ListClusterNetworkInstances operation +type ListClusterNetworkInstancesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []InstanceSummary instances + Items []InstanceSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListClusterNetworkInstancesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListClusterNetworkInstancesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListClusterNetworkInstancesSortByEnum Enum with underlying type: string +type ListClusterNetworkInstancesSortByEnum string + +// Set of constants representing the allowable values for ListClusterNetworkInstancesSortByEnum +const ( + ListClusterNetworkInstancesSortByTimecreated ListClusterNetworkInstancesSortByEnum = "TIMECREATED" + ListClusterNetworkInstancesSortByDisplayname ListClusterNetworkInstancesSortByEnum = "DISPLAYNAME" +) + +var mappingListClusterNetworkInstancesSortBy = map[string]ListClusterNetworkInstancesSortByEnum{ + "TIMECREATED": ListClusterNetworkInstancesSortByTimecreated, + "DISPLAYNAME": ListClusterNetworkInstancesSortByDisplayname, +} + +// GetListClusterNetworkInstancesSortByEnumValues Enumerates the set of values for ListClusterNetworkInstancesSortByEnum +func GetListClusterNetworkInstancesSortByEnumValues() []ListClusterNetworkInstancesSortByEnum { + values := make([]ListClusterNetworkInstancesSortByEnum, 0) + for _, v := range mappingListClusterNetworkInstancesSortBy { + values = append(values, v) + } + return values +} + +// ListClusterNetworkInstancesSortOrderEnum Enum with underlying type: string +type ListClusterNetworkInstancesSortOrderEnum string + +// Set of constants representing the allowable values for ListClusterNetworkInstancesSortOrderEnum +const ( + ListClusterNetworkInstancesSortOrderAsc ListClusterNetworkInstancesSortOrderEnum = "ASC" + ListClusterNetworkInstancesSortOrderDesc ListClusterNetworkInstancesSortOrderEnum = "DESC" +) + +var mappingListClusterNetworkInstancesSortOrder = map[string]ListClusterNetworkInstancesSortOrderEnum{ + "ASC": ListClusterNetworkInstancesSortOrderAsc, + "DESC": ListClusterNetworkInstancesSortOrderDesc, +} + +// GetListClusterNetworkInstancesSortOrderEnumValues Enumerates the set of values for ListClusterNetworkInstancesSortOrderEnum +func GetListClusterNetworkInstancesSortOrderEnumValues() []ListClusterNetworkInstancesSortOrderEnum { + values := make([]ListClusterNetworkInstancesSortOrderEnum, 0) + for _, v := range mappingListClusterNetworkInstancesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cluster_networks_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cluster_networks_request_response.go new file mode 100644 index 000000000..29a67b14d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cluster_networks_request_response.go @@ -0,0 +1,156 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListClusterNetworksRequest wrapper for the ListClusterNetworks operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListClusterNetworks.go.html to see an example of how to use ListClusterNetworksRequest. +type ListClusterNetworksRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListClusterNetworksSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListClusterNetworksSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle + // state. The state value is case-insensitive. + LifecycleState ClusterNetworkSummaryLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListClusterNetworksRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListClusterNetworksRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListClusterNetworksRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListClusterNetworksRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListClusterNetworksResponse wrapper for the ListClusterNetworks operation +type ListClusterNetworksResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []ClusterNetworkSummary instances + Items []ClusterNetworkSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListClusterNetworksResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListClusterNetworksResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListClusterNetworksSortByEnum Enum with underlying type: string +type ListClusterNetworksSortByEnum string + +// Set of constants representing the allowable values for ListClusterNetworksSortByEnum +const ( + ListClusterNetworksSortByTimecreated ListClusterNetworksSortByEnum = "TIMECREATED" + ListClusterNetworksSortByDisplayname ListClusterNetworksSortByEnum = "DISPLAYNAME" +) + +var mappingListClusterNetworksSortBy = map[string]ListClusterNetworksSortByEnum{ + "TIMECREATED": ListClusterNetworksSortByTimecreated, + "DISPLAYNAME": ListClusterNetworksSortByDisplayname, +} + +// GetListClusterNetworksSortByEnumValues Enumerates the set of values for ListClusterNetworksSortByEnum +func GetListClusterNetworksSortByEnumValues() []ListClusterNetworksSortByEnum { + values := make([]ListClusterNetworksSortByEnum, 0) + for _, v := range mappingListClusterNetworksSortBy { + values = append(values, v) + } + return values +} + +// ListClusterNetworksSortOrderEnum Enum with underlying type: string +type ListClusterNetworksSortOrderEnum string + +// Set of constants representing the allowable values for ListClusterNetworksSortOrderEnum +const ( + ListClusterNetworksSortOrderAsc ListClusterNetworksSortOrderEnum = "ASC" + ListClusterNetworksSortOrderDesc ListClusterNetworksSortOrderEnum = "DESC" +) + +var mappingListClusterNetworksSortOrder = map[string]ListClusterNetworksSortOrderEnum{ + "ASC": ListClusterNetworksSortOrderAsc, + "DESC": ListClusterNetworksSortOrderDesc, +} + +// GetListClusterNetworksSortOrderEnumValues Enumerates the set of values for ListClusterNetworksSortOrderEnum +func GetListClusterNetworksSortOrderEnumValues() []ListClusterNetworksSortOrderEnum { + values := make([]ListClusterNetworksSortOrderEnum, 0) + for _, v := range mappingListClusterNetworksSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_capacity_reservation_instance_shapes_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_capacity_reservation_instance_shapes_request_response.go new file mode 100644 index 000000000..1e6e0fc3d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_capacity_reservation_instance_shapes_request_response.go @@ -0,0 +1,156 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListComputeCapacityReservationInstanceShapesRequest wrapper for the ListComputeCapacityReservationInstanceShapes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListComputeCapacityReservationInstanceShapes.go.html to see an example of how to use ListComputeCapacityReservationInstanceShapesRequest. +type ListComputeCapacityReservationInstanceShapesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" contributesTo:"query" name:"availabilityDomain"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListComputeCapacityReservationInstanceShapesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListComputeCapacityReservationInstanceShapesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListComputeCapacityReservationInstanceShapesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListComputeCapacityReservationInstanceShapesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListComputeCapacityReservationInstanceShapesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListComputeCapacityReservationInstanceShapesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListComputeCapacityReservationInstanceShapesResponse wrapper for the ListComputeCapacityReservationInstanceShapes operation +type ListComputeCapacityReservationInstanceShapesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []ComputeCapacityReservationInstanceShapeSummary instances + Items []ComputeCapacityReservationInstanceShapeSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListComputeCapacityReservationInstanceShapesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListComputeCapacityReservationInstanceShapesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListComputeCapacityReservationInstanceShapesSortByEnum Enum with underlying type: string +type ListComputeCapacityReservationInstanceShapesSortByEnum string + +// Set of constants representing the allowable values for ListComputeCapacityReservationInstanceShapesSortByEnum +const ( + ListComputeCapacityReservationInstanceShapesSortByTimecreated ListComputeCapacityReservationInstanceShapesSortByEnum = "TIMECREATED" + ListComputeCapacityReservationInstanceShapesSortByDisplayname ListComputeCapacityReservationInstanceShapesSortByEnum = "DISPLAYNAME" +) + +var mappingListComputeCapacityReservationInstanceShapesSortBy = map[string]ListComputeCapacityReservationInstanceShapesSortByEnum{ + "TIMECREATED": ListComputeCapacityReservationInstanceShapesSortByTimecreated, + "DISPLAYNAME": ListComputeCapacityReservationInstanceShapesSortByDisplayname, +} + +// GetListComputeCapacityReservationInstanceShapesSortByEnumValues Enumerates the set of values for ListComputeCapacityReservationInstanceShapesSortByEnum +func GetListComputeCapacityReservationInstanceShapesSortByEnumValues() []ListComputeCapacityReservationInstanceShapesSortByEnum { + values := make([]ListComputeCapacityReservationInstanceShapesSortByEnum, 0) + for _, v := range mappingListComputeCapacityReservationInstanceShapesSortBy { + values = append(values, v) + } + return values +} + +// ListComputeCapacityReservationInstanceShapesSortOrderEnum Enum with underlying type: string +type ListComputeCapacityReservationInstanceShapesSortOrderEnum string + +// Set of constants representing the allowable values for ListComputeCapacityReservationInstanceShapesSortOrderEnum +const ( + ListComputeCapacityReservationInstanceShapesSortOrderAsc ListComputeCapacityReservationInstanceShapesSortOrderEnum = "ASC" + ListComputeCapacityReservationInstanceShapesSortOrderDesc ListComputeCapacityReservationInstanceShapesSortOrderEnum = "DESC" +) + +var mappingListComputeCapacityReservationInstanceShapesSortOrder = map[string]ListComputeCapacityReservationInstanceShapesSortOrderEnum{ + "ASC": ListComputeCapacityReservationInstanceShapesSortOrderAsc, + "DESC": ListComputeCapacityReservationInstanceShapesSortOrderDesc, +} + +// GetListComputeCapacityReservationInstanceShapesSortOrderEnumValues Enumerates the set of values for ListComputeCapacityReservationInstanceShapesSortOrderEnum +func GetListComputeCapacityReservationInstanceShapesSortOrderEnumValues() []ListComputeCapacityReservationInstanceShapesSortOrderEnum { + values := make([]ListComputeCapacityReservationInstanceShapesSortOrderEnum, 0) + for _, v := range mappingListComputeCapacityReservationInstanceShapesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_capacity_reservation_instances_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_capacity_reservation_instances_request_response.go new file mode 100644 index 000000000..0c29fe6ae --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_capacity_reservation_instances_request_response.go @@ -0,0 +1,156 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListComputeCapacityReservationInstancesRequest wrapper for the ListComputeCapacityReservationInstances operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListComputeCapacityReservationInstances.go.html to see an example of how to use ListComputeCapacityReservationInstancesRequest. +type ListComputeCapacityReservationInstancesRequest struct { + + // The OCID of the compute capacity reservation. + CapacityReservationId *string `mandatory:"true" contributesTo:"path" name:"capacityReservationId"` + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" contributesTo:"query" name:"availabilityDomain"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"false" contributesTo:"query" name:"compartmentId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListComputeCapacityReservationInstancesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListComputeCapacityReservationInstancesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListComputeCapacityReservationInstancesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListComputeCapacityReservationInstancesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListComputeCapacityReservationInstancesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListComputeCapacityReservationInstancesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListComputeCapacityReservationInstancesResponse wrapper for the ListComputeCapacityReservationInstances operation +type ListComputeCapacityReservationInstancesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []CapacityReservationInstanceSummary instances + Items []CapacityReservationInstanceSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListComputeCapacityReservationInstancesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListComputeCapacityReservationInstancesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListComputeCapacityReservationInstancesSortByEnum Enum with underlying type: string +type ListComputeCapacityReservationInstancesSortByEnum string + +// Set of constants representing the allowable values for ListComputeCapacityReservationInstancesSortByEnum +const ( + ListComputeCapacityReservationInstancesSortByTimecreated ListComputeCapacityReservationInstancesSortByEnum = "TIMECREATED" + ListComputeCapacityReservationInstancesSortByDisplayname ListComputeCapacityReservationInstancesSortByEnum = "DISPLAYNAME" +) + +var mappingListComputeCapacityReservationInstancesSortBy = map[string]ListComputeCapacityReservationInstancesSortByEnum{ + "TIMECREATED": ListComputeCapacityReservationInstancesSortByTimecreated, + "DISPLAYNAME": ListComputeCapacityReservationInstancesSortByDisplayname, +} + +// GetListComputeCapacityReservationInstancesSortByEnumValues Enumerates the set of values for ListComputeCapacityReservationInstancesSortByEnum +func GetListComputeCapacityReservationInstancesSortByEnumValues() []ListComputeCapacityReservationInstancesSortByEnum { + values := make([]ListComputeCapacityReservationInstancesSortByEnum, 0) + for _, v := range mappingListComputeCapacityReservationInstancesSortBy { + values = append(values, v) + } + return values +} + +// ListComputeCapacityReservationInstancesSortOrderEnum Enum with underlying type: string +type ListComputeCapacityReservationInstancesSortOrderEnum string + +// Set of constants representing the allowable values for ListComputeCapacityReservationInstancesSortOrderEnum +const ( + ListComputeCapacityReservationInstancesSortOrderAsc ListComputeCapacityReservationInstancesSortOrderEnum = "ASC" + ListComputeCapacityReservationInstancesSortOrderDesc ListComputeCapacityReservationInstancesSortOrderEnum = "DESC" +) + +var mappingListComputeCapacityReservationInstancesSortOrder = map[string]ListComputeCapacityReservationInstancesSortOrderEnum{ + "ASC": ListComputeCapacityReservationInstancesSortOrderAsc, + "DESC": ListComputeCapacityReservationInstancesSortOrderDesc, +} + +// GetListComputeCapacityReservationInstancesSortOrderEnumValues Enumerates the set of values for ListComputeCapacityReservationInstancesSortOrderEnum +func GetListComputeCapacityReservationInstancesSortOrderEnumValues() []ListComputeCapacityReservationInstancesSortOrderEnum { + values := make([]ListComputeCapacityReservationInstancesSortOrderEnum, 0) + for _, v := range mappingListComputeCapacityReservationInstancesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_capacity_reservations_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_capacity_reservations_request_response.go new file mode 100644 index 000000000..6038664ad --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_capacity_reservations_request_response.go @@ -0,0 +1,159 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListComputeCapacityReservationsRequest wrapper for the ListComputeCapacityReservations operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListComputeCapacityReservations.go.html to see an example of how to use ListComputeCapacityReservationsRequest. +type ListComputeCapacityReservationsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" contributesTo:"query" name:"availabilityDomain"` + + // A filter to only return resources that match the given lifecycle state. + LifecycleState ComputeCapacityReservationLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListComputeCapacityReservationsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListComputeCapacityReservationsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListComputeCapacityReservationsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListComputeCapacityReservationsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListComputeCapacityReservationsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListComputeCapacityReservationsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListComputeCapacityReservationsResponse wrapper for the ListComputeCapacityReservations operation +type ListComputeCapacityReservationsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []ComputeCapacityReservationSummary instances + Items []ComputeCapacityReservationSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListComputeCapacityReservationsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListComputeCapacityReservationsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListComputeCapacityReservationsSortByEnum Enum with underlying type: string +type ListComputeCapacityReservationsSortByEnum string + +// Set of constants representing the allowable values for ListComputeCapacityReservationsSortByEnum +const ( + ListComputeCapacityReservationsSortByTimecreated ListComputeCapacityReservationsSortByEnum = "TIMECREATED" + ListComputeCapacityReservationsSortByDisplayname ListComputeCapacityReservationsSortByEnum = "DISPLAYNAME" +) + +var mappingListComputeCapacityReservationsSortBy = map[string]ListComputeCapacityReservationsSortByEnum{ + "TIMECREATED": ListComputeCapacityReservationsSortByTimecreated, + "DISPLAYNAME": ListComputeCapacityReservationsSortByDisplayname, +} + +// GetListComputeCapacityReservationsSortByEnumValues Enumerates the set of values for ListComputeCapacityReservationsSortByEnum +func GetListComputeCapacityReservationsSortByEnumValues() []ListComputeCapacityReservationsSortByEnum { + values := make([]ListComputeCapacityReservationsSortByEnum, 0) + for _, v := range mappingListComputeCapacityReservationsSortBy { + values = append(values, v) + } + return values +} + +// ListComputeCapacityReservationsSortOrderEnum Enum with underlying type: string +type ListComputeCapacityReservationsSortOrderEnum string + +// Set of constants representing the allowable values for ListComputeCapacityReservationsSortOrderEnum +const ( + ListComputeCapacityReservationsSortOrderAsc ListComputeCapacityReservationsSortOrderEnum = "ASC" + ListComputeCapacityReservationsSortOrderDesc ListComputeCapacityReservationsSortOrderEnum = "DESC" +) + +var mappingListComputeCapacityReservationsSortOrder = map[string]ListComputeCapacityReservationsSortOrderEnum{ + "ASC": ListComputeCapacityReservationsSortOrderAsc, + "DESC": ListComputeCapacityReservationsSortOrderDesc, +} + +// GetListComputeCapacityReservationsSortOrderEnumValues Enumerates the set of values for ListComputeCapacityReservationsSortOrderEnum +func GetListComputeCapacityReservationsSortOrderEnumValues() []ListComputeCapacityReservationsSortOrderEnum { + values := make([]ListComputeCapacityReservationsSortOrderEnum, 0) + for _, v := range mappingListComputeCapacityReservationsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_global_image_capability_schema_versions_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_global_image_capability_schema_versions_request_response.go new file mode 100644 index 000000000..c82ba73b4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_global_image_capability_schema_versions_request_response.go @@ -0,0 +1,152 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListComputeGlobalImageCapabilitySchemaVersionsRequest wrapper for the ListComputeGlobalImageCapabilitySchemaVersions operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListComputeGlobalImageCapabilitySchemaVersions.go.html to see an example of how to use ListComputeGlobalImageCapabilitySchemaVersionsRequest. +type ListComputeGlobalImageCapabilitySchemaVersionsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compute global image capability schema + ComputeGlobalImageCapabilitySchemaId *string `mandatory:"true" contributesTo:"path" name:"computeGlobalImageCapabilitySchemaId"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListComputeGlobalImageCapabilitySchemaVersionsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListComputeGlobalImageCapabilitySchemaVersionsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListComputeGlobalImageCapabilitySchemaVersionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListComputeGlobalImageCapabilitySchemaVersionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListComputeGlobalImageCapabilitySchemaVersionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListComputeGlobalImageCapabilitySchemaVersionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListComputeGlobalImageCapabilitySchemaVersionsResponse wrapper for the ListComputeGlobalImageCapabilitySchemaVersions operation +type ListComputeGlobalImageCapabilitySchemaVersionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []ComputeGlobalImageCapabilitySchemaVersionSummary instances + Items []ComputeGlobalImageCapabilitySchemaVersionSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListComputeGlobalImageCapabilitySchemaVersionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListComputeGlobalImageCapabilitySchemaVersionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListComputeGlobalImageCapabilitySchemaVersionsSortByEnum Enum with underlying type: string +type ListComputeGlobalImageCapabilitySchemaVersionsSortByEnum string + +// Set of constants representing the allowable values for ListComputeGlobalImageCapabilitySchemaVersionsSortByEnum +const ( + ListComputeGlobalImageCapabilitySchemaVersionsSortByTimecreated ListComputeGlobalImageCapabilitySchemaVersionsSortByEnum = "TIMECREATED" + ListComputeGlobalImageCapabilitySchemaVersionsSortByDisplayname ListComputeGlobalImageCapabilitySchemaVersionsSortByEnum = "DISPLAYNAME" +) + +var mappingListComputeGlobalImageCapabilitySchemaVersionsSortBy = map[string]ListComputeGlobalImageCapabilitySchemaVersionsSortByEnum{ + "TIMECREATED": ListComputeGlobalImageCapabilitySchemaVersionsSortByTimecreated, + "DISPLAYNAME": ListComputeGlobalImageCapabilitySchemaVersionsSortByDisplayname, +} + +// GetListComputeGlobalImageCapabilitySchemaVersionsSortByEnumValues Enumerates the set of values for ListComputeGlobalImageCapabilitySchemaVersionsSortByEnum +func GetListComputeGlobalImageCapabilitySchemaVersionsSortByEnumValues() []ListComputeGlobalImageCapabilitySchemaVersionsSortByEnum { + values := make([]ListComputeGlobalImageCapabilitySchemaVersionsSortByEnum, 0) + for _, v := range mappingListComputeGlobalImageCapabilitySchemaVersionsSortBy { + values = append(values, v) + } + return values +} + +// ListComputeGlobalImageCapabilitySchemaVersionsSortOrderEnum Enum with underlying type: string +type ListComputeGlobalImageCapabilitySchemaVersionsSortOrderEnum string + +// Set of constants representing the allowable values for ListComputeGlobalImageCapabilitySchemaVersionsSortOrderEnum +const ( + ListComputeGlobalImageCapabilitySchemaVersionsSortOrderAsc ListComputeGlobalImageCapabilitySchemaVersionsSortOrderEnum = "ASC" + ListComputeGlobalImageCapabilitySchemaVersionsSortOrderDesc ListComputeGlobalImageCapabilitySchemaVersionsSortOrderEnum = "DESC" +) + +var mappingListComputeGlobalImageCapabilitySchemaVersionsSortOrder = map[string]ListComputeGlobalImageCapabilitySchemaVersionsSortOrderEnum{ + "ASC": ListComputeGlobalImageCapabilitySchemaVersionsSortOrderAsc, + "DESC": ListComputeGlobalImageCapabilitySchemaVersionsSortOrderDesc, +} + +// GetListComputeGlobalImageCapabilitySchemaVersionsSortOrderEnumValues Enumerates the set of values for ListComputeGlobalImageCapabilitySchemaVersionsSortOrderEnum +func GetListComputeGlobalImageCapabilitySchemaVersionsSortOrderEnumValues() []ListComputeGlobalImageCapabilitySchemaVersionsSortOrderEnum { + values := make([]ListComputeGlobalImageCapabilitySchemaVersionsSortOrderEnum, 0) + for _, v := range mappingListComputeGlobalImageCapabilitySchemaVersionsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_global_image_capability_schemas_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_global_image_capability_schemas_request_response.go new file mode 100644 index 000000000..9b59fd983 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_global_image_capability_schemas_request_response.go @@ -0,0 +1,152 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListComputeGlobalImageCapabilitySchemasRequest wrapper for the ListComputeGlobalImageCapabilitySchemas operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListComputeGlobalImageCapabilitySchemas.go.html to see an example of how to use ListComputeGlobalImageCapabilitySchemasRequest. +type ListComputeGlobalImageCapabilitySchemasRequest struct { + + // A filter to return only resources that match the given compartment OCID exactly. + CompartmentId *string `mandatory:"false" contributesTo:"query" name:"compartmentId"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListComputeGlobalImageCapabilitySchemasSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListComputeGlobalImageCapabilitySchemasSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListComputeGlobalImageCapabilitySchemasRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListComputeGlobalImageCapabilitySchemasRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListComputeGlobalImageCapabilitySchemasRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListComputeGlobalImageCapabilitySchemasRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListComputeGlobalImageCapabilitySchemasResponse wrapper for the ListComputeGlobalImageCapabilitySchemas operation +type ListComputeGlobalImageCapabilitySchemasResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []ComputeGlobalImageCapabilitySchemaSummary instances + Items []ComputeGlobalImageCapabilitySchemaSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListComputeGlobalImageCapabilitySchemasResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListComputeGlobalImageCapabilitySchemasResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListComputeGlobalImageCapabilitySchemasSortByEnum Enum with underlying type: string +type ListComputeGlobalImageCapabilitySchemasSortByEnum string + +// Set of constants representing the allowable values for ListComputeGlobalImageCapabilitySchemasSortByEnum +const ( + ListComputeGlobalImageCapabilitySchemasSortByTimecreated ListComputeGlobalImageCapabilitySchemasSortByEnum = "TIMECREATED" + ListComputeGlobalImageCapabilitySchemasSortByDisplayname ListComputeGlobalImageCapabilitySchemasSortByEnum = "DISPLAYNAME" +) + +var mappingListComputeGlobalImageCapabilitySchemasSortBy = map[string]ListComputeGlobalImageCapabilitySchemasSortByEnum{ + "TIMECREATED": ListComputeGlobalImageCapabilitySchemasSortByTimecreated, + "DISPLAYNAME": ListComputeGlobalImageCapabilitySchemasSortByDisplayname, +} + +// GetListComputeGlobalImageCapabilitySchemasSortByEnumValues Enumerates the set of values for ListComputeGlobalImageCapabilitySchemasSortByEnum +func GetListComputeGlobalImageCapabilitySchemasSortByEnumValues() []ListComputeGlobalImageCapabilitySchemasSortByEnum { + values := make([]ListComputeGlobalImageCapabilitySchemasSortByEnum, 0) + for _, v := range mappingListComputeGlobalImageCapabilitySchemasSortBy { + values = append(values, v) + } + return values +} + +// ListComputeGlobalImageCapabilitySchemasSortOrderEnum Enum with underlying type: string +type ListComputeGlobalImageCapabilitySchemasSortOrderEnum string + +// Set of constants representing the allowable values for ListComputeGlobalImageCapabilitySchemasSortOrderEnum +const ( + ListComputeGlobalImageCapabilitySchemasSortOrderAsc ListComputeGlobalImageCapabilitySchemasSortOrderEnum = "ASC" + ListComputeGlobalImageCapabilitySchemasSortOrderDesc ListComputeGlobalImageCapabilitySchemasSortOrderEnum = "DESC" +) + +var mappingListComputeGlobalImageCapabilitySchemasSortOrder = map[string]ListComputeGlobalImageCapabilitySchemasSortOrderEnum{ + "ASC": ListComputeGlobalImageCapabilitySchemasSortOrderAsc, + "DESC": ListComputeGlobalImageCapabilitySchemasSortOrderDesc, +} + +// GetListComputeGlobalImageCapabilitySchemasSortOrderEnumValues Enumerates the set of values for ListComputeGlobalImageCapabilitySchemasSortOrderEnum +func GetListComputeGlobalImageCapabilitySchemasSortOrderEnumValues() []ListComputeGlobalImageCapabilitySchemasSortOrderEnum { + values := make([]ListComputeGlobalImageCapabilitySchemasSortOrderEnum, 0) + for _, v := range mappingListComputeGlobalImageCapabilitySchemasSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_image_capability_schemas_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_image_capability_schemas_request_response.go new file mode 100644 index 000000000..bbae9b0a1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_compute_image_capability_schemas_request_response.go @@ -0,0 +1,155 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListComputeImageCapabilitySchemasRequest wrapper for the ListComputeImageCapabilitySchemas operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListComputeImageCapabilitySchemas.go.html to see an example of how to use ListComputeImageCapabilitySchemasRequest. +type ListComputeImageCapabilitySchemasRequest struct { + + // A filter to return only resources that match the given compartment OCID exactly. + CompartmentId *string `mandatory:"false" contributesTo:"query" name:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of an image. + ImageId *string `mandatory:"false" contributesTo:"query" name:"imageId"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListComputeImageCapabilitySchemasSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListComputeImageCapabilitySchemasSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListComputeImageCapabilitySchemasRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListComputeImageCapabilitySchemasRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListComputeImageCapabilitySchemasRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListComputeImageCapabilitySchemasRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListComputeImageCapabilitySchemasResponse wrapper for the ListComputeImageCapabilitySchemas operation +type ListComputeImageCapabilitySchemasResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []ComputeImageCapabilitySchemaSummary instances + Items []ComputeImageCapabilitySchemaSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListComputeImageCapabilitySchemasResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListComputeImageCapabilitySchemasResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListComputeImageCapabilitySchemasSortByEnum Enum with underlying type: string +type ListComputeImageCapabilitySchemasSortByEnum string + +// Set of constants representing the allowable values for ListComputeImageCapabilitySchemasSortByEnum +const ( + ListComputeImageCapabilitySchemasSortByTimecreated ListComputeImageCapabilitySchemasSortByEnum = "TIMECREATED" + ListComputeImageCapabilitySchemasSortByDisplayname ListComputeImageCapabilitySchemasSortByEnum = "DISPLAYNAME" +) + +var mappingListComputeImageCapabilitySchemasSortBy = map[string]ListComputeImageCapabilitySchemasSortByEnum{ + "TIMECREATED": ListComputeImageCapabilitySchemasSortByTimecreated, + "DISPLAYNAME": ListComputeImageCapabilitySchemasSortByDisplayname, +} + +// GetListComputeImageCapabilitySchemasSortByEnumValues Enumerates the set of values for ListComputeImageCapabilitySchemasSortByEnum +func GetListComputeImageCapabilitySchemasSortByEnumValues() []ListComputeImageCapabilitySchemasSortByEnum { + values := make([]ListComputeImageCapabilitySchemasSortByEnum, 0) + for _, v := range mappingListComputeImageCapabilitySchemasSortBy { + values = append(values, v) + } + return values +} + +// ListComputeImageCapabilitySchemasSortOrderEnum Enum with underlying type: string +type ListComputeImageCapabilitySchemasSortOrderEnum string + +// Set of constants representing the allowable values for ListComputeImageCapabilitySchemasSortOrderEnum +const ( + ListComputeImageCapabilitySchemasSortOrderAsc ListComputeImageCapabilitySchemasSortOrderEnum = "ASC" + ListComputeImageCapabilitySchemasSortOrderDesc ListComputeImageCapabilitySchemasSortOrderEnum = "DESC" +) + +var mappingListComputeImageCapabilitySchemasSortOrder = map[string]ListComputeImageCapabilitySchemasSortOrderEnum{ + "ASC": ListComputeImageCapabilitySchemasSortOrderAsc, + "DESC": ListComputeImageCapabilitySchemasSortOrderDesc, +} + +// GetListComputeImageCapabilitySchemasSortOrderEnumValues Enumerates the set of values for ListComputeImageCapabilitySchemasSortOrderEnum +func GetListComputeImageCapabilitySchemasSortOrderEnumValues() []ListComputeImageCapabilitySchemasSortOrderEnum { + values := make([]ListComputeImageCapabilitySchemasSortOrderEnum, 0) + for _, v := range mappingListComputeImageCapabilitySchemasSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_console_histories_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_console_histories_request_response.go new file mode 100644 index 000000000..2062efbbe --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_console_histories_request_response.go @@ -0,0 +1,160 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListConsoleHistoriesRequest wrapper for the ListConsoleHistories operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListConsoleHistories.go.html to see an example of how to use ListConsoleHistoriesRequest. +type ListConsoleHistoriesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" contributesTo:"query" name:"availabilityDomain"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The OCID of the instance. + InstanceId *string `mandatory:"false" contributesTo:"query" name:"instanceId"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListConsoleHistoriesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListConsoleHistoriesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state + // value is case-insensitive. + LifecycleState ConsoleHistoryLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListConsoleHistoriesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListConsoleHistoriesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListConsoleHistoriesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListConsoleHistoriesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListConsoleHistoriesResponse wrapper for the ListConsoleHistories operation +type ListConsoleHistoriesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []ConsoleHistory instances + Items []ConsoleHistory `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListConsoleHistoriesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListConsoleHistoriesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListConsoleHistoriesSortByEnum Enum with underlying type: string +type ListConsoleHistoriesSortByEnum string + +// Set of constants representing the allowable values for ListConsoleHistoriesSortByEnum +const ( + ListConsoleHistoriesSortByTimecreated ListConsoleHistoriesSortByEnum = "TIMECREATED" + ListConsoleHistoriesSortByDisplayname ListConsoleHistoriesSortByEnum = "DISPLAYNAME" +) + +var mappingListConsoleHistoriesSortBy = map[string]ListConsoleHistoriesSortByEnum{ + "TIMECREATED": ListConsoleHistoriesSortByTimecreated, + "DISPLAYNAME": ListConsoleHistoriesSortByDisplayname, +} + +// GetListConsoleHistoriesSortByEnumValues Enumerates the set of values for ListConsoleHistoriesSortByEnum +func GetListConsoleHistoriesSortByEnumValues() []ListConsoleHistoriesSortByEnum { + values := make([]ListConsoleHistoriesSortByEnum, 0) + for _, v := range mappingListConsoleHistoriesSortBy { + values = append(values, v) + } + return values +} + +// ListConsoleHistoriesSortOrderEnum Enum with underlying type: string +type ListConsoleHistoriesSortOrderEnum string + +// Set of constants representing the allowable values for ListConsoleHistoriesSortOrderEnum +const ( + ListConsoleHistoriesSortOrderAsc ListConsoleHistoriesSortOrderEnum = "ASC" + ListConsoleHistoriesSortOrderDesc ListConsoleHistoriesSortOrderEnum = "DESC" +) + +var mappingListConsoleHistoriesSortOrder = map[string]ListConsoleHistoriesSortOrderEnum{ + "ASC": ListConsoleHistoriesSortOrderAsc, + "DESC": ListConsoleHistoriesSortOrderDesc, +} + +// GetListConsoleHistoriesSortOrderEnumValues Enumerates the set of values for ListConsoleHistoriesSortOrderEnum +func GetListConsoleHistoriesSortOrderEnumValues() []ListConsoleHistoriesSortOrderEnum { + values := make([]ListConsoleHistoriesSortOrderEnum, 0) + for _, v := range mappingListConsoleHistoriesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cpe_device_shapes_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cpe_device_shapes_request_response.go new file mode 100644 index 000000000..60c217b81 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cpe_device_shapes_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListCpeDeviceShapesRequest wrapper for the ListCpeDeviceShapes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListCpeDeviceShapes.go.html to see an example of how to use ListCpeDeviceShapesRequest. +type ListCpeDeviceShapesRequest struct { + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListCpeDeviceShapesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListCpeDeviceShapesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListCpeDeviceShapesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListCpeDeviceShapesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListCpeDeviceShapesResponse wrapper for the ListCpeDeviceShapes operation +type ListCpeDeviceShapesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []CpeDeviceShapeSummary instances + Items []CpeDeviceShapeSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListCpeDeviceShapesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListCpeDeviceShapesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cpes_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cpes_request_response.go new file mode 100644 index 000000000..6924bd187 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cpes_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListCpesRequest wrapper for the ListCpes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListCpes.go.html to see an example of how to use ListCpesRequest. +type ListCpesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListCpesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListCpesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListCpesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListCpesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListCpesResponse wrapper for the ListCpes operation +type ListCpesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Cpe instances + Items []Cpe `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListCpesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListCpesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connect_groups_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connect_groups_request_response.go new file mode 100644 index 000000000..72ef19bd5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connect_groups_request_response.go @@ -0,0 +1,156 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListCrossConnectGroupsRequest wrapper for the ListCrossConnectGroups operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListCrossConnectGroups.go.html to see an example of how to use ListCrossConnectGroupsRequest. +type ListCrossConnectGroupsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListCrossConnectGroupsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListCrossConnectGroupsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to return only resources that match the specified lifecycle + // state. The value is case insensitive. + LifecycleState CrossConnectGroupLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListCrossConnectGroupsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListCrossConnectGroupsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListCrossConnectGroupsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListCrossConnectGroupsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListCrossConnectGroupsResponse wrapper for the ListCrossConnectGroups operation +type ListCrossConnectGroupsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []CrossConnectGroup instances + Items []CrossConnectGroup `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListCrossConnectGroupsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListCrossConnectGroupsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListCrossConnectGroupsSortByEnum Enum with underlying type: string +type ListCrossConnectGroupsSortByEnum string + +// Set of constants representing the allowable values for ListCrossConnectGroupsSortByEnum +const ( + ListCrossConnectGroupsSortByTimecreated ListCrossConnectGroupsSortByEnum = "TIMECREATED" + ListCrossConnectGroupsSortByDisplayname ListCrossConnectGroupsSortByEnum = "DISPLAYNAME" +) + +var mappingListCrossConnectGroupsSortBy = map[string]ListCrossConnectGroupsSortByEnum{ + "TIMECREATED": ListCrossConnectGroupsSortByTimecreated, + "DISPLAYNAME": ListCrossConnectGroupsSortByDisplayname, +} + +// GetListCrossConnectGroupsSortByEnumValues Enumerates the set of values for ListCrossConnectGroupsSortByEnum +func GetListCrossConnectGroupsSortByEnumValues() []ListCrossConnectGroupsSortByEnum { + values := make([]ListCrossConnectGroupsSortByEnum, 0) + for _, v := range mappingListCrossConnectGroupsSortBy { + values = append(values, v) + } + return values +} + +// ListCrossConnectGroupsSortOrderEnum Enum with underlying type: string +type ListCrossConnectGroupsSortOrderEnum string + +// Set of constants representing the allowable values for ListCrossConnectGroupsSortOrderEnum +const ( + ListCrossConnectGroupsSortOrderAsc ListCrossConnectGroupsSortOrderEnum = "ASC" + ListCrossConnectGroupsSortOrderDesc ListCrossConnectGroupsSortOrderEnum = "DESC" +) + +var mappingListCrossConnectGroupsSortOrder = map[string]ListCrossConnectGroupsSortOrderEnum{ + "ASC": ListCrossConnectGroupsSortOrderAsc, + "DESC": ListCrossConnectGroupsSortOrderDesc, +} + +// GetListCrossConnectGroupsSortOrderEnumValues Enumerates the set of values for ListCrossConnectGroupsSortOrderEnum +func GetListCrossConnectGroupsSortOrderEnumValues() []ListCrossConnectGroupsSortOrderEnum { + values := make([]ListCrossConnectGroupsSortOrderEnum, 0) + for _, v := range mappingListCrossConnectGroupsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connect_locations_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connect_locations_request_response.go new file mode 100644 index 000000000..ac923b2d4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connect_locations_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListCrossConnectLocationsRequest wrapper for the ListCrossConnectLocations operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListCrossConnectLocations.go.html to see an example of how to use ListCrossConnectLocationsRequest. +type ListCrossConnectLocationsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListCrossConnectLocationsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListCrossConnectLocationsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListCrossConnectLocationsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListCrossConnectLocationsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListCrossConnectLocationsResponse wrapper for the ListCrossConnectLocations operation +type ListCrossConnectLocationsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []CrossConnectLocation instances + Items []CrossConnectLocation `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListCrossConnectLocationsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListCrossConnectLocationsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connect_mappings_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connect_mappings_request_response.go new file mode 100644 index 000000000..29f19da17 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connect_mappings_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListCrossConnectMappingsRequest wrapper for the ListCrossConnectMappings operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListCrossConnectMappings.go.html to see an example of how to use ListCrossConnectMappingsRequest. +type ListCrossConnectMappingsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the virtual circuit. + VirtualCircuitId *string `mandatory:"true" contributesTo:"path" name:"virtualCircuitId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListCrossConnectMappingsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListCrossConnectMappingsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListCrossConnectMappingsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListCrossConnectMappingsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListCrossConnectMappingsResponse wrapper for the ListCrossConnectMappings operation +type ListCrossConnectMappingsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The CrossConnectMappingDetailsCollection instance + CrossConnectMappingDetailsCollection `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListCrossConnectMappingsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListCrossConnectMappingsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connects_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connects_request_response.go new file mode 100644 index 000000000..873592bca --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_cross_connects_request_response.go @@ -0,0 +1,159 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListCrossConnectsRequest wrapper for the ListCrossConnects operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListCrossConnects.go.html to see an example of how to use ListCrossConnectsRequest. +type ListCrossConnectsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the cross-connect group. + CrossConnectGroupId *string `mandatory:"false" contributesTo:"query" name:"crossConnectGroupId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListCrossConnectsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListCrossConnectsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to return only resources that match the specified lifecycle + // state. The value is case insensitive. + LifecycleState CrossConnectLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListCrossConnectsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListCrossConnectsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListCrossConnectsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListCrossConnectsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListCrossConnectsResponse wrapper for the ListCrossConnects operation +type ListCrossConnectsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []CrossConnect instances + Items []CrossConnect `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListCrossConnectsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListCrossConnectsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListCrossConnectsSortByEnum Enum with underlying type: string +type ListCrossConnectsSortByEnum string + +// Set of constants representing the allowable values for ListCrossConnectsSortByEnum +const ( + ListCrossConnectsSortByTimecreated ListCrossConnectsSortByEnum = "TIMECREATED" + ListCrossConnectsSortByDisplayname ListCrossConnectsSortByEnum = "DISPLAYNAME" +) + +var mappingListCrossConnectsSortBy = map[string]ListCrossConnectsSortByEnum{ + "TIMECREATED": ListCrossConnectsSortByTimecreated, + "DISPLAYNAME": ListCrossConnectsSortByDisplayname, +} + +// GetListCrossConnectsSortByEnumValues Enumerates the set of values for ListCrossConnectsSortByEnum +func GetListCrossConnectsSortByEnumValues() []ListCrossConnectsSortByEnum { + values := make([]ListCrossConnectsSortByEnum, 0) + for _, v := range mappingListCrossConnectsSortBy { + values = append(values, v) + } + return values +} + +// ListCrossConnectsSortOrderEnum Enum with underlying type: string +type ListCrossConnectsSortOrderEnum string + +// Set of constants representing the allowable values for ListCrossConnectsSortOrderEnum +const ( + ListCrossConnectsSortOrderAsc ListCrossConnectsSortOrderEnum = "ASC" + ListCrossConnectsSortOrderDesc ListCrossConnectsSortOrderEnum = "DESC" +) + +var mappingListCrossConnectsSortOrder = map[string]ListCrossConnectsSortOrderEnum{ + "ASC": ListCrossConnectsSortOrderAsc, + "DESC": ListCrossConnectsSortOrderDesc, +} + +// GetListCrossConnectsSortOrderEnumValues Enumerates the set of values for ListCrossConnectsSortOrderEnum +func GetListCrossConnectsSortOrderEnumValues() []ListCrossConnectsSortOrderEnum { + values := make([]ListCrossConnectsSortOrderEnum, 0) + for _, v := range mappingListCrossConnectsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_crossconnect_port_speed_shapes_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_crossconnect_port_speed_shapes_request_response.go new file mode 100644 index 000000000..9c38f8ba9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_crossconnect_port_speed_shapes_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListCrossconnectPortSpeedShapesRequest wrapper for the ListCrossconnectPortSpeedShapes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListCrossconnectPortSpeedShapes.go.html to see an example of how to use ListCrossconnectPortSpeedShapesRequest. +type ListCrossconnectPortSpeedShapesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListCrossconnectPortSpeedShapesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListCrossconnectPortSpeedShapesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListCrossconnectPortSpeedShapesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListCrossconnectPortSpeedShapesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListCrossconnectPortSpeedShapesResponse wrapper for the ListCrossconnectPortSpeedShapes operation +type ListCrossconnectPortSpeedShapesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []CrossConnectPortSpeedShape instances + Items []CrossConnectPortSpeedShape `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListCrossconnectPortSpeedShapesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListCrossconnectPortSpeedShapesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_host_instance_shapes_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_host_instance_shapes_request_response.go new file mode 100644 index 000000000..0c2f19384 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_host_instance_shapes_request_response.go @@ -0,0 +1,97 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListDedicatedVmHostInstanceShapesRequest wrapper for the ListDedicatedVmHostInstanceShapes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDedicatedVmHostInstanceShapes.go.html to see an example of how to use ListDedicatedVmHostInstanceShapesRequest. +type ListDedicatedVmHostInstanceShapesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" contributesTo:"query" name:"availabilityDomain"` + + // Dedicated VM host shape name + DedicatedVmHostShape *string `mandatory:"false" contributesTo:"query" name:"dedicatedVmHostShape"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListDedicatedVmHostInstanceShapesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListDedicatedVmHostInstanceShapesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListDedicatedVmHostInstanceShapesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListDedicatedVmHostInstanceShapesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListDedicatedVmHostInstanceShapesResponse wrapper for the ListDedicatedVmHostInstanceShapes operation +type ListDedicatedVmHostInstanceShapesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []DedicatedVmHostInstanceShapeSummary instances + Items []DedicatedVmHostInstanceShapeSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListDedicatedVmHostInstanceShapesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListDedicatedVmHostInstanceShapesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_host_instances_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_host_instances_request_response.go new file mode 100644 index 000000000..7efd3c5a0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_host_instances_request_response.go @@ -0,0 +1,156 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListDedicatedVmHostInstancesRequest wrapper for the ListDedicatedVmHostInstances operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDedicatedVmHostInstances.go.html to see an example of how to use ListDedicatedVmHostInstancesRequest. +type ListDedicatedVmHostInstancesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID of the dedicated VM host. + DedicatedVmHostId *string `mandatory:"true" contributesTo:"path" name:"dedicatedVmHostId"` + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" contributesTo:"query" name:"availabilityDomain"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListDedicatedVmHostInstancesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListDedicatedVmHostInstancesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListDedicatedVmHostInstancesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListDedicatedVmHostInstancesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListDedicatedVmHostInstancesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListDedicatedVmHostInstancesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListDedicatedVmHostInstancesResponse wrapper for the ListDedicatedVmHostInstances operation +type ListDedicatedVmHostInstancesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []DedicatedVmHostInstanceSummary instances + Items []DedicatedVmHostInstanceSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListDedicatedVmHostInstancesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListDedicatedVmHostInstancesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListDedicatedVmHostInstancesSortByEnum Enum with underlying type: string +type ListDedicatedVmHostInstancesSortByEnum string + +// Set of constants representing the allowable values for ListDedicatedVmHostInstancesSortByEnum +const ( + ListDedicatedVmHostInstancesSortByTimecreated ListDedicatedVmHostInstancesSortByEnum = "TIMECREATED" + ListDedicatedVmHostInstancesSortByDisplayname ListDedicatedVmHostInstancesSortByEnum = "DISPLAYNAME" +) + +var mappingListDedicatedVmHostInstancesSortBy = map[string]ListDedicatedVmHostInstancesSortByEnum{ + "TIMECREATED": ListDedicatedVmHostInstancesSortByTimecreated, + "DISPLAYNAME": ListDedicatedVmHostInstancesSortByDisplayname, +} + +// GetListDedicatedVmHostInstancesSortByEnumValues Enumerates the set of values for ListDedicatedVmHostInstancesSortByEnum +func GetListDedicatedVmHostInstancesSortByEnumValues() []ListDedicatedVmHostInstancesSortByEnum { + values := make([]ListDedicatedVmHostInstancesSortByEnum, 0) + for _, v := range mappingListDedicatedVmHostInstancesSortBy { + values = append(values, v) + } + return values +} + +// ListDedicatedVmHostInstancesSortOrderEnum Enum with underlying type: string +type ListDedicatedVmHostInstancesSortOrderEnum string + +// Set of constants representing the allowable values for ListDedicatedVmHostInstancesSortOrderEnum +const ( + ListDedicatedVmHostInstancesSortOrderAsc ListDedicatedVmHostInstancesSortOrderEnum = "ASC" + ListDedicatedVmHostInstancesSortOrderDesc ListDedicatedVmHostInstancesSortOrderEnum = "DESC" +) + +var mappingListDedicatedVmHostInstancesSortOrder = map[string]ListDedicatedVmHostInstancesSortOrderEnum{ + "ASC": ListDedicatedVmHostInstancesSortOrderAsc, + "DESC": ListDedicatedVmHostInstancesSortOrderDesc, +} + +// GetListDedicatedVmHostInstancesSortOrderEnumValues Enumerates the set of values for ListDedicatedVmHostInstancesSortOrderEnum +func GetListDedicatedVmHostInstancesSortOrderEnumValues() []ListDedicatedVmHostInstancesSortOrderEnum { + values := make([]ListDedicatedVmHostInstancesSortOrderEnum, 0) + for _, v := range mappingListDedicatedVmHostInstancesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_host_shapes_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_host_shapes_request_response.go new file mode 100644 index 000000000..76fb07b8f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_host_shapes_request_response.go @@ -0,0 +1,97 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListDedicatedVmHostShapesRequest wrapper for the ListDedicatedVmHostShapes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDedicatedVmHostShapes.go.html to see an example of how to use ListDedicatedVmHostShapesRequest. +type ListDedicatedVmHostShapesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" contributesTo:"query" name:"availabilityDomain"` + + // The name for the instance's shape. + InstanceShapeName *string `mandatory:"false" contributesTo:"query" name:"instanceShapeName"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListDedicatedVmHostShapesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListDedicatedVmHostShapesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListDedicatedVmHostShapesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListDedicatedVmHostShapesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListDedicatedVmHostShapesResponse wrapper for the ListDedicatedVmHostShapes operation +type ListDedicatedVmHostShapesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []DedicatedVmHostShapeSummary instances + Items []DedicatedVmHostShapeSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListDedicatedVmHostShapesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListDedicatedVmHostShapesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_hosts_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_hosts_request_response.go new file mode 100644 index 000000000..102b32a82 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_dedicated_vm_hosts_request_response.go @@ -0,0 +1,199 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListDedicatedVmHostsRequest wrapper for the ListDedicatedVmHosts operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDedicatedVmHosts.go.html to see an example of how to use ListDedicatedVmHostsRequest. +type ListDedicatedVmHostsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" contributesTo:"query" name:"availabilityDomain"` + + // A filter to only return resources that match the given lifecycle state. + LifecycleState ListDedicatedVmHostsLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The name for the instance's shape. + InstanceShapeName *string `mandatory:"false" contributesTo:"query" name:"instanceShapeName"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListDedicatedVmHostsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListDedicatedVmHostsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // The remaining memory of the dedicated VM host, in GBs. + RemainingMemoryInGBsGreaterThanOrEqualTo *float32 `mandatory:"false" contributesTo:"query" name:"remainingMemoryInGBsGreaterThanOrEqualTo"` + + // The available OCPUs of the dedicated VM host. + RemainingOcpusGreaterThanOrEqualTo *float32 `mandatory:"false" contributesTo:"query" name:"remainingOcpusGreaterThanOrEqualTo"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListDedicatedVmHostsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListDedicatedVmHostsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListDedicatedVmHostsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListDedicatedVmHostsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListDedicatedVmHostsResponse wrapper for the ListDedicatedVmHosts operation +type ListDedicatedVmHostsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []DedicatedVmHostSummary instances + Items []DedicatedVmHostSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListDedicatedVmHostsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListDedicatedVmHostsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListDedicatedVmHostsLifecycleStateEnum Enum with underlying type: string +type ListDedicatedVmHostsLifecycleStateEnum string + +// Set of constants representing the allowable values for ListDedicatedVmHostsLifecycleStateEnum +const ( + ListDedicatedVmHostsLifecycleStateCreating ListDedicatedVmHostsLifecycleStateEnum = "CREATING" + ListDedicatedVmHostsLifecycleStateActive ListDedicatedVmHostsLifecycleStateEnum = "ACTIVE" + ListDedicatedVmHostsLifecycleStateUpdating ListDedicatedVmHostsLifecycleStateEnum = "UPDATING" + ListDedicatedVmHostsLifecycleStateDeleting ListDedicatedVmHostsLifecycleStateEnum = "DELETING" + ListDedicatedVmHostsLifecycleStateDeleted ListDedicatedVmHostsLifecycleStateEnum = "DELETED" + ListDedicatedVmHostsLifecycleStateFailed ListDedicatedVmHostsLifecycleStateEnum = "FAILED" +) + +var mappingListDedicatedVmHostsLifecycleState = map[string]ListDedicatedVmHostsLifecycleStateEnum{ + "CREATING": ListDedicatedVmHostsLifecycleStateCreating, + "ACTIVE": ListDedicatedVmHostsLifecycleStateActive, + "UPDATING": ListDedicatedVmHostsLifecycleStateUpdating, + "DELETING": ListDedicatedVmHostsLifecycleStateDeleting, + "DELETED": ListDedicatedVmHostsLifecycleStateDeleted, + "FAILED": ListDedicatedVmHostsLifecycleStateFailed, +} + +// GetListDedicatedVmHostsLifecycleStateEnumValues Enumerates the set of values for ListDedicatedVmHostsLifecycleStateEnum +func GetListDedicatedVmHostsLifecycleStateEnumValues() []ListDedicatedVmHostsLifecycleStateEnum { + values := make([]ListDedicatedVmHostsLifecycleStateEnum, 0) + for _, v := range mappingListDedicatedVmHostsLifecycleState { + values = append(values, v) + } + return values +} + +// ListDedicatedVmHostsSortByEnum Enum with underlying type: string +type ListDedicatedVmHostsSortByEnum string + +// Set of constants representing the allowable values for ListDedicatedVmHostsSortByEnum +const ( + ListDedicatedVmHostsSortByTimecreated ListDedicatedVmHostsSortByEnum = "TIMECREATED" + ListDedicatedVmHostsSortByDisplayname ListDedicatedVmHostsSortByEnum = "DISPLAYNAME" +) + +var mappingListDedicatedVmHostsSortBy = map[string]ListDedicatedVmHostsSortByEnum{ + "TIMECREATED": ListDedicatedVmHostsSortByTimecreated, + "DISPLAYNAME": ListDedicatedVmHostsSortByDisplayname, +} + +// GetListDedicatedVmHostsSortByEnumValues Enumerates the set of values for ListDedicatedVmHostsSortByEnum +func GetListDedicatedVmHostsSortByEnumValues() []ListDedicatedVmHostsSortByEnum { + values := make([]ListDedicatedVmHostsSortByEnum, 0) + for _, v := range mappingListDedicatedVmHostsSortBy { + values = append(values, v) + } + return values +} + +// ListDedicatedVmHostsSortOrderEnum Enum with underlying type: string +type ListDedicatedVmHostsSortOrderEnum string + +// Set of constants representing the allowable values for ListDedicatedVmHostsSortOrderEnum +const ( + ListDedicatedVmHostsSortOrderAsc ListDedicatedVmHostsSortOrderEnum = "ASC" + ListDedicatedVmHostsSortOrderDesc ListDedicatedVmHostsSortOrderEnum = "DESC" +) + +var mappingListDedicatedVmHostsSortOrder = map[string]ListDedicatedVmHostsSortOrderEnum{ + "ASC": ListDedicatedVmHostsSortOrderAsc, + "DESC": ListDedicatedVmHostsSortOrderDesc, +} + +// GetListDedicatedVmHostsSortOrderEnumValues Enumerates the set of values for ListDedicatedVmHostsSortOrderEnum +func GetListDedicatedVmHostsSortOrderEnumValues() []ListDedicatedVmHostsSortOrderEnum { + values := make([]ListDedicatedVmHostsSortOrderEnum, 0) + for _, v := range mappingListDedicatedVmHostsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_dhcp_options_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_dhcp_options_request_response.go new file mode 100644 index 000000000..26b3b06a0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_dhcp_options_request_response.go @@ -0,0 +1,159 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListDhcpOptionsRequest wrapper for the ListDhcpOptions operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDhcpOptions.go.html to see an example of how to use ListDhcpOptionsRequest. +type ListDhcpOptionsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"false" contributesTo:"query" name:"vcnId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListDhcpOptionsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListDhcpOptionsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle + // state. The state value is case-insensitive. + LifecycleState DhcpOptionsLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListDhcpOptionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListDhcpOptionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListDhcpOptionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListDhcpOptionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListDhcpOptionsResponse wrapper for the ListDhcpOptions operation +type ListDhcpOptionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []DhcpOptions instances + Items []DhcpOptions `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListDhcpOptionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListDhcpOptionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListDhcpOptionsSortByEnum Enum with underlying type: string +type ListDhcpOptionsSortByEnum string + +// Set of constants representing the allowable values for ListDhcpOptionsSortByEnum +const ( + ListDhcpOptionsSortByTimecreated ListDhcpOptionsSortByEnum = "TIMECREATED" + ListDhcpOptionsSortByDisplayname ListDhcpOptionsSortByEnum = "DISPLAYNAME" +) + +var mappingListDhcpOptionsSortBy = map[string]ListDhcpOptionsSortByEnum{ + "TIMECREATED": ListDhcpOptionsSortByTimecreated, + "DISPLAYNAME": ListDhcpOptionsSortByDisplayname, +} + +// GetListDhcpOptionsSortByEnumValues Enumerates the set of values for ListDhcpOptionsSortByEnum +func GetListDhcpOptionsSortByEnumValues() []ListDhcpOptionsSortByEnum { + values := make([]ListDhcpOptionsSortByEnum, 0) + for _, v := range mappingListDhcpOptionsSortBy { + values = append(values, v) + } + return values +} + +// ListDhcpOptionsSortOrderEnum Enum with underlying type: string +type ListDhcpOptionsSortOrderEnum string + +// Set of constants representing the allowable values for ListDhcpOptionsSortOrderEnum +const ( + ListDhcpOptionsSortOrderAsc ListDhcpOptionsSortOrderEnum = "ASC" + ListDhcpOptionsSortOrderDesc ListDhcpOptionsSortOrderEnum = "DESC" +) + +var mappingListDhcpOptionsSortOrder = map[string]ListDhcpOptionsSortOrderEnum{ + "ASC": ListDhcpOptionsSortOrderAsc, + "DESC": ListDhcpOptionsSortOrderDesc, +} + +// GetListDhcpOptionsSortOrderEnumValues Enumerates the set of values for ListDhcpOptionsSortOrderEnum +func GetListDhcpOptionsSortOrderEnumValues() []ListDhcpOptionsSortOrderEnum { + values := make([]ListDhcpOptionsSortOrderEnum, 0) + for _, v := range mappingListDhcpOptionsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_attachments_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_attachments_request_response.go new file mode 100644 index 000000000..e787b4a78 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_attachments_request_response.go @@ -0,0 +1,200 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListDrgAttachmentsRequest wrapper for the ListDrgAttachments operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDrgAttachments.go.html to see an example of how to use ListDrgAttachmentsRequest. +type ListDrgAttachmentsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"false" contributesTo:"query" name:"vcnId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"false" contributesTo:"query" name:"drgId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the resource (virtual circuit, VCN, IPSec tunnel, or remote peering connection) attached to the DRG. + NetworkId *string `mandatory:"false" contributesTo:"query" name:"networkId"` + + // The type for the network resource attached to the DRG. + AttachmentType ListDrgAttachmentsAttachmentTypeEnum `mandatory:"false" contributesTo:"query" name:"attachmentType" omitEmpty:"true"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG route table assigned to the DRG attachment. + DrgRouteTableId *string `mandatory:"false" contributesTo:"query" name:"drgRouteTableId"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListDrgAttachmentsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListDrgAttachmentsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to return only resources that match the specified lifecycle + // state. The value is case insensitive. + LifecycleState DrgAttachmentLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListDrgAttachmentsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListDrgAttachmentsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListDrgAttachmentsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListDrgAttachmentsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListDrgAttachmentsResponse wrapper for the ListDrgAttachments operation +type ListDrgAttachmentsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []DrgAttachment instances + Items []DrgAttachment `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListDrgAttachmentsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListDrgAttachmentsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListDrgAttachmentsAttachmentTypeEnum Enum with underlying type: string +type ListDrgAttachmentsAttachmentTypeEnum string + +// Set of constants representing the allowable values for ListDrgAttachmentsAttachmentTypeEnum +const ( + ListDrgAttachmentsAttachmentTypeVcn ListDrgAttachmentsAttachmentTypeEnum = "VCN" + ListDrgAttachmentsAttachmentTypeVirtualCircuit ListDrgAttachmentsAttachmentTypeEnum = "VIRTUAL_CIRCUIT" + ListDrgAttachmentsAttachmentTypeRemotePeeringConnection ListDrgAttachmentsAttachmentTypeEnum = "REMOTE_PEERING_CONNECTION" + ListDrgAttachmentsAttachmentTypeIpsecTunnel ListDrgAttachmentsAttachmentTypeEnum = "IPSEC_TUNNEL" + ListDrgAttachmentsAttachmentTypeAll ListDrgAttachmentsAttachmentTypeEnum = "ALL" +) + +var mappingListDrgAttachmentsAttachmentType = map[string]ListDrgAttachmentsAttachmentTypeEnum{ + "VCN": ListDrgAttachmentsAttachmentTypeVcn, + "VIRTUAL_CIRCUIT": ListDrgAttachmentsAttachmentTypeVirtualCircuit, + "REMOTE_PEERING_CONNECTION": ListDrgAttachmentsAttachmentTypeRemotePeeringConnection, + "IPSEC_TUNNEL": ListDrgAttachmentsAttachmentTypeIpsecTunnel, + "ALL": ListDrgAttachmentsAttachmentTypeAll, +} + +// GetListDrgAttachmentsAttachmentTypeEnumValues Enumerates the set of values for ListDrgAttachmentsAttachmentTypeEnum +func GetListDrgAttachmentsAttachmentTypeEnumValues() []ListDrgAttachmentsAttachmentTypeEnum { + values := make([]ListDrgAttachmentsAttachmentTypeEnum, 0) + for _, v := range mappingListDrgAttachmentsAttachmentType { + values = append(values, v) + } + return values +} + +// ListDrgAttachmentsSortByEnum Enum with underlying type: string +type ListDrgAttachmentsSortByEnum string + +// Set of constants representing the allowable values for ListDrgAttachmentsSortByEnum +const ( + ListDrgAttachmentsSortByTimecreated ListDrgAttachmentsSortByEnum = "TIMECREATED" + ListDrgAttachmentsSortByDisplayname ListDrgAttachmentsSortByEnum = "DISPLAYNAME" +) + +var mappingListDrgAttachmentsSortBy = map[string]ListDrgAttachmentsSortByEnum{ + "TIMECREATED": ListDrgAttachmentsSortByTimecreated, + "DISPLAYNAME": ListDrgAttachmentsSortByDisplayname, +} + +// GetListDrgAttachmentsSortByEnumValues Enumerates the set of values for ListDrgAttachmentsSortByEnum +func GetListDrgAttachmentsSortByEnumValues() []ListDrgAttachmentsSortByEnum { + values := make([]ListDrgAttachmentsSortByEnum, 0) + for _, v := range mappingListDrgAttachmentsSortBy { + values = append(values, v) + } + return values +} + +// ListDrgAttachmentsSortOrderEnum Enum with underlying type: string +type ListDrgAttachmentsSortOrderEnum string + +// Set of constants representing the allowable values for ListDrgAttachmentsSortOrderEnum +const ( + ListDrgAttachmentsSortOrderAsc ListDrgAttachmentsSortOrderEnum = "ASC" + ListDrgAttachmentsSortOrderDesc ListDrgAttachmentsSortOrderEnum = "DESC" +) + +var mappingListDrgAttachmentsSortOrder = map[string]ListDrgAttachmentsSortOrderEnum{ + "ASC": ListDrgAttachmentsSortOrderAsc, + "DESC": ListDrgAttachmentsSortOrderDesc, +} + +// GetListDrgAttachmentsSortOrderEnumValues Enumerates the set of values for ListDrgAttachmentsSortOrderEnum +func GetListDrgAttachmentsSortOrderEnumValues() []ListDrgAttachmentsSortOrderEnum { + values := make([]ListDrgAttachmentsSortOrderEnum, 0) + for _, v := range mappingListDrgAttachmentsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_distribution_statements_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_distribution_statements_request_response.go new file mode 100644 index 000000000..3f3b88e94 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_distribution_statements_request_response.go @@ -0,0 +1,141 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListDrgRouteDistributionStatementsRequest wrapper for the ListDrgRouteDistributionStatements operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDrgRouteDistributionStatements.go.html to see an example of how to use ListDrgRouteDistributionStatementsRequest. +type ListDrgRouteDistributionStatementsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route distribution. + DrgRouteDistributionId *string `mandatory:"true" contributesTo:"path" name:"drgRouteDistributionId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. + SortBy ListDrgRouteDistributionStatementsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListDrgRouteDistributionStatementsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListDrgRouteDistributionStatementsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListDrgRouteDistributionStatementsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListDrgRouteDistributionStatementsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListDrgRouteDistributionStatementsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListDrgRouteDistributionStatementsResponse wrapper for the ListDrgRouteDistributionStatements operation +type ListDrgRouteDistributionStatementsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []DrgRouteDistributionStatement instances + Items []DrgRouteDistributionStatement `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListDrgRouteDistributionStatementsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListDrgRouteDistributionStatementsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListDrgRouteDistributionStatementsSortByEnum Enum with underlying type: string +type ListDrgRouteDistributionStatementsSortByEnum string + +// Set of constants representing the allowable values for ListDrgRouteDistributionStatementsSortByEnum +const ( + ListDrgRouteDistributionStatementsSortByTimecreated ListDrgRouteDistributionStatementsSortByEnum = "TIMECREATED" +) + +var mappingListDrgRouteDistributionStatementsSortBy = map[string]ListDrgRouteDistributionStatementsSortByEnum{ + "TIMECREATED": ListDrgRouteDistributionStatementsSortByTimecreated, +} + +// GetListDrgRouteDistributionStatementsSortByEnumValues Enumerates the set of values for ListDrgRouteDistributionStatementsSortByEnum +func GetListDrgRouteDistributionStatementsSortByEnumValues() []ListDrgRouteDistributionStatementsSortByEnum { + values := make([]ListDrgRouteDistributionStatementsSortByEnum, 0) + for _, v := range mappingListDrgRouteDistributionStatementsSortBy { + values = append(values, v) + } + return values +} + +// ListDrgRouteDistributionStatementsSortOrderEnum Enum with underlying type: string +type ListDrgRouteDistributionStatementsSortOrderEnum string + +// Set of constants representing the allowable values for ListDrgRouteDistributionStatementsSortOrderEnum +const ( + ListDrgRouteDistributionStatementsSortOrderAsc ListDrgRouteDistributionStatementsSortOrderEnum = "ASC" + ListDrgRouteDistributionStatementsSortOrderDesc ListDrgRouteDistributionStatementsSortOrderEnum = "DESC" +) + +var mappingListDrgRouteDistributionStatementsSortOrder = map[string]ListDrgRouteDistributionStatementsSortOrderEnum{ + "ASC": ListDrgRouteDistributionStatementsSortOrderAsc, + "DESC": ListDrgRouteDistributionStatementsSortOrderDesc, +} + +// GetListDrgRouteDistributionStatementsSortOrderEnumValues Enumerates the set of values for ListDrgRouteDistributionStatementsSortOrderEnum +func GetListDrgRouteDistributionStatementsSortOrderEnumValues() []ListDrgRouteDistributionStatementsSortOrderEnum { + values := make([]ListDrgRouteDistributionStatementsSortOrderEnum, 0) + for _, v := range mappingListDrgRouteDistributionStatementsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_distributions_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_distributions_request_response.go new file mode 100644 index 000000000..5949f74c8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_distributions_request_response.go @@ -0,0 +1,156 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListDrgRouteDistributionsRequest wrapper for the ListDrgRouteDistributions operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDrgRouteDistributions.go.html to see an example of how to use ListDrgRouteDistributionsRequest. +type ListDrgRouteDistributionsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"true" contributesTo:"query" name:"drgId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListDrgRouteDistributionsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListDrgRouteDistributionsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter that only returns resources that match the specified lifecycle + // state. The value is case insensitive. + LifecycleState DrgRouteDistributionLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListDrgRouteDistributionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListDrgRouteDistributionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListDrgRouteDistributionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListDrgRouteDistributionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListDrgRouteDistributionsResponse wrapper for the ListDrgRouteDistributions operation +type ListDrgRouteDistributionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []DrgRouteDistribution instances + Items []DrgRouteDistribution `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListDrgRouteDistributionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListDrgRouteDistributionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListDrgRouteDistributionsSortByEnum Enum with underlying type: string +type ListDrgRouteDistributionsSortByEnum string + +// Set of constants representing the allowable values for ListDrgRouteDistributionsSortByEnum +const ( + ListDrgRouteDistributionsSortByTimecreated ListDrgRouteDistributionsSortByEnum = "TIMECREATED" + ListDrgRouteDistributionsSortByDisplayname ListDrgRouteDistributionsSortByEnum = "DISPLAYNAME" +) + +var mappingListDrgRouteDistributionsSortBy = map[string]ListDrgRouteDistributionsSortByEnum{ + "TIMECREATED": ListDrgRouteDistributionsSortByTimecreated, + "DISPLAYNAME": ListDrgRouteDistributionsSortByDisplayname, +} + +// GetListDrgRouteDistributionsSortByEnumValues Enumerates the set of values for ListDrgRouteDistributionsSortByEnum +func GetListDrgRouteDistributionsSortByEnumValues() []ListDrgRouteDistributionsSortByEnum { + values := make([]ListDrgRouteDistributionsSortByEnum, 0) + for _, v := range mappingListDrgRouteDistributionsSortBy { + values = append(values, v) + } + return values +} + +// ListDrgRouteDistributionsSortOrderEnum Enum with underlying type: string +type ListDrgRouteDistributionsSortOrderEnum string + +// Set of constants representing the allowable values for ListDrgRouteDistributionsSortOrderEnum +const ( + ListDrgRouteDistributionsSortOrderAsc ListDrgRouteDistributionsSortOrderEnum = "ASC" + ListDrgRouteDistributionsSortOrderDesc ListDrgRouteDistributionsSortOrderEnum = "DESC" +) + +var mappingListDrgRouteDistributionsSortOrder = map[string]ListDrgRouteDistributionsSortOrderEnum{ + "ASC": ListDrgRouteDistributionsSortOrderAsc, + "DESC": ListDrgRouteDistributionsSortOrderDesc, +} + +// GetListDrgRouteDistributionsSortOrderEnumValues Enumerates the set of values for ListDrgRouteDistributionsSortOrderEnum +func GetListDrgRouteDistributionsSortOrderEnumValues() []ListDrgRouteDistributionsSortOrderEnum { + values := make([]ListDrgRouteDistributionsSortOrderEnum, 0) + for _, v := range mappingListDrgRouteDistributionsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_rules_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_rules_request_response.go new file mode 100644 index 000000000..d231f8f7c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_rules_request_response.go @@ -0,0 +1,117 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListDrgRouteRulesRequest wrapper for the ListDrgRouteRules operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDrgRouteRules.go.html to see an example of how to use ListDrgRouteRulesRequest. +type ListDrgRouteRulesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG route table. + DrgRouteTableId *string `mandatory:"true" contributesTo:"path" name:"drgRouteTableId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Static routes are specified through the DRG route table API. + // Dynamic routes are learned by the DRG from the DRG attachments through various routing protocols. + RouteType ListDrgRouteRulesRouteTypeEnum `mandatory:"false" contributesTo:"query" name:"routeType" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListDrgRouteRulesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListDrgRouteRulesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListDrgRouteRulesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListDrgRouteRulesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListDrgRouteRulesResponse wrapper for the ListDrgRouteRules operation +type ListDrgRouteRulesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []DrgRouteRule instances + Items []DrgRouteRule `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListDrgRouteRulesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListDrgRouteRulesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListDrgRouteRulesRouteTypeEnum Enum with underlying type: string +type ListDrgRouteRulesRouteTypeEnum string + +// Set of constants representing the allowable values for ListDrgRouteRulesRouteTypeEnum +const ( + ListDrgRouteRulesRouteTypeStatic ListDrgRouteRulesRouteTypeEnum = "STATIC" + ListDrgRouteRulesRouteTypeDynamic ListDrgRouteRulesRouteTypeEnum = "DYNAMIC" +) + +var mappingListDrgRouteRulesRouteType = map[string]ListDrgRouteRulesRouteTypeEnum{ + "STATIC": ListDrgRouteRulesRouteTypeStatic, + "DYNAMIC": ListDrgRouteRulesRouteTypeDynamic, +} + +// GetListDrgRouteRulesRouteTypeEnumValues Enumerates the set of values for ListDrgRouteRulesRouteTypeEnum +func GetListDrgRouteRulesRouteTypeEnumValues() []ListDrgRouteRulesRouteTypeEnum { + values := make([]ListDrgRouteRulesRouteTypeEnum, 0) + for _, v := range mappingListDrgRouteRulesRouteType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_tables_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_tables_request_response.go new file mode 100644 index 000000000..c9718b8a6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drg_route_tables_request_response.go @@ -0,0 +1,159 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListDrgRouteTablesRequest wrapper for the ListDrgRouteTables operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDrgRouteTables.go.html to see an example of how to use ListDrgRouteTablesRequest. +type ListDrgRouteTablesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"true" contributesTo:"query" name:"drgId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListDrgRouteTablesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListDrgRouteTablesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the import route distribution. + ImportDrgRouteDistributionId *string `mandatory:"false" contributesTo:"query" name:"importDrgRouteDistributionId"` + + // A filter that only returns matches for the specified lifecycle + // state. The value is case insensitive. + LifecycleState DrgRouteTableLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListDrgRouteTablesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListDrgRouteTablesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListDrgRouteTablesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListDrgRouteTablesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListDrgRouteTablesResponse wrapper for the ListDrgRouteTables operation +type ListDrgRouteTablesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []DrgRouteTable instances + Items []DrgRouteTable `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListDrgRouteTablesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListDrgRouteTablesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListDrgRouteTablesSortByEnum Enum with underlying type: string +type ListDrgRouteTablesSortByEnum string + +// Set of constants representing the allowable values for ListDrgRouteTablesSortByEnum +const ( + ListDrgRouteTablesSortByTimecreated ListDrgRouteTablesSortByEnum = "TIMECREATED" + ListDrgRouteTablesSortByDisplayname ListDrgRouteTablesSortByEnum = "DISPLAYNAME" +) + +var mappingListDrgRouteTablesSortBy = map[string]ListDrgRouteTablesSortByEnum{ + "TIMECREATED": ListDrgRouteTablesSortByTimecreated, + "DISPLAYNAME": ListDrgRouteTablesSortByDisplayname, +} + +// GetListDrgRouteTablesSortByEnumValues Enumerates the set of values for ListDrgRouteTablesSortByEnum +func GetListDrgRouteTablesSortByEnumValues() []ListDrgRouteTablesSortByEnum { + values := make([]ListDrgRouteTablesSortByEnum, 0) + for _, v := range mappingListDrgRouteTablesSortBy { + values = append(values, v) + } + return values +} + +// ListDrgRouteTablesSortOrderEnum Enum with underlying type: string +type ListDrgRouteTablesSortOrderEnum string + +// Set of constants representing the allowable values for ListDrgRouteTablesSortOrderEnum +const ( + ListDrgRouteTablesSortOrderAsc ListDrgRouteTablesSortOrderEnum = "ASC" + ListDrgRouteTablesSortOrderDesc ListDrgRouteTablesSortOrderEnum = "DESC" +) + +var mappingListDrgRouteTablesSortOrder = map[string]ListDrgRouteTablesSortOrderEnum{ + "ASC": ListDrgRouteTablesSortOrderAsc, + "DESC": ListDrgRouteTablesSortOrderDesc, +} + +// GetListDrgRouteTablesSortOrderEnumValues Enumerates the set of values for ListDrgRouteTablesSortOrderEnum +func GetListDrgRouteTablesSortOrderEnumValues() []ListDrgRouteTablesSortOrderEnum { + values := make([]ListDrgRouteTablesSortOrderEnum, 0) + for _, v := range mappingListDrgRouteTablesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drgs_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drgs_request_response.go new file mode 100644 index 000000000..1117460c9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_drgs_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListDrgsRequest wrapper for the ListDrgs operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListDrgs.go.html to see an example of how to use ListDrgsRequest. +type ListDrgsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListDrgsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListDrgsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListDrgsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListDrgsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListDrgsResponse wrapper for the ListDrgs operation +type ListDrgsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Drg instances + Items []Drg `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListDrgsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListDrgsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_fast_connect_provider_services_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_fast_connect_provider_services_request_response.go new file mode 100644 index 000000000..c390f3780 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_fast_connect_provider_services_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListFastConnectProviderServicesRequest wrapper for the ListFastConnectProviderServices operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListFastConnectProviderServices.go.html to see an example of how to use ListFastConnectProviderServicesRequest. +type ListFastConnectProviderServicesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListFastConnectProviderServicesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListFastConnectProviderServicesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListFastConnectProviderServicesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListFastConnectProviderServicesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListFastConnectProviderServicesResponse wrapper for the ListFastConnectProviderServices operation +type ListFastConnectProviderServicesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []FastConnectProviderService instances + Items []FastConnectProviderService `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListFastConnectProviderServicesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListFastConnectProviderServicesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_fast_connect_provider_virtual_circuit_bandwidth_shapes_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_fast_connect_provider_virtual_circuit_bandwidth_shapes_request_response.go new file mode 100644 index 000000000..535895a98 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_fast_connect_provider_virtual_circuit_bandwidth_shapes_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListFastConnectProviderVirtualCircuitBandwidthShapesRequest wrapper for the ListFastConnectProviderVirtualCircuitBandwidthShapes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListFastConnectProviderVirtualCircuitBandwidthShapes.go.html to see an example of how to use ListFastConnectProviderVirtualCircuitBandwidthShapesRequest. +type ListFastConnectProviderVirtualCircuitBandwidthShapesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the provider service. + ProviderServiceId *string `mandatory:"true" contributesTo:"path" name:"providerServiceId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListFastConnectProviderVirtualCircuitBandwidthShapesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListFastConnectProviderVirtualCircuitBandwidthShapesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListFastConnectProviderVirtualCircuitBandwidthShapesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListFastConnectProviderVirtualCircuitBandwidthShapesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListFastConnectProviderVirtualCircuitBandwidthShapesResponse wrapper for the ListFastConnectProviderVirtualCircuitBandwidthShapes operation +type ListFastConnectProviderVirtualCircuitBandwidthShapesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []VirtualCircuitBandwidthShape instances + Items []VirtualCircuitBandwidthShape `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListFastConnectProviderVirtualCircuitBandwidthShapesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListFastConnectProviderVirtualCircuitBandwidthShapesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connection_tunnel_routes_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connection_tunnel_routes_request_response.go new file mode 100644 index 000000000..dc6c3922c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connection_tunnel_routes_request_response.go @@ -0,0 +1,101 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListIPSecConnectionTunnelRoutesRequest wrapper for the ListIPSecConnectionTunnelRoutes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListIPSecConnectionTunnelRoutes.go.html to see an example of how to use ListIPSecConnectionTunnelRoutesRequest. +type ListIPSecConnectionTunnelRoutesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the tunnel. + TunnelId *string `mandatory:"true" contributesTo:"path" name:"tunnelId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Specifies the advertiser of the routes. If set to ORACLE, then returns only the + // routes advertised by ORACLE, else if set to CUSTOMER, then returns only the + // routes advertised by the CUSTOMER. + Advertiser TunnelRouteSummaryAdvertiserEnum `mandatory:"false" contributesTo:"query" name:"advertiser" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListIPSecConnectionTunnelRoutesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListIPSecConnectionTunnelRoutesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListIPSecConnectionTunnelRoutesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListIPSecConnectionTunnelRoutesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListIPSecConnectionTunnelRoutesResponse wrapper for the ListIPSecConnectionTunnelRoutes operation +type ListIPSecConnectionTunnelRoutesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []TunnelRouteSummary instances + Items []TunnelRouteSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For list pagination. A pagination token to get the total number of results available. + OpcTotalItems *int `presentIn:"header" name:"opc-total-items"` +} + +func (response ListIPSecConnectionTunnelRoutesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListIPSecConnectionTunnelRoutesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connection_tunnel_security_associations_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connection_tunnel_security_associations_request_response.go new file mode 100644 index 000000000..eb5b4842e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connection_tunnel_security_associations_request_response.go @@ -0,0 +1,96 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListIPSecConnectionTunnelSecurityAssociationsRequest wrapper for the ListIPSecConnectionTunnelSecurityAssociations operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListIPSecConnectionTunnelSecurityAssociations.go.html to see an example of how to use ListIPSecConnectionTunnelSecurityAssociationsRequest. +type ListIPSecConnectionTunnelSecurityAssociationsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the tunnel. + TunnelId *string `mandatory:"true" contributesTo:"path" name:"tunnelId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListIPSecConnectionTunnelSecurityAssociationsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListIPSecConnectionTunnelSecurityAssociationsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListIPSecConnectionTunnelSecurityAssociationsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListIPSecConnectionTunnelSecurityAssociationsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListIPSecConnectionTunnelSecurityAssociationsResponse wrapper for the ListIPSecConnectionTunnelSecurityAssociations operation +type ListIPSecConnectionTunnelSecurityAssociationsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []TunnelSecurityAssociationSummary instances + Items []TunnelSecurityAssociationSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For list pagination. A pagination token to get the total number of results available. + OpcTotalItems *int `presentIn:"header" name:"opc-total-items"` +} + +func (response ListIPSecConnectionTunnelSecurityAssociationsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListIPSecConnectionTunnelSecurityAssociationsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connection_tunnels_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connection_tunnels_request_response.go new file mode 100644 index 000000000..afdff7948 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connection_tunnels_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListIPSecConnectionTunnelsRequest wrapper for the ListIPSecConnectionTunnels operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListIPSecConnectionTunnels.go.html to see an example of how to use ListIPSecConnectionTunnelsRequest. +type ListIPSecConnectionTunnelsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListIPSecConnectionTunnelsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListIPSecConnectionTunnelsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListIPSecConnectionTunnelsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListIPSecConnectionTunnelsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListIPSecConnectionTunnelsResponse wrapper for the ListIPSecConnectionTunnels operation +type ListIPSecConnectionTunnelsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []IpSecConnectionTunnel instances + Items []IpSecConnectionTunnel `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListIPSecConnectionTunnelsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListIPSecConnectionTunnelsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connections_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connections_request_response.go new file mode 100644 index 000000000..775c4f8bf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_i_p_sec_connections_request_response.go @@ -0,0 +1,96 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListIPSecConnectionsRequest wrapper for the ListIPSecConnections operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListIPSecConnections.go.html to see an example of how to use ListIPSecConnectionsRequest. +type ListIPSecConnectionsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"false" contributesTo:"query" name:"drgId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the CPE. + CpeId *string `mandatory:"false" contributesTo:"query" name:"cpeId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListIPSecConnectionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListIPSecConnectionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListIPSecConnectionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListIPSecConnectionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListIPSecConnectionsResponse wrapper for the ListIPSecConnections operation +type ListIPSecConnectionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []IpSecConnection instances + Items []IpSecConnection `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListIPSecConnectionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListIPSecConnectionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_image_shape_compatibility_entries_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_image_shape_compatibility_entries_request_response.go new file mode 100644 index 000000000..8df8a9b8b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_image_shape_compatibility_entries_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListImageShapeCompatibilityEntriesRequest wrapper for the ListImageShapeCompatibilityEntries operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListImageShapeCompatibilityEntries.go.html to see an example of how to use ListImageShapeCompatibilityEntriesRequest. +type ListImageShapeCompatibilityEntriesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the image. + ImageId *string `mandatory:"true" contributesTo:"path" name:"imageId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListImageShapeCompatibilityEntriesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListImageShapeCompatibilityEntriesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListImageShapeCompatibilityEntriesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListImageShapeCompatibilityEntriesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListImageShapeCompatibilityEntriesResponse wrapper for the ListImageShapeCompatibilityEntries operation +type ListImageShapeCompatibilityEntriesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []ImageShapeCompatibilitySummary instances + Items []ImageShapeCompatibilitySummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListImageShapeCompatibilityEntriesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListImageShapeCompatibilityEntriesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_images_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_images_request_response.go new file mode 100644 index 000000000..c59235bf9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_images_request_response.go @@ -0,0 +1,167 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListImagesRequest wrapper for the ListImages operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListImages.go.html to see an example of how to use ListImagesRequest. +type ListImagesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The image's operating system. + // Example: `Oracle Linux` + OperatingSystem *string `mandatory:"false" contributesTo:"query" name:"operatingSystem"` + + // The image's operating system version. + // Example: `7.2` + OperatingSystemVersion *string `mandatory:"false" contributesTo:"query" name:"operatingSystemVersion"` + + // Shape name. + Shape *string `mandatory:"false" contributesTo:"query" name:"shape"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListImagesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListImagesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state + // value is case-insensitive. + LifecycleState ImageLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListImagesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListImagesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListImagesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListImagesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListImagesResponse wrapper for the ListImages operation +type ListImagesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Image instances + Items []Image `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListImagesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListImagesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListImagesSortByEnum Enum with underlying type: string +type ListImagesSortByEnum string + +// Set of constants representing the allowable values for ListImagesSortByEnum +const ( + ListImagesSortByTimecreated ListImagesSortByEnum = "TIMECREATED" + ListImagesSortByDisplayname ListImagesSortByEnum = "DISPLAYNAME" +) + +var mappingListImagesSortBy = map[string]ListImagesSortByEnum{ + "TIMECREATED": ListImagesSortByTimecreated, + "DISPLAYNAME": ListImagesSortByDisplayname, +} + +// GetListImagesSortByEnumValues Enumerates the set of values for ListImagesSortByEnum +func GetListImagesSortByEnumValues() []ListImagesSortByEnum { + values := make([]ListImagesSortByEnum, 0) + for _, v := range mappingListImagesSortBy { + values = append(values, v) + } + return values +} + +// ListImagesSortOrderEnum Enum with underlying type: string +type ListImagesSortOrderEnum string + +// Set of constants representing the allowable values for ListImagesSortOrderEnum +const ( + ListImagesSortOrderAsc ListImagesSortOrderEnum = "ASC" + ListImagesSortOrderDesc ListImagesSortOrderEnum = "DESC" +) + +var mappingListImagesSortOrder = map[string]ListImagesSortOrderEnum{ + "ASC": ListImagesSortOrderAsc, + "DESC": ListImagesSortOrderDesc, +} + +// GetListImagesSortOrderEnumValues Enumerates the set of values for ListImagesSortOrderEnum +func GetListImagesSortOrderEnumValues() []ListImagesSortOrderEnum { + values := make([]ListImagesSortOrderEnum, 0) + for _, v := range mappingListImagesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_configurations_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_configurations_request_response.go new file mode 100644 index 000000000..0c0b81c79 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_configurations_request_response.go @@ -0,0 +1,149 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListInstanceConfigurationsRequest wrapper for the ListInstanceConfigurations operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListInstanceConfigurations.go.html to see an example of how to use ListInstanceConfigurationsRequest. +type ListInstanceConfigurationsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListInstanceConfigurationsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListInstanceConfigurationsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListInstanceConfigurationsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListInstanceConfigurationsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListInstanceConfigurationsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListInstanceConfigurationsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListInstanceConfigurationsResponse wrapper for the ListInstanceConfigurations operation +type ListInstanceConfigurationsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []InstanceConfigurationSummary instances + Items []InstanceConfigurationSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListInstanceConfigurationsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListInstanceConfigurationsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListInstanceConfigurationsSortByEnum Enum with underlying type: string +type ListInstanceConfigurationsSortByEnum string + +// Set of constants representing the allowable values for ListInstanceConfigurationsSortByEnum +const ( + ListInstanceConfigurationsSortByTimecreated ListInstanceConfigurationsSortByEnum = "TIMECREATED" + ListInstanceConfigurationsSortByDisplayname ListInstanceConfigurationsSortByEnum = "DISPLAYNAME" +) + +var mappingListInstanceConfigurationsSortBy = map[string]ListInstanceConfigurationsSortByEnum{ + "TIMECREATED": ListInstanceConfigurationsSortByTimecreated, + "DISPLAYNAME": ListInstanceConfigurationsSortByDisplayname, +} + +// GetListInstanceConfigurationsSortByEnumValues Enumerates the set of values for ListInstanceConfigurationsSortByEnum +func GetListInstanceConfigurationsSortByEnumValues() []ListInstanceConfigurationsSortByEnum { + values := make([]ListInstanceConfigurationsSortByEnum, 0) + for _, v := range mappingListInstanceConfigurationsSortBy { + values = append(values, v) + } + return values +} + +// ListInstanceConfigurationsSortOrderEnum Enum with underlying type: string +type ListInstanceConfigurationsSortOrderEnum string + +// Set of constants representing the allowable values for ListInstanceConfigurationsSortOrderEnum +const ( + ListInstanceConfigurationsSortOrderAsc ListInstanceConfigurationsSortOrderEnum = "ASC" + ListInstanceConfigurationsSortOrderDesc ListInstanceConfigurationsSortOrderEnum = "DESC" +) + +var mappingListInstanceConfigurationsSortOrder = map[string]ListInstanceConfigurationsSortOrderEnum{ + "ASC": ListInstanceConfigurationsSortOrderAsc, + "DESC": ListInstanceConfigurationsSortOrderDesc, +} + +// GetListInstanceConfigurationsSortOrderEnumValues Enumerates the set of values for ListInstanceConfigurationsSortOrderEnum +func GetListInstanceConfigurationsSortOrderEnumValues() []ListInstanceConfigurationsSortOrderEnum { + values := make([]ListInstanceConfigurationsSortOrderEnum, 0) + for _, v := range mappingListInstanceConfigurationsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_console_connections_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_console_connections_request_response.go new file mode 100644 index 000000000..64b44743e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_console_connections_request_response.go @@ -0,0 +1,93 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListInstanceConsoleConnectionsRequest wrapper for the ListInstanceConsoleConnections operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListInstanceConsoleConnections.go.html to see an example of how to use ListInstanceConsoleConnectionsRequest. +type ListInstanceConsoleConnectionsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID of the instance. + InstanceId *string `mandatory:"false" contributesTo:"query" name:"instanceId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListInstanceConsoleConnectionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListInstanceConsoleConnectionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListInstanceConsoleConnectionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListInstanceConsoleConnectionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListInstanceConsoleConnectionsResponse wrapper for the ListInstanceConsoleConnections operation +type ListInstanceConsoleConnectionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []InstanceConsoleConnection instances + Items []InstanceConsoleConnection `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListInstanceConsoleConnectionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListInstanceConsoleConnectionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_devices_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_devices_request_response.go new file mode 100644 index 000000000..ca4e85c9f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_devices_request_response.go @@ -0,0 +1,155 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListInstanceDevicesRequest wrapper for the ListInstanceDevices operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListInstanceDevices.go.html to see an example of how to use ListInstanceDevicesRequest. +type ListInstanceDevicesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance. + InstanceId *string `mandatory:"true" contributesTo:"path" name:"instanceId"` + + // A filter to return only available devices or only used devices. + IsAvailable *bool `mandatory:"false" contributesTo:"query" name:"isAvailable"` + + // A filter to return only devices that match the given name exactly. + Name *string `mandatory:"false" contributesTo:"query" name:"name"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListInstanceDevicesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListInstanceDevicesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListInstanceDevicesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListInstanceDevicesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListInstanceDevicesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListInstanceDevicesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListInstanceDevicesResponse wrapper for the ListInstanceDevices operation +type ListInstanceDevicesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Device instances + Items []Device `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListInstanceDevicesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListInstanceDevicesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListInstanceDevicesSortByEnum Enum with underlying type: string +type ListInstanceDevicesSortByEnum string + +// Set of constants representing the allowable values for ListInstanceDevicesSortByEnum +const ( + ListInstanceDevicesSortByTimecreated ListInstanceDevicesSortByEnum = "TIMECREATED" + ListInstanceDevicesSortByDisplayname ListInstanceDevicesSortByEnum = "DISPLAYNAME" +) + +var mappingListInstanceDevicesSortBy = map[string]ListInstanceDevicesSortByEnum{ + "TIMECREATED": ListInstanceDevicesSortByTimecreated, + "DISPLAYNAME": ListInstanceDevicesSortByDisplayname, +} + +// GetListInstanceDevicesSortByEnumValues Enumerates the set of values for ListInstanceDevicesSortByEnum +func GetListInstanceDevicesSortByEnumValues() []ListInstanceDevicesSortByEnum { + values := make([]ListInstanceDevicesSortByEnum, 0) + for _, v := range mappingListInstanceDevicesSortBy { + values = append(values, v) + } + return values +} + +// ListInstanceDevicesSortOrderEnum Enum with underlying type: string +type ListInstanceDevicesSortOrderEnum string + +// Set of constants representing the allowable values for ListInstanceDevicesSortOrderEnum +const ( + ListInstanceDevicesSortOrderAsc ListInstanceDevicesSortOrderEnum = "ASC" + ListInstanceDevicesSortOrderDesc ListInstanceDevicesSortOrderEnum = "DESC" +) + +var mappingListInstanceDevicesSortOrder = map[string]ListInstanceDevicesSortOrderEnum{ + "ASC": ListInstanceDevicesSortOrderAsc, + "DESC": ListInstanceDevicesSortOrderDesc, +} + +// GetListInstanceDevicesSortOrderEnumValues Enumerates the set of values for ListInstanceDevicesSortOrderEnum +func GetListInstanceDevicesSortOrderEnumValues() []ListInstanceDevicesSortOrderEnum { + values := make([]ListInstanceDevicesSortOrderEnum, 0) + for _, v := range mappingListInstanceDevicesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_pool_instances_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_pool_instances_request_response.go new file mode 100644 index 000000000..8bdf81fa3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_pool_instances_request_response.go @@ -0,0 +1,155 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListInstancePoolInstancesRequest wrapper for the ListInstancePoolInstances operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListInstancePoolInstances.go.html to see an example of how to use ListInstancePoolInstancesRequest. +type ListInstancePoolInstancesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" contributesTo:"path" name:"instancePoolId"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListInstancePoolInstancesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListInstancePoolInstancesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListInstancePoolInstancesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListInstancePoolInstancesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListInstancePoolInstancesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListInstancePoolInstancesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListInstancePoolInstancesResponse wrapper for the ListInstancePoolInstances operation +type ListInstancePoolInstancesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []InstanceSummary instances + Items []InstanceSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListInstancePoolInstancesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListInstancePoolInstancesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListInstancePoolInstancesSortByEnum Enum with underlying type: string +type ListInstancePoolInstancesSortByEnum string + +// Set of constants representing the allowable values for ListInstancePoolInstancesSortByEnum +const ( + ListInstancePoolInstancesSortByTimecreated ListInstancePoolInstancesSortByEnum = "TIMECREATED" + ListInstancePoolInstancesSortByDisplayname ListInstancePoolInstancesSortByEnum = "DISPLAYNAME" +) + +var mappingListInstancePoolInstancesSortBy = map[string]ListInstancePoolInstancesSortByEnum{ + "TIMECREATED": ListInstancePoolInstancesSortByTimecreated, + "DISPLAYNAME": ListInstancePoolInstancesSortByDisplayname, +} + +// GetListInstancePoolInstancesSortByEnumValues Enumerates the set of values for ListInstancePoolInstancesSortByEnum +func GetListInstancePoolInstancesSortByEnumValues() []ListInstancePoolInstancesSortByEnum { + values := make([]ListInstancePoolInstancesSortByEnum, 0) + for _, v := range mappingListInstancePoolInstancesSortBy { + values = append(values, v) + } + return values +} + +// ListInstancePoolInstancesSortOrderEnum Enum with underlying type: string +type ListInstancePoolInstancesSortOrderEnum string + +// Set of constants representing the allowable values for ListInstancePoolInstancesSortOrderEnum +const ( + ListInstancePoolInstancesSortOrderAsc ListInstancePoolInstancesSortOrderEnum = "ASC" + ListInstancePoolInstancesSortOrderDesc ListInstancePoolInstancesSortOrderEnum = "DESC" +) + +var mappingListInstancePoolInstancesSortOrder = map[string]ListInstancePoolInstancesSortOrderEnum{ + "ASC": ListInstancePoolInstancesSortOrderAsc, + "DESC": ListInstancePoolInstancesSortOrderDesc, +} + +// GetListInstancePoolInstancesSortOrderEnumValues Enumerates the set of values for ListInstancePoolInstancesSortOrderEnum +func GetListInstancePoolInstancesSortOrderEnumValues() []ListInstancePoolInstancesSortOrderEnum { + values := make([]ListInstancePoolInstancesSortOrderEnum, 0) + for _, v := range mappingListInstancePoolInstancesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_pools_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_pools_request_response.go new file mode 100644 index 000000000..4313fdc4f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instance_pools_request_response.go @@ -0,0 +1,156 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListInstancePoolsRequest wrapper for the ListInstancePools operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListInstancePools.go.html to see an example of how to use ListInstancePoolsRequest. +type ListInstancePoolsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListInstancePoolsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListInstancePoolsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state + // value is case-insensitive. + LifecycleState InstancePoolSummaryLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListInstancePoolsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListInstancePoolsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListInstancePoolsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListInstancePoolsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListInstancePoolsResponse wrapper for the ListInstancePools operation +type ListInstancePoolsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []InstancePoolSummary instances + Items []InstancePoolSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListInstancePoolsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListInstancePoolsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListInstancePoolsSortByEnum Enum with underlying type: string +type ListInstancePoolsSortByEnum string + +// Set of constants representing the allowable values for ListInstancePoolsSortByEnum +const ( + ListInstancePoolsSortByTimecreated ListInstancePoolsSortByEnum = "TIMECREATED" + ListInstancePoolsSortByDisplayname ListInstancePoolsSortByEnum = "DISPLAYNAME" +) + +var mappingListInstancePoolsSortBy = map[string]ListInstancePoolsSortByEnum{ + "TIMECREATED": ListInstancePoolsSortByTimecreated, + "DISPLAYNAME": ListInstancePoolsSortByDisplayname, +} + +// GetListInstancePoolsSortByEnumValues Enumerates the set of values for ListInstancePoolsSortByEnum +func GetListInstancePoolsSortByEnumValues() []ListInstancePoolsSortByEnum { + values := make([]ListInstancePoolsSortByEnum, 0) + for _, v := range mappingListInstancePoolsSortBy { + values = append(values, v) + } + return values +} + +// ListInstancePoolsSortOrderEnum Enum with underlying type: string +type ListInstancePoolsSortOrderEnum string + +// Set of constants representing the allowable values for ListInstancePoolsSortOrderEnum +const ( + ListInstancePoolsSortOrderAsc ListInstancePoolsSortOrderEnum = "ASC" + ListInstancePoolsSortOrderDesc ListInstancePoolsSortOrderEnum = "DESC" +) + +var mappingListInstancePoolsSortOrder = map[string]ListInstancePoolsSortOrderEnum{ + "ASC": ListInstancePoolsSortOrderAsc, + "DESC": ListInstancePoolsSortOrderDesc, +} + +// GetListInstancePoolsSortOrderEnumValues Enumerates the set of values for ListInstancePoolsSortOrderEnum +func GetListInstancePoolsSortOrderEnumValues() []ListInstancePoolsSortOrderEnum { + values := make([]ListInstancePoolsSortOrderEnum, 0) + for _, v := range mappingListInstancePoolsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instances_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instances_request_response.go new file mode 100644 index 000000000..cd7f3f6b7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_instances_request_response.go @@ -0,0 +1,163 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListInstancesRequest wrapper for the ListInstances operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListInstances.go.html to see an example of how to use ListInstancesRequest. +type ListInstancesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" contributesTo:"query" name:"availabilityDomain"` + + // The OCID of the compute capacity reservation. + CapacityReservationId *string `mandatory:"false" contributesTo:"query" name:"capacityReservationId"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListInstancesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListInstancesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state + // value is case-insensitive. + LifecycleState InstanceLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListInstancesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListInstancesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListInstancesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListInstancesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListInstancesResponse wrapper for the ListInstances operation +type ListInstancesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Instance instances + Items []Instance `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListInstancesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListInstancesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListInstancesSortByEnum Enum with underlying type: string +type ListInstancesSortByEnum string + +// Set of constants representing the allowable values for ListInstancesSortByEnum +const ( + ListInstancesSortByTimecreated ListInstancesSortByEnum = "TIMECREATED" + ListInstancesSortByDisplayname ListInstancesSortByEnum = "DISPLAYNAME" +) + +var mappingListInstancesSortBy = map[string]ListInstancesSortByEnum{ + "TIMECREATED": ListInstancesSortByTimecreated, + "DISPLAYNAME": ListInstancesSortByDisplayname, +} + +// GetListInstancesSortByEnumValues Enumerates the set of values for ListInstancesSortByEnum +func GetListInstancesSortByEnumValues() []ListInstancesSortByEnum { + values := make([]ListInstancesSortByEnum, 0) + for _, v := range mappingListInstancesSortBy { + values = append(values, v) + } + return values +} + +// ListInstancesSortOrderEnum Enum with underlying type: string +type ListInstancesSortOrderEnum string + +// Set of constants representing the allowable values for ListInstancesSortOrderEnum +const ( + ListInstancesSortOrderAsc ListInstancesSortOrderEnum = "ASC" + ListInstancesSortOrderDesc ListInstancesSortOrderEnum = "DESC" +) + +var mappingListInstancesSortOrder = map[string]ListInstancesSortOrderEnum{ + "ASC": ListInstancesSortOrderAsc, + "DESC": ListInstancesSortOrderDesc, +} + +// GetListInstancesSortOrderEnumValues Enumerates the set of values for ListInstancesSortOrderEnum +func GetListInstancesSortOrderEnumValues() []ListInstancesSortOrderEnum { + values := make([]ListInstancesSortOrderEnum, 0) + for _, v := range mappingListInstancesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_internet_gateways_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_internet_gateways_request_response.go new file mode 100644 index 000000000..868daeec5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_internet_gateways_request_response.go @@ -0,0 +1,159 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListInternetGatewaysRequest wrapper for the ListInternetGateways operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListInternetGateways.go.html to see an example of how to use ListInternetGatewaysRequest. +type ListInternetGatewaysRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"false" contributesTo:"query" name:"vcnId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListInternetGatewaysSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListInternetGatewaysSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle + // state. The state value is case-insensitive. + LifecycleState InternetGatewayLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListInternetGatewaysRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListInternetGatewaysRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListInternetGatewaysRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListInternetGatewaysRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListInternetGatewaysResponse wrapper for the ListInternetGateways operation +type ListInternetGatewaysResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []InternetGateway instances + Items []InternetGateway `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListInternetGatewaysResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListInternetGatewaysResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListInternetGatewaysSortByEnum Enum with underlying type: string +type ListInternetGatewaysSortByEnum string + +// Set of constants representing the allowable values for ListInternetGatewaysSortByEnum +const ( + ListInternetGatewaysSortByTimecreated ListInternetGatewaysSortByEnum = "TIMECREATED" + ListInternetGatewaysSortByDisplayname ListInternetGatewaysSortByEnum = "DISPLAYNAME" +) + +var mappingListInternetGatewaysSortBy = map[string]ListInternetGatewaysSortByEnum{ + "TIMECREATED": ListInternetGatewaysSortByTimecreated, + "DISPLAYNAME": ListInternetGatewaysSortByDisplayname, +} + +// GetListInternetGatewaysSortByEnumValues Enumerates the set of values for ListInternetGatewaysSortByEnum +func GetListInternetGatewaysSortByEnumValues() []ListInternetGatewaysSortByEnum { + values := make([]ListInternetGatewaysSortByEnum, 0) + for _, v := range mappingListInternetGatewaysSortBy { + values = append(values, v) + } + return values +} + +// ListInternetGatewaysSortOrderEnum Enum with underlying type: string +type ListInternetGatewaysSortOrderEnum string + +// Set of constants representing the allowable values for ListInternetGatewaysSortOrderEnum +const ( + ListInternetGatewaysSortOrderAsc ListInternetGatewaysSortOrderEnum = "ASC" + ListInternetGatewaysSortOrderDesc ListInternetGatewaysSortOrderEnum = "DESC" +) + +var mappingListInternetGatewaysSortOrder = map[string]ListInternetGatewaysSortOrderEnum{ + "ASC": ListInternetGatewaysSortOrderAsc, + "DESC": ListInternetGatewaysSortOrderDesc, +} + +// GetListInternetGatewaysSortOrderEnumValues Enumerates the set of values for ListInternetGatewaysSortOrderEnum +func GetListInternetGatewaysSortOrderEnumValues() []ListInternetGatewaysSortOrderEnum { + values := make([]ListInternetGatewaysSortOrderEnum, 0) + for _, v := range mappingListInternetGatewaysSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_ipv6s_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_ipv6s_request_response.go new file mode 100644 index 000000000..ceef3f040 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_ipv6s_request_response.go @@ -0,0 +1,97 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListIpv6sRequest wrapper for the ListIpv6s operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListIpv6s.go.html to see an example of how to use ListIpv6sRequest. +type ListIpv6sRequest struct { + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // An IP address. This could be either IPv4 or IPv6, depending on the resource. + // Example: `10.0.3.3` + IpAddress *string `mandatory:"false" contributesTo:"query" name:"ipAddress"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the subnet. + SubnetId *string `mandatory:"false" contributesTo:"query" name:"subnetId"` + + // The OCID of the VNIC. + VnicId *string `mandatory:"false" contributesTo:"query" name:"vnicId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListIpv6sRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListIpv6sRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListIpv6sRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListIpv6sRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListIpv6sResponse wrapper for the ListIpv6s operation +type ListIpv6sResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Ipv6 instances + Items []Ipv6 `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListIpv6sResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListIpv6sResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_local_peering_gateways_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_local_peering_gateways_request_response.go new file mode 100644 index 000000000..74a549b58 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_local_peering_gateways_request_response.go @@ -0,0 +1,93 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListLocalPeeringGatewaysRequest wrapper for the ListLocalPeeringGateways operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListLocalPeeringGateways.go.html to see an example of how to use ListLocalPeeringGatewaysRequest. +type ListLocalPeeringGatewaysRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"false" contributesTo:"query" name:"vcnId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListLocalPeeringGatewaysRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListLocalPeeringGatewaysRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListLocalPeeringGatewaysRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListLocalPeeringGatewaysRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListLocalPeeringGatewaysResponse wrapper for the ListLocalPeeringGateways operation +type ListLocalPeeringGatewaysResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []LocalPeeringGateway instances + Items []LocalPeeringGateway `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListLocalPeeringGatewaysResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListLocalPeeringGatewaysResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_nat_gateways_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_nat_gateways_request_response.go new file mode 100644 index 000000000..bbad36706 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_nat_gateways_request_response.go @@ -0,0 +1,159 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListNatGatewaysRequest wrapper for the ListNatGateways operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListNatGateways.go.html to see an example of how to use ListNatGatewaysRequest. +type ListNatGatewaysRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"false" contributesTo:"query" name:"vcnId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListNatGatewaysSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListNatGatewaysSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to return only resources that match the specified lifecycle + // state. The value is case insensitive. + LifecycleState NatGatewayLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListNatGatewaysRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListNatGatewaysRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListNatGatewaysRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListNatGatewaysRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListNatGatewaysResponse wrapper for the ListNatGateways operation +type ListNatGatewaysResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []NatGateway instances + Items []NatGateway `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListNatGatewaysResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListNatGatewaysResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListNatGatewaysSortByEnum Enum with underlying type: string +type ListNatGatewaysSortByEnum string + +// Set of constants representing the allowable values for ListNatGatewaysSortByEnum +const ( + ListNatGatewaysSortByTimecreated ListNatGatewaysSortByEnum = "TIMECREATED" + ListNatGatewaysSortByDisplayname ListNatGatewaysSortByEnum = "DISPLAYNAME" +) + +var mappingListNatGatewaysSortBy = map[string]ListNatGatewaysSortByEnum{ + "TIMECREATED": ListNatGatewaysSortByTimecreated, + "DISPLAYNAME": ListNatGatewaysSortByDisplayname, +} + +// GetListNatGatewaysSortByEnumValues Enumerates the set of values for ListNatGatewaysSortByEnum +func GetListNatGatewaysSortByEnumValues() []ListNatGatewaysSortByEnum { + values := make([]ListNatGatewaysSortByEnum, 0) + for _, v := range mappingListNatGatewaysSortBy { + values = append(values, v) + } + return values +} + +// ListNatGatewaysSortOrderEnum Enum with underlying type: string +type ListNatGatewaysSortOrderEnum string + +// Set of constants representing the allowable values for ListNatGatewaysSortOrderEnum +const ( + ListNatGatewaysSortOrderAsc ListNatGatewaysSortOrderEnum = "ASC" + ListNatGatewaysSortOrderDesc ListNatGatewaysSortOrderEnum = "DESC" +) + +var mappingListNatGatewaysSortOrder = map[string]ListNatGatewaysSortOrderEnum{ + "ASC": ListNatGatewaysSortOrderAsc, + "DESC": ListNatGatewaysSortOrderDesc, +} + +// GetListNatGatewaysSortOrderEnumValues Enumerates the set of values for ListNatGatewaysSortOrderEnum +func GetListNatGatewaysSortOrderEnumValues() []ListNatGatewaysSortOrderEnum { + values := make([]ListNatGatewaysSortOrderEnum, 0) + for _, v := range mappingListNatGatewaysSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_network_security_group_security_rules_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_network_security_group_security_rules_request_response.go new file mode 100644 index 000000000..9df9e83af --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_network_security_group_security_rules_request_response.go @@ -0,0 +1,168 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListNetworkSecurityGroupSecurityRulesRequest wrapper for the ListNetworkSecurityGroupSecurityRules operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListNetworkSecurityGroupSecurityRules.go.html to see an example of how to use ListNetworkSecurityGroupSecurityRulesRequest. +type ListNetworkSecurityGroupSecurityRulesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network security group. + NetworkSecurityGroupId *string `mandatory:"true" contributesTo:"path" name:"networkSecurityGroupId"` + + // Direction of the security rule. Set to `EGRESS` for rules that allow outbound IP packets, + // or `INGRESS` for rules that allow inbound IP packets. + Direction ListNetworkSecurityGroupSecurityRulesDirectionEnum `mandatory:"false" contributesTo:"query" name:"direction" omitEmpty:"true"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. + SortBy ListNetworkSecurityGroupSecurityRulesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListNetworkSecurityGroupSecurityRulesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListNetworkSecurityGroupSecurityRulesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListNetworkSecurityGroupSecurityRulesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListNetworkSecurityGroupSecurityRulesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListNetworkSecurityGroupSecurityRulesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListNetworkSecurityGroupSecurityRulesResponse wrapper for the ListNetworkSecurityGroupSecurityRules operation +type ListNetworkSecurityGroupSecurityRulesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []SecurityRule instances + Items []SecurityRule `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListNetworkSecurityGroupSecurityRulesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListNetworkSecurityGroupSecurityRulesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListNetworkSecurityGroupSecurityRulesDirectionEnum Enum with underlying type: string +type ListNetworkSecurityGroupSecurityRulesDirectionEnum string + +// Set of constants representing the allowable values for ListNetworkSecurityGroupSecurityRulesDirectionEnum +const ( + ListNetworkSecurityGroupSecurityRulesDirectionEgress ListNetworkSecurityGroupSecurityRulesDirectionEnum = "EGRESS" + ListNetworkSecurityGroupSecurityRulesDirectionIngress ListNetworkSecurityGroupSecurityRulesDirectionEnum = "INGRESS" +) + +var mappingListNetworkSecurityGroupSecurityRulesDirection = map[string]ListNetworkSecurityGroupSecurityRulesDirectionEnum{ + "EGRESS": ListNetworkSecurityGroupSecurityRulesDirectionEgress, + "INGRESS": ListNetworkSecurityGroupSecurityRulesDirectionIngress, +} + +// GetListNetworkSecurityGroupSecurityRulesDirectionEnumValues Enumerates the set of values for ListNetworkSecurityGroupSecurityRulesDirectionEnum +func GetListNetworkSecurityGroupSecurityRulesDirectionEnumValues() []ListNetworkSecurityGroupSecurityRulesDirectionEnum { + values := make([]ListNetworkSecurityGroupSecurityRulesDirectionEnum, 0) + for _, v := range mappingListNetworkSecurityGroupSecurityRulesDirection { + values = append(values, v) + } + return values +} + +// ListNetworkSecurityGroupSecurityRulesSortByEnum Enum with underlying type: string +type ListNetworkSecurityGroupSecurityRulesSortByEnum string + +// Set of constants representing the allowable values for ListNetworkSecurityGroupSecurityRulesSortByEnum +const ( + ListNetworkSecurityGroupSecurityRulesSortByTimecreated ListNetworkSecurityGroupSecurityRulesSortByEnum = "TIMECREATED" +) + +var mappingListNetworkSecurityGroupSecurityRulesSortBy = map[string]ListNetworkSecurityGroupSecurityRulesSortByEnum{ + "TIMECREATED": ListNetworkSecurityGroupSecurityRulesSortByTimecreated, +} + +// GetListNetworkSecurityGroupSecurityRulesSortByEnumValues Enumerates the set of values for ListNetworkSecurityGroupSecurityRulesSortByEnum +func GetListNetworkSecurityGroupSecurityRulesSortByEnumValues() []ListNetworkSecurityGroupSecurityRulesSortByEnum { + values := make([]ListNetworkSecurityGroupSecurityRulesSortByEnum, 0) + for _, v := range mappingListNetworkSecurityGroupSecurityRulesSortBy { + values = append(values, v) + } + return values +} + +// ListNetworkSecurityGroupSecurityRulesSortOrderEnum Enum with underlying type: string +type ListNetworkSecurityGroupSecurityRulesSortOrderEnum string + +// Set of constants representing the allowable values for ListNetworkSecurityGroupSecurityRulesSortOrderEnum +const ( + ListNetworkSecurityGroupSecurityRulesSortOrderAsc ListNetworkSecurityGroupSecurityRulesSortOrderEnum = "ASC" + ListNetworkSecurityGroupSecurityRulesSortOrderDesc ListNetworkSecurityGroupSecurityRulesSortOrderEnum = "DESC" +) + +var mappingListNetworkSecurityGroupSecurityRulesSortOrder = map[string]ListNetworkSecurityGroupSecurityRulesSortOrderEnum{ + "ASC": ListNetworkSecurityGroupSecurityRulesSortOrderAsc, + "DESC": ListNetworkSecurityGroupSecurityRulesSortOrderDesc, +} + +// GetListNetworkSecurityGroupSecurityRulesSortOrderEnumValues Enumerates the set of values for ListNetworkSecurityGroupSecurityRulesSortOrderEnum +func GetListNetworkSecurityGroupSecurityRulesSortOrderEnumValues() []ListNetworkSecurityGroupSecurityRulesSortOrderEnum { + values := make([]ListNetworkSecurityGroupSecurityRulesSortOrderEnum, 0) + for _, v := range mappingListNetworkSecurityGroupSecurityRulesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_network_security_group_vnics_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_network_security_group_vnics_request_response.go new file mode 100644 index 000000000..c7a32a4a8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_network_security_group_vnics_request_response.go @@ -0,0 +1,141 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListNetworkSecurityGroupVnicsRequest wrapper for the ListNetworkSecurityGroupVnics operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListNetworkSecurityGroupVnics.go.html to see an example of how to use ListNetworkSecurityGroupVnicsRequest. +type ListNetworkSecurityGroupVnicsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network security group. + NetworkSecurityGroupId *string `mandatory:"true" contributesTo:"path" name:"networkSecurityGroupId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. + SortBy ListNetworkSecurityGroupVnicsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListNetworkSecurityGroupVnicsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListNetworkSecurityGroupVnicsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListNetworkSecurityGroupVnicsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListNetworkSecurityGroupVnicsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListNetworkSecurityGroupVnicsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListNetworkSecurityGroupVnicsResponse wrapper for the ListNetworkSecurityGroupVnics operation +type ListNetworkSecurityGroupVnicsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []NetworkSecurityGroupVnic instances + Items []NetworkSecurityGroupVnic `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListNetworkSecurityGroupVnicsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListNetworkSecurityGroupVnicsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListNetworkSecurityGroupVnicsSortByEnum Enum with underlying type: string +type ListNetworkSecurityGroupVnicsSortByEnum string + +// Set of constants representing the allowable values for ListNetworkSecurityGroupVnicsSortByEnum +const ( + ListNetworkSecurityGroupVnicsSortByTimeassociated ListNetworkSecurityGroupVnicsSortByEnum = "TIMEASSOCIATED" +) + +var mappingListNetworkSecurityGroupVnicsSortBy = map[string]ListNetworkSecurityGroupVnicsSortByEnum{ + "TIMEASSOCIATED": ListNetworkSecurityGroupVnicsSortByTimeassociated, +} + +// GetListNetworkSecurityGroupVnicsSortByEnumValues Enumerates the set of values for ListNetworkSecurityGroupVnicsSortByEnum +func GetListNetworkSecurityGroupVnicsSortByEnumValues() []ListNetworkSecurityGroupVnicsSortByEnum { + values := make([]ListNetworkSecurityGroupVnicsSortByEnum, 0) + for _, v := range mappingListNetworkSecurityGroupVnicsSortBy { + values = append(values, v) + } + return values +} + +// ListNetworkSecurityGroupVnicsSortOrderEnum Enum with underlying type: string +type ListNetworkSecurityGroupVnicsSortOrderEnum string + +// Set of constants representing the allowable values for ListNetworkSecurityGroupVnicsSortOrderEnum +const ( + ListNetworkSecurityGroupVnicsSortOrderAsc ListNetworkSecurityGroupVnicsSortOrderEnum = "ASC" + ListNetworkSecurityGroupVnicsSortOrderDesc ListNetworkSecurityGroupVnicsSortOrderEnum = "DESC" +) + +var mappingListNetworkSecurityGroupVnicsSortOrder = map[string]ListNetworkSecurityGroupVnicsSortOrderEnum{ + "ASC": ListNetworkSecurityGroupVnicsSortOrderAsc, + "DESC": ListNetworkSecurityGroupVnicsSortOrderDesc, +} + +// GetListNetworkSecurityGroupVnicsSortOrderEnumValues Enumerates the set of values for ListNetworkSecurityGroupVnicsSortOrderEnum +func GetListNetworkSecurityGroupVnicsSortOrderEnumValues() []ListNetworkSecurityGroupVnicsSortOrderEnum { + values := make([]ListNetworkSecurityGroupVnicsSortOrderEnum, 0) + for _, v := range mappingListNetworkSecurityGroupVnicsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_network_security_groups_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_network_security_groups_request_response.go new file mode 100644 index 000000000..925fbbd67 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_network_security_groups_request_response.go @@ -0,0 +1,162 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListNetworkSecurityGroupsRequest wrapper for the ListNetworkSecurityGroups operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListNetworkSecurityGroups.go.html to see an example of how to use ListNetworkSecurityGroupsRequest. +type ListNetworkSecurityGroupsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"false" contributesTo:"query" name:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VLAN. + VlanId *string `mandatory:"false" contributesTo:"query" name:"vlanId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"false" contributesTo:"query" name:"vcnId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListNetworkSecurityGroupsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListNetworkSecurityGroupsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to return only resources that match the specified lifecycle + // state. The value is case insensitive. + LifecycleState NetworkSecurityGroupLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListNetworkSecurityGroupsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListNetworkSecurityGroupsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListNetworkSecurityGroupsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListNetworkSecurityGroupsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListNetworkSecurityGroupsResponse wrapper for the ListNetworkSecurityGroups operation +type ListNetworkSecurityGroupsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []NetworkSecurityGroup instances + Items []NetworkSecurityGroup `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListNetworkSecurityGroupsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListNetworkSecurityGroupsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListNetworkSecurityGroupsSortByEnum Enum with underlying type: string +type ListNetworkSecurityGroupsSortByEnum string + +// Set of constants representing the allowable values for ListNetworkSecurityGroupsSortByEnum +const ( + ListNetworkSecurityGroupsSortByTimecreated ListNetworkSecurityGroupsSortByEnum = "TIMECREATED" + ListNetworkSecurityGroupsSortByDisplayname ListNetworkSecurityGroupsSortByEnum = "DISPLAYNAME" +) + +var mappingListNetworkSecurityGroupsSortBy = map[string]ListNetworkSecurityGroupsSortByEnum{ + "TIMECREATED": ListNetworkSecurityGroupsSortByTimecreated, + "DISPLAYNAME": ListNetworkSecurityGroupsSortByDisplayname, +} + +// GetListNetworkSecurityGroupsSortByEnumValues Enumerates the set of values for ListNetworkSecurityGroupsSortByEnum +func GetListNetworkSecurityGroupsSortByEnumValues() []ListNetworkSecurityGroupsSortByEnum { + values := make([]ListNetworkSecurityGroupsSortByEnum, 0) + for _, v := range mappingListNetworkSecurityGroupsSortBy { + values = append(values, v) + } + return values +} + +// ListNetworkSecurityGroupsSortOrderEnum Enum with underlying type: string +type ListNetworkSecurityGroupsSortOrderEnum string + +// Set of constants representing the allowable values for ListNetworkSecurityGroupsSortOrderEnum +const ( + ListNetworkSecurityGroupsSortOrderAsc ListNetworkSecurityGroupsSortOrderEnum = "ASC" + ListNetworkSecurityGroupsSortOrderDesc ListNetworkSecurityGroupsSortOrderEnum = "DESC" +) + +var mappingListNetworkSecurityGroupsSortOrder = map[string]ListNetworkSecurityGroupsSortOrderEnum{ + "ASC": ListNetworkSecurityGroupsSortOrderAsc, + "DESC": ListNetworkSecurityGroupsSortOrderDesc, +} + +// GetListNetworkSecurityGroupsSortOrderEnumValues Enumerates the set of values for ListNetworkSecurityGroupsSortOrderEnum +func GetListNetworkSecurityGroupsSortOrderEnumValues() []ListNetworkSecurityGroupsSortOrderEnum { + values := make([]ListNetworkSecurityGroupsSortOrderEnum, 0) + for _, v := range mappingListNetworkSecurityGroupsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_private_ips_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_private_ips_request_response.go new file mode 100644 index 000000000..d00fa04e8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_private_ips_request_response.go @@ -0,0 +1,100 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListPrivateIpsRequest wrapper for the ListPrivateIps operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListPrivateIps.go.html to see an example of how to use ListPrivateIpsRequest. +type ListPrivateIpsRequest struct { + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // An IP address. This could be either IPv4 or IPv6, depending on the resource. + // Example: `10.0.3.3` + IpAddress *string `mandatory:"false" contributesTo:"query" name:"ipAddress"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the subnet. + SubnetId *string `mandatory:"false" contributesTo:"query" name:"subnetId"` + + // The OCID of the VNIC. + VnicId *string `mandatory:"false" contributesTo:"query" name:"vnicId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VLAN. + VlanId *string `mandatory:"false" contributesTo:"query" name:"vlanId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListPrivateIpsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListPrivateIpsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListPrivateIpsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListPrivateIpsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListPrivateIpsResponse wrapper for the ListPrivateIps operation +type ListPrivateIpsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []PrivateIp instances + Items []PrivateIp `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListPrivateIpsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListPrivateIpsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_public_ip_pools_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_public_ip_pools_request_response.go new file mode 100644 index 000000000..623bcf7f7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_public_ip_pools_request_response.go @@ -0,0 +1,155 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListPublicIpPoolsRequest wrapper for the ListPublicIpPools operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListPublicIpPools.go.html to see an example of how to use ListPublicIpPoolsRequest. +type ListPublicIpPoolsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // A filter to return only resources that match the given BYOIP CIDR block. + ByoipRangeId *string `mandatory:"false" contributesTo:"query" name:"byoipRangeId"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListPublicIpPoolsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListPublicIpPoolsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListPublicIpPoolsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListPublicIpPoolsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListPublicIpPoolsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListPublicIpPoolsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListPublicIpPoolsResponse wrapper for the ListPublicIpPools operation +type ListPublicIpPoolsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of PublicIpPoolCollection instances + PublicIpPoolCollection `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListPublicIpPoolsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListPublicIpPoolsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListPublicIpPoolsSortByEnum Enum with underlying type: string +type ListPublicIpPoolsSortByEnum string + +// Set of constants representing the allowable values for ListPublicIpPoolsSortByEnum +const ( + ListPublicIpPoolsSortByTimecreated ListPublicIpPoolsSortByEnum = "TIMECREATED" + ListPublicIpPoolsSortByDisplayname ListPublicIpPoolsSortByEnum = "DISPLAYNAME" +) + +var mappingListPublicIpPoolsSortBy = map[string]ListPublicIpPoolsSortByEnum{ + "TIMECREATED": ListPublicIpPoolsSortByTimecreated, + "DISPLAYNAME": ListPublicIpPoolsSortByDisplayname, +} + +// GetListPublicIpPoolsSortByEnumValues Enumerates the set of values for ListPublicIpPoolsSortByEnum +func GetListPublicIpPoolsSortByEnumValues() []ListPublicIpPoolsSortByEnum { + values := make([]ListPublicIpPoolsSortByEnum, 0) + for _, v := range mappingListPublicIpPoolsSortBy { + values = append(values, v) + } + return values +} + +// ListPublicIpPoolsSortOrderEnum Enum with underlying type: string +type ListPublicIpPoolsSortOrderEnum string + +// Set of constants representing the allowable values for ListPublicIpPoolsSortOrderEnum +const ( + ListPublicIpPoolsSortOrderAsc ListPublicIpPoolsSortOrderEnum = "ASC" + ListPublicIpPoolsSortOrderDesc ListPublicIpPoolsSortOrderEnum = "DESC" +) + +var mappingListPublicIpPoolsSortOrder = map[string]ListPublicIpPoolsSortOrderEnum{ + "ASC": ListPublicIpPoolsSortOrderAsc, + "DESC": ListPublicIpPoolsSortOrderDesc, +} + +// GetListPublicIpPoolsSortOrderEnumValues Enumerates the set of values for ListPublicIpPoolsSortOrderEnum +func GetListPublicIpPoolsSortOrderEnumValues() []ListPublicIpPoolsSortOrderEnum { + values := make([]ListPublicIpPoolsSortOrderEnum, 0) + for _, v := range mappingListPublicIpPoolsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_public_ips_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_public_ips_request_response.go new file mode 100644 index 000000000..3e51fdc1c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_public_ips_request_response.go @@ -0,0 +1,156 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListPublicIpsRequest wrapper for the ListPublicIps operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListPublicIps.go.html to see an example of how to use ListPublicIpsRequest. +type ListPublicIpsRequest struct { + + // Whether the public IP is regional or specific to a particular availability domain. + // * `REGION`: The public IP exists within a region and is assigned to a regional entity + // (such as a NatGateway), or can be assigned to a private IP + // in any availability domain in the region. Reserved public IPs have `scope` = `REGION`, as do + // ephemeral public IPs assigned to a regional entity. + // * `AVAILABILITY_DOMAIN`: The public IP exists within the availability domain of the entity + // it's assigned to, which is specified by the `availabilityDomain` property of the public IP object. + // Ephemeral public IPs that are assigned to private IPs have `scope` = `AVAILABILITY_DOMAIN`. + Scope ListPublicIpsScopeEnum `mandatory:"true" contributesTo:"query" name:"scope" omitEmpty:"true"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" contributesTo:"query" name:"availabilityDomain"` + + // A filter to return only public IPs that match given lifetime. + Lifetime ListPublicIpsLifetimeEnum `mandatory:"false" contributesTo:"query" name:"lifetime" omitEmpty:"true"` + + // A filter to return only resources that belong to the given public IP pool. + PublicIpPoolId *string `mandatory:"false" contributesTo:"query" name:"publicIpPoolId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListPublicIpsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListPublicIpsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListPublicIpsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListPublicIpsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListPublicIpsResponse wrapper for the ListPublicIps operation +type ListPublicIpsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []PublicIp instances + Items []PublicIp `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListPublicIpsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListPublicIpsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListPublicIpsScopeEnum Enum with underlying type: string +type ListPublicIpsScopeEnum string + +// Set of constants representing the allowable values for ListPublicIpsScopeEnum +const ( + ListPublicIpsScopeRegion ListPublicIpsScopeEnum = "REGION" + ListPublicIpsScopeAvailabilityDomain ListPublicIpsScopeEnum = "AVAILABILITY_DOMAIN" +) + +var mappingListPublicIpsScope = map[string]ListPublicIpsScopeEnum{ + "REGION": ListPublicIpsScopeRegion, + "AVAILABILITY_DOMAIN": ListPublicIpsScopeAvailabilityDomain, +} + +// GetListPublicIpsScopeEnumValues Enumerates the set of values for ListPublicIpsScopeEnum +func GetListPublicIpsScopeEnumValues() []ListPublicIpsScopeEnum { + values := make([]ListPublicIpsScopeEnum, 0) + for _, v := range mappingListPublicIpsScope { + values = append(values, v) + } + return values +} + +// ListPublicIpsLifetimeEnum Enum with underlying type: string +type ListPublicIpsLifetimeEnum string + +// Set of constants representing the allowable values for ListPublicIpsLifetimeEnum +const ( + ListPublicIpsLifetimeEphemeral ListPublicIpsLifetimeEnum = "EPHEMERAL" + ListPublicIpsLifetimeReserved ListPublicIpsLifetimeEnum = "RESERVED" +) + +var mappingListPublicIpsLifetime = map[string]ListPublicIpsLifetimeEnum{ + "EPHEMERAL": ListPublicIpsLifetimeEphemeral, + "RESERVED": ListPublicIpsLifetimeReserved, +} + +// GetListPublicIpsLifetimeEnumValues Enumerates the set of values for ListPublicIpsLifetimeEnum +func GetListPublicIpsLifetimeEnumValues() []ListPublicIpsLifetimeEnum { + values := make([]ListPublicIpsLifetimeEnum, 0) + for _, v := range mappingListPublicIpsLifetime { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_remote_peering_connections_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_remote_peering_connections_request_response.go new file mode 100644 index 000000000..a21847dde --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_remote_peering_connections_request_response.go @@ -0,0 +1,93 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListRemotePeeringConnectionsRequest wrapper for the ListRemotePeeringConnections operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListRemotePeeringConnections.go.html to see an example of how to use ListRemotePeeringConnectionsRequest. +type ListRemotePeeringConnectionsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"false" contributesTo:"query" name:"drgId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListRemotePeeringConnectionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListRemotePeeringConnectionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListRemotePeeringConnectionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListRemotePeeringConnectionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListRemotePeeringConnectionsResponse wrapper for the ListRemotePeeringConnections operation +type ListRemotePeeringConnectionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []RemotePeeringConnection instances + Items []RemotePeeringConnection `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListRemotePeeringConnectionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListRemotePeeringConnectionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_route_tables_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_route_tables_request_response.go new file mode 100644 index 000000000..0ee622fc3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_route_tables_request_response.go @@ -0,0 +1,159 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListRouteTablesRequest wrapper for the ListRouteTables operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListRouteTables.go.html to see an example of how to use ListRouteTablesRequest. +type ListRouteTablesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"false" contributesTo:"query" name:"vcnId"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListRouteTablesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListRouteTablesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle + // state. The state value is case-insensitive. + LifecycleState RouteTableLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListRouteTablesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListRouteTablesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListRouteTablesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListRouteTablesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListRouteTablesResponse wrapper for the ListRouteTables operation +type ListRouteTablesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []RouteTable instances + Items []RouteTable `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListRouteTablesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListRouteTablesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListRouteTablesSortByEnum Enum with underlying type: string +type ListRouteTablesSortByEnum string + +// Set of constants representing the allowable values for ListRouteTablesSortByEnum +const ( + ListRouteTablesSortByTimecreated ListRouteTablesSortByEnum = "TIMECREATED" + ListRouteTablesSortByDisplayname ListRouteTablesSortByEnum = "DISPLAYNAME" +) + +var mappingListRouteTablesSortBy = map[string]ListRouteTablesSortByEnum{ + "TIMECREATED": ListRouteTablesSortByTimecreated, + "DISPLAYNAME": ListRouteTablesSortByDisplayname, +} + +// GetListRouteTablesSortByEnumValues Enumerates the set of values for ListRouteTablesSortByEnum +func GetListRouteTablesSortByEnumValues() []ListRouteTablesSortByEnum { + values := make([]ListRouteTablesSortByEnum, 0) + for _, v := range mappingListRouteTablesSortBy { + values = append(values, v) + } + return values +} + +// ListRouteTablesSortOrderEnum Enum with underlying type: string +type ListRouteTablesSortOrderEnum string + +// Set of constants representing the allowable values for ListRouteTablesSortOrderEnum +const ( + ListRouteTablesSortOrderAsc ListRouteTablesSortOrderEnum = "ASC" + ListRouteTablesSortOrderDesc ListRouteTablesSortOrderEnum = "DESC" +) + +var mappingListRouteTablesSortOrder = map[string]ListRouteTablesSortOrderEnum{ + "ASC": ListRouteTablesSortOrderAsc, + "DESC": ListRouteTablesSortOrderDesc, +} + +// GetListRouteTablesSortOrderEnumValues Enumerates the set of values for ListRouteTablesSortOrderEnum +func GetListRouteTablesSortOrderEnumValues() []ListRouteTablesSortOrderEnum { + values := make([]ListRouteTablesSortOrderEnum, 0) + for _, v := range mappingListRouteTablesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_security_lists_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_security_lists_request_response.go new file mode 100644 index 000000000..3de041e20 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_security_lists_request_response.go @@ -0,0 +1,159 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListSecurityListsRequest wrapper for the ListSecurityLists operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListSecurityLists.go.html to see an example of how to use ListSecurityListsRequest. +type ListSecurityListsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"false" contributesTo:"query" name:"vcnId"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListSecurityListsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListSecurityListsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle + // state. The state value is case-insensitive. + LifecycleState SecurityListLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListSecurityListsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListSecurityListsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListSecurityListsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListSecurityListsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListSecurityListsResponse wrapper for the ListSecurityLists operation +type ListSecurityListsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []SecurityList instances + Items []SecurityList `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListSecurityListsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListSecurityListsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListSecurityListsSortByEnum Enum with underlying type: string +type ListSecurityListsSortByEnum string + +// Set of constants representing the allowable values for ListSecurityListsSortByEnum +const ( + ListSecurityListsSortByTimecreated ListSecurityListsSortByEnum = "TIMECREATED" + ListSecurityListsSortByDisplayname ListSecurityListsSortByEnum = "DISPLAYNAME" +) + +var mappingListSecurityListsSortBy = map[string]ListSecurityListsSortByEnum{ + "TIMECREATED": ListSecurityListsSortByTimecreated, + "DISPLAYNAME": ListSecurityListsSortByDisplayname, +} + +// GetListSecurityListsSortByEnumValues Enumerates the set of values for ListSecurityListsSortByEnum +func GetListSecurityListsSortByEnumValues() []ListSecurityListsSortByEnum { + values := make([]ListSecurityListsSortByEnum, 0) + for _, v := range mappingListSecurityListsSortBy { + values = append(values, v) + } + return values +} + +// ListSecurityListsSortOrderEnum Enum with underlying type: string +type ListSecurityListsSortOrderEnum string + +// Set of constants representing the allowable values for ListSecurityListsSortOrderEnum +const ( + ListSecurityListsSortOrderAsc ListSecurityListsSortOrderEnum = "ASC" + ListSecurityListsSortOrderDesc ListSecurityListsSortOrderEnum = "DESC" +) + +var mappingListSecurityListsSortOrder = map[string]ListSecurityListsSortOrderEnum{ + "ASC": ListSecurityListsSortOrderAsc, + "DESC": ListSecurityListsSortOrderDesc, +} + +// GetListSecurityListsSortOrderEnumValues Enumerates the set of values for ListSecurityListsSortOrderEnum +func GetListSecurityListsSortOrderEnumValues() []ListSecurityListsSortOrderEnum { + values := make([]ListSecurityListsSortOrderEnum, 0) + for _, v := range mappingListSecurityListsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_service_gateways_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_service_gateways_request_response.go new file mode 100644 index 000000000..7e939b016 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_service_gateways_request_response.go @@ -0,0 +1,156 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListServiceGatewaysRequest wrapper for the ListServiceGateways operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListServiceGateways.go.html to see an example of how to use ListServiceGatewaysRequest. +type ListServiceGatewaysRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"false" contributesTo:"query" name:"vcnId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListServiceGatewaysSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListServiceGatewaysSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to return only resources that match the given lifecycle + // state. The state value is case-insensitive. + LifecycleState ServiceGatewayLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListServiceGatewaysRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListServiceGatewaysRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListServiceGatewaysRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListServiceGatewaysRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListServiceGatewaysResponse wrapper for the ListServiceGateways operation +type ListServiceGatewaysResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []ServiceGateway instances + Items []ServiceGateway `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListServiceGatewaysResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListServiceGatewaysResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListServiceGatewaysSortByEnum Enum with underlying type: string +type ListServiceGatewaysSortByEnum string + +// Set of constants representing the allowable values for ListServiceGatewaysSortByEnum +const ( + ListServiceGatewaysSortByTimecreated ListServiceGatewaysSortByEnum = "TIMECREATED" + ListServiceGatewaysSortByDisplayname ListServiceGatewaysSortByEnum = "DISPLAYNAME" +) + +var mappingListServiceGatewaysSortBy = map[string]ListServiceGatewaysSortByEnum{ + "TIMECREATED": ListServiceGatewaysSortByTimecreated, + "DISPLAYNAME": ListServiceGatewaysSortByDisplayname, +} + +// GetListServiceGatewaysSortByEnumValues Enumerates the set of values for ListServiceGatewaysSortByEnum +func GetListServiceGatewaysSortByEnumValues() []ListServiceGatewaysSortByEnum { + values := make([]ListServiceGatewaysSortByEnum, 0) + for _, v := range mappingListServiceGatewaysSortBy { + values = append(values, v) + } + return values +} + +// ListServiceGatewaysSortOrderEnum Enum with underlying type: string +type ListServiceGatewaysSortOrderEnum string + +// Set of constants representing the allowable values for ListServiceGatewaysSortOrderEnum +const ( + ListServiceGatewaysSortOrderAsc ListServiceGatewaysSortOrderEnum = "ASC" + ListServiceGatewaysSortOrderDesc ListServiceGatewaysSortOrderEnum = "DESC" +) + +var mappingListServiceGatewaysSortOrder = map[string]ListServiceGatewaysSortOrderEnum{ + "ASC": ListServiceGatewaysSortOrderAsc, + "DESC": ListServiceGatewaysSortOrderDesc, +} + +// GetListServiceGatewaysSortOrderEnumValues Enumerates the set of values for ListServiceGatewaysSortOrderEnum +func GetListServiceGatewaysSortOrderEnumValues() []ListServiceGatewaysSortOrderEnum { + values := make([]ListServiceGatewaysSortOrderEnum, 0) + for _, v := range mappingListServiceGatewaysSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_services_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_services_request_response.go new file mode 100644 index 000000000..6d04c2042 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_services_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListServicesRequest wrapper for the ListServices operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListServices.go.html to see an example of how to use ListServicesRequest. +type ListServicesRequest struct { + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListServicesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListServicesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListServicesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListServicesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListServicesResponse wrapper for the ListServices operation +type ListServicesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Service instances + Items []Service `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListServicesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListServicesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_shapes_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_shapes_request_response.go new file mode 100644 index 000000000..fcc34b3f4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_shapes_request_response.go @@ -0,0 +1,97 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListShapesRequest wrapper for the ListShapes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListShapes.go.html to see an example of how to use ListShapesRequest. +type ListShapesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" contributesTo:"query" name:"availabilityDomain"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of an image. + ImageId *string `mandatory:"false" contributesTo:"query" name:"imageId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListShapesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListShapesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListShapesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListShapesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListShapesResponse wrapper for the ListShapes operation +type ListShapesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Shape instances + Items []Shape `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListShapesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListShapesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_subnets_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_subnets_request_response.go new file mode 100644 index 000000000..17ca7cd81 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_subnets_request_response.go @@ -0,0 +1,159 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListSubnetsRequest wrapper for the ListSubnets operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListSubnets.go.html to see an example of how to use ListSubnetsRequest. +type ListSubnetsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"false" contributesTo:"query" name:"vcnId"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListSubnetsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListSubnetsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle + // state. The state value is case-insensitive. + LifecycleState SubnetLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListSubnetsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListSubnetsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListSubnetsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListSubnetsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListSubnetsResponse wrapper for the ListSubnets operation +type ListSubnetsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Subnet instances + Items []Subnet `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListSubnetsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListSubnetsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListSubnetsSortByEnum Enum with underlying type: string +type ListSubnetsSortByEnum string + +// Set of constants representing the allowable values for ListSubnetsSortByEnum +const ( + ListSubnetsSortByTimecreated ListSubnetsSortByEnum = "TIMECREATED" + ListSubnetsSortByDisplayname ListSubnetsSortByEnum = "DISPLAYNAME" +) + +var mappingListSubnetsSortBy = map[string]ListSubnetsSortByEnum{ + "TIMECREATED": ListSubnetsSortByTimecreated, + "DISPLAYNAME": ListSubnetsSortByDisplayname, +} + +// GetListSubnetsSortByEnumValues Enumerates the set of values for ListSubnetsSortByEnum +func GetListSubnetsSortByEnumValues() []ListSubnetsSortByEnum { + values := make([]ListSubnetsSortByEnum, 0) + for _, v := range mappingListSubnetsSortBy { + values = append(values, v) + } + return values +} + +// ListSubnetsSortOrderEnum Enum with underlying type: string +type ListSubnetsSortOrderEnum string + +// Set of constants representing the allowable values for ListSubnetsSortOrderEnum +const ( + ListSubnetsSortOrderAsc ListSubnetsSortOrderEnum = "ASC" + ListSubnetsSortOrderDesc ListSubnetsSortOrderEnum = "DESC" +) + +var mappingListSubnetsSortOrder = map[string]ListSubnetsSortOrderEnum{ + "ASC": ListSubnetsSortOrderAsc, + "DESC": ListSubnetsSortOrderDesc, +} + +// GetListSubnetsSortOrderEnumValues Enumerates the set of values for ListSubnetsSortOrderEnum +func GetListSubnetsSortOrderEnumValues() []ListSubnetsSortOrderEnum { + values := make([]ListSubnetsSortOrderEnum, 0) + for _, v := range mappingListSubnetsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_vcns_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_vcns_request_response.go new file mode 100644 index 000000000..ba7f40cb6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_vcns_request_response.go @@ -0,0 +1,156 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListVcnsRequest wrapper for the ListVcns operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVcns.go.html to see an example of how to use ListVcnsRequest. +type ListVcnsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListVcnsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListVcnsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle + // state. The state value is case-insensitive. + LifecycleState VcnLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListVcnsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListVcnsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListVcnsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListVcnsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListVcnsResponse wrapper for the ListVcns operation +type ListVcnsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Vcn instances + Items []Vcn `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListVcnsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListVcnsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListVcnsSortByEnum Enum with underlying type: string +type ListVcnsSortByEnum string + +// Set of constants representing the allowable values for ListVcnsSortByEnum +const ( + ListVcnsSortByTimecreated ListVcnsSortByEnum = "TIMECREATED" + ListVcnsSortByDisplayname ListVcnsSortByEnum = "DISPLAYNAME" +) + +var mappingListVcnsSortBy = map[string]ListVcnsSortByEnum{ + "TIMECREATED": ListVcnsSortByTimecreated, + "DISPLAYNAME": ListVcnsSortByDisplayname, +} + +// GetListVcnsSortByEnumValues Enumerates the set of values for ListVcnsSortByEnum +func GetListVcnsSortByEnumValues() []ListVcnsSortByEnum { + values := make([]ListVcnsSortByEnum, 0) + for _, v := range mappingListVcnsSortBy { + values = append(values, v) + } + return values +} + +// ListVcnsSortOrderEnum Enum with underlying type: string +type ListVcnsSortOrderEnum string + +// Set of constants representing the allowable values for ListVcnsSortOrderEnum +const ( + ListVcnsSortOrderAsc ListVcnsSortOrderEnum = "ASC" + ListVcnsSortOrderDesc ListVcnsSortOrderEnum = "DESC" +) + +var mappingListVcnsSortOrder = map[string]ListVcnsSortOrderEnum{ + "ASC": ListVcnsSortOrderAsc, + "DESC": ListVcnsSortOrderDesc, +} + +// GetListVcnsSortOrderEnumValues Enumerates the set of values for ListVcnsSortOrderEnum +func GetListVcnsSortOrderEnumValues() []ListVcnsSortOrderEnum { + values := make([]ListVcnsSortOrderEnum, 0) + for _, v := range mappingListVcnsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_virtual_circuit_bandwidth_shapes_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_virtual_circuit_bandwidth_shapes_request_response.go new file mode 100644 index 000000000..d396b7fa1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_virtual_circuit_bandwidth_shapes_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListVirtualCircuitBandwidthShapesRequest wrapper for the ListVirtualCircuitBandwidthShapes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVirtualCircuitBandwidthShapes.go.html to see an example of how to use ListVirtualCircuitBandwidthShapesRequest. +type ListVirtualCircuitBandwidthShapesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListVirtualCircuitBandwidthShapesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListVirtualCircuitBandwidthShapesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListVirtualCircuitBandwidthShapesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListVirtualCircuitBandwidthShapesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListVirtualCircuitBandwidthShapesResponse wrapper for the ListVirtualCircuitBandwidthShapes operation +type ListVirtualCircuitBandwidthShapesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []VirtualCircuitBandwidthShape instances + Items []VirtualCircuitBandwidthShape `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListVirtualCircuitBandwidthShapesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListVirtualCircuitBandwidthShapesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_virtual_circuit_public_prefixes_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_virtual_circuit_public_prefixes_request_response.go new file mode 100644 index 000000000..58fae45d7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_virtual_circuit_public_prefixes_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListVirtualCircuitPublicPrefixesRequest wrapper for the ListVirtualCircuitPublicPrefixes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVirtualCircuitPublicPrefixes.go.html to see an example of how to use ListVirtualCircuitPublicPrefixesRequest. +type ListVirtualCircuitPublicPrefixesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the virtual circuit. + VirtualCircuitId *string `mandatory:"true" contributesTo:"path" name:"virtualCircuitId"` + + // A filter to only return resources that match the given verification + // state. + // The state value is case-insensitive. + VerificationState VirtualCircuitPublicPrefixVerificationStateEnum `mandatory:"false" contributesTo:"query" name:"verificationState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListVirtualCircuitPublicPrefixesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListVirtualCircuitPublicPrefixesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListVirtualCircuitPublicPrefixesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListVirtualCircuitPublicPrefixesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListVirtualCircuitPublicPrefixesResponse wrapper for the ListVirtualCircuitPublicPrefixes operation +type ListVirtualCircuitPublicPrefixesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []VirtualCircuitPublicPrefix instance + Items []VirtualCircuitPublicPrefix `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListVirtualCircuitPublicPrefixesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListVirtualCircuitPublicPrefixesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_virtual_circuits_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_virtual_circuits_request_response.go new file mode 100644 index 000000000..f4beff561 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_virtual_circuits_request_response.go @@ -0,0 +1,156 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListVirtualCircuitsRequest wrapper for the ListVirtualCircuits operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVirtualCircuits.go.html to see an example of how to use ListVirtualCircuitsRequest. +type ListVirtualCircuitsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListVirtualCircuitsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListVirtualCircuitsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to return only resources that match the specified lifecycle + // state. The value is case insensitive. + LifecycleState VirtualCircuitLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListVirtualCircuitsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListVirtualCircuitsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListVirtualCircuitsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListVirtualCircuitsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListVirtualCircuitsResponse wrapper for the ListVirtualCircuits operation +type ListVirtualCircuitsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []VirtualCircuit instances + Items []VirtualCircuit `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListVirtualCircuitsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListVirtualCircuitsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListVirtualCircuitsSortByEnum Enum with underlying type: string +type ListVirtualCircuitsSortByEnum string + +// Set of constants representing the allowable values for ListVirtualCircuitsSortByEnum +const ( + ListVirtualCircuitsSortByTimecreated ListVirtualCircuitsSortByEnum = "TIMECREATED" + ListVirtualCircuitsSortByDisplayname ListVirtualCircuitsSortByEnum = "DISPLAYNAME" +) + +var mappingListVirtualCircuitsSortBy = map[string]ListVirtualCircuitsSortByEnum{ + "TIMECREATED": ListVirtualCircuitsSortByTimecreated, + "DISPLAYNAME": ListVirtualCircuitsSortByDisplayname, +} + +// GetListVirtualCircuitsSortByEnumValues Enumerates the set of values for ListVirtualCircuitsSortByEnum +func GetListVirtualCircuitsSortByEnumValues() []ListVirtualCircuitsSortByEnum { + values := make([]ListVirtualCircuitsSortByEnum, 0) + for _, v := range mappingListVirtualCircuitsSortBy { + values = append(values, v) + } + return values +} + +// ListVirtualCircuitsSortOrderEnum Enum with underlying type: string +type ListVirtualCircuitsSortOrderEnum string + +// Set of constants representing the allowable values for ListVirtualCircuitsSortOrderEnum +const ( + ListVirtualCircuitsSortOrderAsc ListVirtualCircuitsSortOrderEnum = "ASC" + ListVirtualCircuitsSortOrderDesc ListVirtualCircuitsSortOrderEnum = "DESC" +) + +var mappingListVirtualCircuitsSortOrder = map[string]ListVirtualCircuitsSortOrderEnum{ + "ASC": ListVirtualCircuitsSortOrderAsc, + "DESC": ListVirtualCircuitsSortOrderDesc, +} + +// GetListVirtualCircuitsSortOrderEnumValues Enumerates the set of values for ListVirtualCircuitsSortOrderEnum +func GetListVirtualCircuitsSortOrderEnumValues() []ListVirtualCircuitsSortOrderEnum { + values := make([]ListVirtualCircuitsSortOrderEnum, 0) + for _, v := range mappingListVirtualCircuitsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_vlans_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_vlans_request_response.go new file mode 100644 index 000000000..a8fdee064 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_vlans_request_response.go @@ -0,0 +1,159 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListVlansRequest wrapper for the ListVlans operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVlans.go.html to see an example of how to use ListVlansRequest. +type ListVlansRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"false" contributesTo:"query" name:"vcnId"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListVlansSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListVlansSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A filter to only return resources that match the given lifecycle + // state. The state value is case-insensitive. + LifecycleState VlanLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListVlansRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListVlansRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListVlansRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListVlansRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListVlansResponse wrapper for the ListVlans operation +type ListVlansResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Vlan instances + Items []Vlan `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListVlansResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListVlansResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListVlansSortByEnum Enum with underlying type: string +type ListVlansSortByEnum string + +// Set of constants representing the allowable values for ListVlansSortByEnum +const ( + ListVlansSortByTimecreated ListVlansSortByEnum = "TIMECREATED" + ListVlansSortByDisplayname ListVlansSortByEnum = "DISPLAYNAME" +) + +var mappingListVlansSortBy = map[string]ListVlansSortByEnum{ + "TIMECREATED": ListVlansSortByTimecreated, + "DISPLAYNAME": ListVlansSortByDisplayname, +} + +// GetListVlansSortByEnumValues Enumerates the set of values for ListVlansSortByEnum +func GetListVlansSortByEnumValues() []ListVlansSortByEnum { + values := make([]ListVlansSortByEnum, 0) + for _, v := range mappingListVlansSortBy { + values = append(values, v) + } + return values +} + +// ListVlansSortOrderEnum Enum with underlying type: string +type ListVlansSortOrderEnum string + +// Set of constants representing the allowable values for ListVlansSortOrderEnum +const ( + ListVlansSortOrderAsc ListVlansSortOrderEnum = "ASC" + ListVlansSortOrderDesc ListVlansSortOrderEnum = "DESC" +) + +var mappingListVlansSortOrder = map[string]ListVlansSortOrderEnum{ + "ASC": ListVlansSortOrderAsc, + "DESC": ListVlansSortOrderDesc, +} + +// GetListVlansSortOrderEnumValues Enumerates the set of values for ListVlansSortOrderEnum +func GetListVlansSortOrderEnumValues() []ListVlansSortOrderEnum { + values := make([]ListVlansSortOrderEnum, 0) + for _, v := range mappingListVlansSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_vnic_attachments_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_vnic_attachments_request_response.go new file mode 100644 index 000000000..6cb599a8e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_vnic_attachments_request_response.go @@ -0,0 +1,100 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListVnicAttachmentsRequest wrapper for the ListVnicAttachments operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVnicAttachments.go.html to see an example of how to use ListVnicAttachmentsRequest. +type ListVnicAttachmentsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" contributesTo:"query" name:"availabilityDomain"` + + // The OCID of the instance. + InstanceId *string `mandatory:"false" contributesTo:"query" name:"instanceId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The OCID of the VNIC. + VnicId *string `mandatory:"false" contributesTo:"query" name:"vnicId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListVnicAttachmentsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListVnicAttachmentsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListVnicAttachmentsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListVnicAttachmentsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListVnicAttachmentsResponse wrapper for the ListVnicAttachments operation +type ListVnicAttachmentsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []VnicAttachment instances + Items []VnicAttachment `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListVnicAttachmentsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListVnicAttachmentsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_attachments_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_attachments_request_response.go new file mode 100644 index 000000000..468af9680 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_attachments_request_response.go @@ -0,0 +1,100 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListVolumeAttachmentsRequest wrapper for the ListVolumeAttachments operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVolumeAttachments.go.html to see an example of how to use ListVolumeAttachmentsRequest. +type ListVolumeAttachmentsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" contributesTo:"query" name:"availabilityDomain"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The OCID of the instance. + InstanceId *string `mandatory:"false" contributesTo:"query" name:"instanceId"` + + // The OCID of the volume. + VolumeId *string `mandatory:"false" contributesTo:"query" name:"volumeId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListVolumeAttachmentsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListVolumeAttachmentsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListVolumeAttachmentsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListVolumeAttachmentsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListVolumeAttachmentsResponse wrapper for the ListVolumeAttachments operation +type ListVolumeAttachmentsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []VolumeAttachment instances + Items []VolumeAttachment `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListVolumeAttachmentsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListVolumeAttachmentsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_backup_policies_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_backup_policies_request_response.go new file mode 100644 index 000000000..225a0bad1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_backup_policies_request_response.go @@ -0,0 +1,91 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListVolumeBackupPoliciesRequest wrapper for the ListVolumeBackupPolicies operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVolumeBackupPolicies.go.html to see an example of how to use ListVolumeBackupPoliciesRequest. +type ListVolumeBackupPoliciesRequest struct { + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The OCID of the compartment. + // If no compartment is specified, the Oracle defined backup policies are listed. + CompartmentId *string `mandatory:"false" contributesTo:"query" name:"compartmentId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListVolumeBackupPoliciesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListVolumeBackupPoliciesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListVolumeBackupPoliciesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListVolumeBackupPoliciesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListVolumeBackupPoliciesResponse wrapper for the ListVolumeBackupPolicies operation +type ListVolumeBackupPoliciesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []VolumeBackupPolicy instances + Items []VolumeBackupPolicy `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListVolumeBackupPoliciesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListVolumeBackupPoliciesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_backups_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_backups_request_response.go new file mode 100644 index 000000000..03539894b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_backups_request_response.go @@ -0,0 +1,162 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListVolumeBackupsRequest wrapper for the ListVolumeBackups operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVolumeBackups.go.html to see an example of how to use ListVolumeBackupsRequest. +type ListVolumeBackupsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID of the volume. + VolumeId *string `mandatory:"false" contributesTo:"query" name:"volumeId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // A filter to return only resources that originated from the given source volume backup. + SourceVolumeBackupId *string `mandatory:"false" contributesTo:"query" name:"sourceVolumeBackupId"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListVolumeBackupsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListVolumeBackupsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state + // value is case-insensitive. + LifecycleState VolumeBackupLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListVolumeBackupsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListVolumeBackupsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListVolumeBackupsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListVolumeBackupsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListVolumeBackupsResponse wrapper for the ListVolumeBackups operation +type ListVolumeBackupsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []VolumeBackup instances + Items []VolumeBackup `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListVolumeBackupsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListVolumeBackupsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListVolumeBackupsSortByEnum Enum with underlying type: string +type ListVolumeBackupsSortByEnum string + +// Set of constants representing the allowable values for ListVolumeBackupsSortByEnum +const ( + ListVolumeBackupsSortByTimecreated ListVolumeBackupsSortByEnum = "TIMECREATED" + ListVolumeBackupsSortByDisplayname ListVolumeBackupsSortByEnum = "DISPLAYNAME" +) + +var mappingListVolumeBackupsSortBy = map[string]ListVolumeBackupsSortByEnum{ + "TIMECREATED": ListVolumeBackupsSortByTimecreated, + "DISPLAYNAME": ListVolumeBackupsSortByDisplayname, +} + +// GetListVolumeBackupsSortByEnumValues Enumerates the set of values for ListVolumeBackupsSortByEnum +func GetListVolumeBackupsSortByEnumValues() []ListVolumeBackupsSortByEnum { + values := make([]ListVolumeBackupsSortByEnum, 0) + for _, v := range mappingListVolumeBackupsSortBy { + values = append(values, v) + } + return values +} + +// ListVolumeBackupsSortOrderEnum Enum with underlying type: string +type ListVolumeBackupsSortOrderEnum string + +// Set of constants representing the allowable values for ListVolumeBackupsSortOrderEnum +const ( + ListVolumeBackupsSortOrderAsc ListVolumeBackupsSortOrderEnum = "ASC" + ListVolumeBackupsSortOrderDesc ListVolumeBackupsSortOrderEnum = "DESC" +) + +var mappingListVolumeBackupsSortOrder = map[string]ListVolumeBackupsSortOrderEnum{ + "ASC": ListVolumeBackupsSortOrderAsc, + "DESC": ListVolumeBackupsSortOrderDesc, +} + +// GetListVolumeBackupsSortOrderEnumValues Enumerates the set of values for ListVolumeBackupsSortOrderEnum +func GetListVolumeBackupsSortOrderEnumValues() []ListVolumeBackupsSortOrderEnum { + values := make([]ListVolumeBackupsSortOrderEnum, 0) + for _, v := range mappingListVolumeBackupsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_group_backups_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_group_backups_request_response.go new file mode 100644 index 000000000..dde977119 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_group_backups_request_response.go @@ -0,0 +1,155 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListVolumeGroupBackupsRequest wrapper for the ListVolumeGroupBackups operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVolumeGroupBackups.go.html to see an example of how to use ListVolumeGroupBackupsRequest. +type ListVolumeGroupBackupsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID of the volume group. + VolumeGroupId *string `mandatory:"false" contributesTo:"query" name:"volumeGroupId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListVolumeGroupBackupsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListVolumeGroupBackupsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListVolumeGroupBackupsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListVolumeGroupBackupsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListVolumeGroupBackupsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListVolumeGroupBackupsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListVolumeGroupBackupsResponse wrapper for the ListVolumeGroupBackups operation +type ListVolumeGroupBackupsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []VolumeGroupBackup instances + Items []VolumeGroupBackup `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListVolumeGroupBackupsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListVolumeGroupBackupsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListVolumeGroupBackupsSortByEnum Enum with underlying type: string +type ListVolumeGroupBackupsSortByEnum string + +// Set of constants representing the allowable values for ListVolumeGroupBackupsSortByEnum +const ( + ListVolumeGroupBackupsSortByTimecreated ListVolumeGroupBackupsSortByEnum = "TIMECREATED" + ListVolumeGroupBackupsSortByDisplayname ListVolumeGroupBackupsSortByEnum = "DISPLAYNAME" +) + +var mappingListVolumeGroupBackupsSortBy = map[string]ListVolumeGroupBackupsSortByEnum{ + "TIMECREATED": ListVolumeGroupBackupsSortByTimecreated, + "DISPLAYNAME": ListVolumeGroupBackupsSortByDisplayname, +} + +// GetListVolumeGroupBackupsSortByEnumValues Enumerates the set of values for ListVolumeGroupBackupsSortByEnum +func GetListVolumeGroupBackupsSortByEnumValues() []ListVolumeGroupBackupsSortByEnum { + values := make([]ListVolumeGroupBackupsSortByEnum, 0) + for _, v := range mappingListVolumeGroupBackupsSortBy { + values = append(values, v) + } + return values +} + +// ListVolumeGroupBackupsSortOrderEnum Enum with underlying type: string +type ListVolumeGroupBackupsSortOrderEnum string + +// Set of constants representing the allowable values for ListVolumeGroupBackupsSortOrderEnum +const ( + ListVolumeGroupBackupsSortOrderAsc ListVolumeGroupBackupsSortOrderEnum = "ASC" + ListVolumeGroupBackupsSortOrderDesc ListVolumeGroupBackupsSortOrderEnum = "DESC" +) + +var mappingListVolumeGroupBackupsSortOrder = map[string]ListVolumeGroupBackupsSortOrderEnum{ + "ASC": ListVolumeGroupBackupsSortOrderAsc, + "DESC": ListVolumeGroupBackupsSortOrderDesc, +} + +// GetListVolumeGroupBackupsSortOrderEnumValues Enumerates the set of values for ListVolumeGroupBackupsSortOrderEnum +func GetListVolumeGroupBackupsSortOrderEnumValues() []ListVolumeGroupBackupsSortOrderEnum { + values := make([]ListVolumeGroupBackupsSortOrderEnum, 0) + for _, v := range mappingListVolumeGroupBackupsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_groups_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_groups_request_response.go new file mode 100644 index 000000000..8a5be2af8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volume_groups_request_response.go @@ -0,0 +1,160 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListVolumeGroupsRequest wrapper for the ListVolumeGroups operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVolumeGroups.go.html to see an example of how to use ListVolumeGroupsRequest. +type ListVolumeGroupsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" contributesTo:"query" name:"availabilityDomain"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListVolumeGroupsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListVolumeGroupsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle + // state. The state value is case-insensitive. + LifecycleState VolumeGroupLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListVolumeGroupsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListVolumeGroupsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListVolumeGroupsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListVolumeGroupsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListVolumeGroupsResponse wrapper for the ListVolumeGroups operation +type ListVolumeGroupsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []VolumeGroup instances + Items []VolumeGroup `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListVolumeGroupsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListVolumeGroupsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListVolumeGroupsSortByEnum Enum with underlying type: string +type ListVolumeGroupsSortByEnum string + +// Set of constants representing the allowable values for ListVolumeGroupsSortByEnum +const ( + ListVolumeGroupsSortByTimecreated ListVolumeGroupsSortByEnum = "TIMECREATED" + ListVolumeGroupsSortByDisplayname ListVolumeGroupsSortByEnum = "DISPLAYNAME" +) + +var mappingListVolumeGroupsSortBy = map[string]ListVolumeGroupsSortByEnum{ + "TIMECREATED": ListVolumeGroupsSortByTimecreated, + "DISPLAYNAME": ListVolumeGroupsSortByDisplayname, +} + +// GetListVolumeGroupsSortByEnumValues Enumerates the set of values for ListVolumeGroupsSortByEnum +func GetListVolumeGroupsSortByEnumValues() []ListVolumeGroupsSortByEnum { + values := make([]ListVolumeGroupsSortByEnum, 0) + for _, v := range mappingListVolumeGroupsSortBy { + values = append(values, v) + } + return values +} + +// ListVolumeGroupsSortOrderEnum Enum with underlying type: string +type ListVolumeGroupsSortOrderEnum string + +// Set of constants representing the allowable values for ListVolumeGroupsSortOrderEnum +const ( + ListVolumeGroupsSortOrderAsc ListVolumeGroupsSortOrderEnum = "ASC" + ListVolumeGroupsSortOrderDesc ListVolumeGroupsSortOrderEnum = "DESC" +) + +var mappingListVolumeGroupsSortOrder = map[string]ListVolumeGroupsSortOrderEnum{ + "ASC": ListVolumeGroupsSortOrderAsc, + "DESC": ListVolumeGroupsSortOrderDesc, +} + +// GetListVolumeGroupsSortOrderEnumValues Enumerates the set of values for ListVolumeGroupsSortOrderEnum +func GetListVolumeGroupsSortOrderEnumValues() []ListVolumeGroupsSortOrderEnum { + values := make([]ListVolumeGroupsSortOrderEnum, 0) + for _, v := range mappingListVolumeGroupsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volumes_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volumes_request_response.go new file mode 100644 index 000000000..1489cf52f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/list_volumes_request_response.go @@ -0,0 +1,163 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListVolumesRequest wrapper for the ListVolumes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ListVolumes.go.html to see an example of how to use ListVolumesRequest. +type ListVolumesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The name of the availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" contributesTo:"query" name:"availabilityDomain"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + // Example: `50` + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" + // call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // A filter to return only resources that match the given display name exactly. + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by availability domain if the scope of the resource type is within a + // single availability domain. If you call one of these "List" operations without specifying + // an availability domain, the resources are grouped by availability domain, then sorted. + SortBy ListVolumesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The DISPLAYNAME sort order + // is case sensitive. + SortOrder ListVolumesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // The OCID of the volume group. + VolumeGroupId *string `mandatory:"false" contributesTo:"query" name:"volumeGroupId"` + + // A filter to only return resources that match the given lifecycle state. The state + // value is case-insensitive. + LifecycleState VolumeLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListVolumesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListVolumesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListVolumesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListVolumesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListVolumesResponse wrapper for the ListVolumes operation +type ListVolumesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Volume instances + Items []Volume `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages + // of results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListVolumesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListVolumesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListVolumesSortByEnum Enum with underlying type: string +type ListVolumesSortByEnum string + +// Set of constants representing the allowable values for ListVolumesSortByEnum +const ( + ListVolumesSortByTimecreated ListVolumesSortByEnum = "TIMECREATED" + ListVolumesSortByDisplayname ListVolumesSortByEnum = "DISPLAYNAME" +) + +var mappingListVolumesSortBy = map[string]ListVolumesSortByEnum{ + "TIMECREATED": ListVolumesSortByTimecreated, + "DISPLAYNAME": ListVolumesSortByDisplayname, +} + +// GetListVolumesSortByEnumValues Enumerates the set of values for ListVolumesSortByEnum +func GetListVolumesSortByEnumValues() []ListVolumesSortByEnum { + values := make([]ListVolumesSortByEnum, 0) + for _, v := range mappingListVolumesSortBy { + values = append(values, v) + } + return values +} + +// ListVolumesSortOrderEnum Enum with underlying type: string +type ListVolumesSortOrderEnum string + +// Set of constants representing the allowable values for ListVolumesSortOrderEnum +const ( + ListVolumesSortOrderAsc ListVolumesSortOrderEnum = "ASC" + ListVolumesSortOrderDesc ListVolumesSortOrderEnum = "DESC" +) + +var mappingListVolumesSortOrder = map[string]ListVolumesSortOrderEnum{ + "ASC": ListVolumesSortOrderAsc, + "DESC": ListVolumesSortOrderDesc, +} + +// GetListVolumesSortOrderEnumValues Enumerates the set of values for ListVolumesSortOrderEnum +func GetListVolumesSortOrderEnumValues() []ListVolumesSortOrderEnum { + values := make([]ListVolumesSortOrderEnum, 0) + for _, v := range mappingListVolumesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/local_peering_gateway.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/local_peering_gateway.go new file mode 100644 index 000000000..e52c34840 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/local_peering_gateway.go @@ -0,0 +1,152 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// LocalPeeringGateway A local peering gateway (LPG) is an object on a VCN that lets that VCN peer +// with another VCN in the same region. *Peering* means that the two VCNs can +// communicate using private IP addresses, but without the traffic traversing the +// internet or routing through your on-premises network. For more information, +// see VCN Peering (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/VCNpeering.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type LocalPeeringGateway struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the LPG. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The LPG's Oracle ID (OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"true" json:"id"` + + // Whether the VCN at the other end of the peering is in a different tenancy. + // Example: `false` + IsCrossTenancyPeering *bool `mandatory:"true" json:"isCrossTenancyPeering"` + + // The LPG's current lifecycle state. + LifecycleState LocalPeeringGatewayLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // Whether the LPG is peered with another LPG. `NEW` means the LPG has not yet been + // peered. `PENDING` means the peering is being established. `REVOKED` means the + // LPG at the other end of the peering has been deleted. + PeeringStatus LocalPeeringGatewayPeeringStatusEnum `mandatory:"true" json:"peeringStatus"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the peered LPG. + PeerId *string `mandatory:"true" json:"peerId"` + + // The date and time the LPG was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN that uses the LPG. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The smallest aggregate CIDR that contains all the CIDR routes advertised by the VCN + // at the other end of the peering from this LPG. See `peerAdvertisedCidrDetails` for + // the individual CIDRs. The value is `null` if the LPG is not peered. + // Example: `192.168.0.0/16`, or if aggregated with `172.16.0.0/24` then `128.0.0.0/1` + PeerAdvertisedCidr *string `mandatory:"false" json:"peerAdvertisedCidr"` + + // The specific ranges of IP addresses available on or via the VCN at the other + // end of the peering from this LPG. The value is `null` if the LPG is not peered. + // You can use these as destination CIDRs for route rules to route a subnet's + // traffic to this LPG. + // Example: [`192.168.0.0/16`, `172.16.0.0/24`] + PeerAdvertisedCidrDetails []string `mandatory:"false" json:"peerAdvertisedCidrDetails"` + + // Additional information regarding the peering status, if applicable. + PeeringStatusDetails *string `mandatory:"false" json:"peeringStatusDetails"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route table the LPG is using. + // For information about why you would associate a route table with an LPG, see + // Transit Routing: Access to Multiple VCNs in Same Region (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitrouting.htm). + RouteTableId *string `mandatory:"false" json:"routeTableId"` +} + +func (m LocalPeeringGateway) String() string { + return common.PointerString(m) +} + +// LocalPeeringGatewayLifecycleStateEnum Enum with underlying type: string +type LocalPeeringGatewayLifecycleStateEnum string + +// Set of constants representing the allowable values for LocalPeeringGatewayLifecycleStateEnum +const ( + LocalPeeringGatewayLifecycleStateProvisioning LocalPeeringGatewayLifecycleStateEnum = "PROVISIONING" + LocalPeeringGatewayLifecycleStateAvailable LocalPeeringGatewayLifecycleStateEnum = "AVAILABLE" + LocalPeeringGatewayLifecycleStateTerminating LocalPeeringGatewayLifecycleStateEnum = "TERMINATING" + LocalPeeringGatewayLifecycleStateTerminated LocalPeeringGatewayLifecycleStateEnum = "TERMINATED" +) + +var mappingLocalPeeringGatewayLifecycleState = map[string]LocalPeeringGatewayLifecycleStateEnum{ + "PROVISIONING": LocalPeeringGatewayLifecycleStateProvisioning, + "AVAILABLE": LocalPeeringGatewayLifecycleStateAvailable, + "TERMINATING": LocalPeeringGatewayLifecycleStateTerminating, + "TERMINATED": LocalPeeringGatewayLifecycleStateTerminated, +} + +// GetLocalPeeringGatewayLifecycleStateEnumValues Enumerates the set of values for LocalPeeringGatewayLifecycleStateEnum +func GetLocalPeeringGatewayLifecycleStateEnumValues() []LocalPeeringGatewayLifecycleStateEnum { + values := make([]LocalPeeringGatewayLifecycleStateEnum, 0) + for _, v := range mappingLocalPeeringGatewayLifecycleState { + values = append(values, v) + } + return values +} + +// LocalPeeringGatewayPeeringStatusEnum Enum with underlying type: string +type LocalPeeringGatewayPeeringStatusEnum string + +// Set of constants representing the allowable values for LocalPeeringGatewayPeeringStatusEnum +const ( + LocalPeeringGatewayPeeringStatusInvalid LocalPeeringGatewayPeeringStatusEnum = "INVALID" + LocalPeeringGatewayPeeringStatusNew LocalPeeringGatewayPeeringStatusEnum = "NEW" + LocalPeeringGatewayPeeringStatusPeered LocalPeeringGatewayPeeringStatusEnum = "PEERED" + LocalPeeringGatewayPeeringStatusPending LocalPeeringGatewayPeeringStatusEnum = "PENDING" + LocalPeeringGatewayPeeringStatusRevoked LocalPeeringGatewayPeeringStatusEnum = "REVOKED" +) + +var mappingLocalPeeringGatewayPeeringStatus = map[string]LocalPeeringGatewayPeeringStatusEnum{ + "INVALID": LocalPeeringGatewayPeeringStatusInvalid, + "NEW": LocalPeeringGatewayPeeringStatusNew, + "PEERED": LocalPeeringGatewayPeeringStatusPeered, + "PENDING": LocalPeeringGatewayPeeringStatusPending, + "REVOKED": LocalPeeringGatewayPeeringStatusRevoked, +} + +// GetLocalPeeringGatewayPeeringStatusEnumValues Enumerates the set of values for LocalPeeringGatewayPeeringStatusEnum +func GetLocalPeeringGatewayPeeringStatusEnumValues() []LocalPeeringGatewayPeeringStatusEnum { + values := make([]LocalPeeringGatewayPeeringStatusEnum, 0) + for _, v := range mappingLocalPeeringGatewayPeeringStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_encryption_cipher.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_encryption_cipher.go new file mode 100644 index 000000000..64f855f9d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_encryption_cipher.go @@ -0,0 +1,41 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +// MacsecEncryptionCipherEnum Enum with underlying type: string +type MacsecEncryptionCipherEnum string + +// Set of constants representing the allowable values for MacsecEncryptionCipherEnum +const ( + MacsecEncryptionCipherAes128Gcm MacsecEncryptionCipherEnum = "AES128_GCM" + MacsecEncryptionCipherAes128GcmXpn MacsecEncryptionCipherEnum = "AES128_GCM_XPN" + MacsecEncryptionCipherAes256Gcm MacsecEncryptionCipherEnum = "AES256_GCM" + MacsecEncryptionCipherAes256GcmXpn MacsecEncryptionCipherEnum = "AES256_GCM_XPN" +) + +var mappingMacsecEncryptionCipher = map[string]MacsecEncryptionCipherEnum{ + "AES128_GCM": MacsecEncryptionCipherAes128Gcm, + "AES128_GCM_XPN": MacsecEncryptionCipherAes128GcmXpn, + "AES256_GCM": MacsecEncryptionCipherAes256Gcm, + "AES256_GCM_XPN": MacsecEncryptionCipherAes256GcmXpn, +} + +// GetMacsecEncryptionCipherEnumValues Enumerates the set of values for MacsecEncryptionCipherEnum +func GetMacsecEncryptionCipherEnumValues() []MacsecEncryptionCipherEnum { + values := make([]MacsecEncryptionCipherEnum, 0) + for _, v := range mappingMacsecEncryptionCipher { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_key.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_key.go new file mode 100644 index 000000000..28070f9fb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_key.go @@ -0,0 +1,38 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// MacsecKey An object defining the Secrets-in-Vault OCIDs representing the MACsec key. +type MacsecKey struct { + + // Secret OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) containing the Connectivity association Key Name (CKN) of this MACsec key. + ConnectivityAssociationNameSecretId *string `mandatory:"true" json:"connectivityAssociationNameSecretId"` + + // Secret OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) containing the Connectivity Association Key (CAK) of this MACsec key. + ConnectivityAssociationKeySecretId *string `mandatory:"true" json:"connectivityAssociationKeySecretId"` + + // The secret version of the connectivity association name secret in Vault. + ConnectivityAssociationNameSecretVersion *int64 `mandatory:"false" json:"connectivityAssociationNameSecretVersion"` + + // The secret version of the `connectivityAssociationKey` secret in Vault. + ConnectivityAssociationKeySecretVersion *int64 `mandatory:"false" json:"connectivityAssociationKeySecretVersion"` +} + +func (m MacsecKey) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_properties.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_properties.go new file mode 100644 index 000000000..52cd5a3bd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_properties.go @@ -0,0 +1,34 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// MacsecProperties Properties used for MACsec (if capable). +type MacsecProperties struct { + + // Indicates whether or not MACsec is enabled. + State MacsecStateEnum `mandatory:"true" json:"state"` + + PrimaryKey *MacsecKey `mandatory:"false" json:"primaryKey"` + + // Type of encryption cipher suite to use for the MACsec connection. + EncryptionCipher MacsecEncryptionCipherEnum `mandatory:"false" json:"encryptionCipher,omitempty"` +} + +func (m MacsecProperties) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_state.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_state.go new file mode 100644 index 000000000..7658a609a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/macsec_state.go @@ -0,0 +1,37 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +// MacsecStateEnum Enum with underlying type: string +type MacsecStateEnum string + +// Set of constants representing the allowable values for MacsecStateEnum +const ( + MacsecStateEnabled MacsecStateEnum = "ENABLED" + MacsecStateDisabled MacsecStateEnum = "DISABLED" +) + +var mappingMacsecState = map[string]MacsecStateEnum{ + "ENABLED": MacsecStateEnabled, + "DISABLED": MacsecStateDisabled, +} + +// GetMacsecStateEnumValues Enumerates the set of values for MacsecStateEnum +func GetMacsecStateEnumValues() []MacsecStateEnum { + values := make([]MacsecStateEnum, 0) + for _, v := range mappingMacsecState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/measured_boot_entry.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/measured_boot_entry.go new file mode 100644 index 000000000..0d6d06388 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/measured_boot_entry.go @@ -0,0 +1,36 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// MeasuredBootEntry One Trusted Platform Module (TPM) Platform Configuration Register (PCR) entry. The entry might be measured during boot, +// or specified in a policy. +type MeasuredBootEntry struct { + + // The index of the policy. + PcrIndex *string `mandatory:"false" json:"pcrIndex"` + + // The hashed PCR value. + Value *string `mandatory:"false" json:"value"` + + // The type of algorithm used to calculate the hash. + HashAlgorithm *string `mandatory:"false" json:"hashAlgorithm"` +} + +func (m MeasuredBootEntry) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/measured_boot_report.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/measured_boot_report.go new file mode 100644 index 000000000..207db7962 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/measured_boot_report.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// MeasuredBootReport The measured boot report for a shielded instance. +type MeasuredBootReport struct { + + // Whether the verification succeeded, and the new values match the expected values. + IsPolicyVerificationSuccessful *bool `mandatory:"true" json:"isPolicyVerificationSuccessful"` + + Measurements *MeasuredBootReportMeasurements `mandatory:"false" json:"measurements"` +} + +func (m MeasuredBootReport) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/measured_boot_report_measurements.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/measured_boot_report_measurements.go new file mode 100644 index 000000000..c977cdeb2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/measured_boot_report_measurements.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// MeasuredBootReportMeasurements A list of Trusted Platform Module (TPM) Platform Configuration Register (PCR) entries. +type MeasuredBootReportMeasurements struct { + + // The list of expected PCR entries to use during verification. + Policy []MeasuredBootEntry `mandatory:"false" json:"policy"` + + // The list of actual PCR entries measured during boot. + Actual []MeasuredBootEntry `mandatory:"false" json:"actual"` +} + +func (m MeasuredBootReportMeasurements) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/modify_vcn_cidr_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/modify_vcn_cidr_details.go new file mode 100644 index 000000000..eb6acd650 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/modify_vcn_cidr_details.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ModifyVcnCidrDetails Details for updating a CIDR block. +type ModifyVcnCidrDetails struct { + + // The CIDR IP address to update. + OriginalCidrBlock *string `mandatory:"true" json:"originalCidrBlock"` + + // The new CIDR IP address. + NewCidrBlock *string `mandatory:"true" json:"newCidrBlock"` +} + +func (m ModifyVcnCidrDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/modify_vcn_cidr_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/modify_vcn_cidr_request_response.go new file mode 100644 index 000000000..fb292473e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/modify_vcn_cidr_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ModifyVcnCidrRequest wrapper for the ModifyVcnCidr operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ModifyVcnCidr.go.html to see an example of how to use ModifyVcnCidrRequest. +type ModifyVcnCidrRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"true" contributesTo:"path" name:"vcnId"` + + // Details object for updating a VCN CIDR. + ModifyVcnCidrDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ModifyVcnCidrRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ModifyVcnCidrRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ModifyVcnCidrRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ModifyVcnCidrRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ModifyVcnCidrResponse wrapper for the ModifyVcnCidr operation +type ModifyVcnCidrResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response ModifyVcnCidrResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ModifyVcnCidrResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/multipath_device.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/multipath_device.go new file mode 100644 index 000000000..78125528e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/multipath_device.go @@ -0,0 +1,39 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// MultipathDevice Secondary multipath device, it uses the charUsername and chapSecret from primary volume attachment +type MultipathDevice struct { + + // The volume's iSCSI IP address. + // Example: `169.254.2.2` + Ipv4 *string `mandatory:"true" json:"ipv4"` + + // The target volume's iSCSI Qualified Name in the format defined + // by RFC 3720 (https://tools.ietf.org/html/rfc3720#page-32). + // Example: `iqn.2015-12.com.oracleiaas:40b7ee03-883f-46c6-a951-63d2841d2195` + Iqn *string `mandatory:"true" json:"iqn"` + + // The volume's iSCSI port, usually port 860 or 3260. + // Example: `3260` + Port *int `mandatory:"false" json:"port"` +} + +func (m MultipathDevice) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/nat_gateway.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/nat_gateway.go new file mode 100644 index 000000000..ca94c3101 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/nat_gateway.go @@ -0,0 +1,104 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// NatGateway A NAT (Network Address Translation) gateway, which represents a router that lets instances +// without public IPs contact the public internet without exposing the instance to inbound +// internet traffic. For more information, see +// NAT Gateway (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/NATgateway.htm). +// To use any of the API operations, you must be authorized in an +// IAM policy. If you are not authorized, talk to an +// administrator. If you are an administrator who needs to write +// policies to give users access, see Getting Started with +// Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type NatGateway struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment that contains + // the NAT gateway. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the + // NAT gateway. + Id *string `mandatory:"true" json:"id"` + + // Whether the NAT gateway blocks traffic through it. The default is `false`. + // Example: `true` + BlockTraffic *bool `mandatory:"true" json:"blockTraffic"` + + // The NAT gateway's current state. + LifecycleState NatGatewayLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The IP address associated with the NAT gateway. + NatIp *string `mandatory:"true" json:"natIp"` + + // The date and time the NAT gateway was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN the NAT gateway + // belongs to. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the public IP address associated with the NAT gateway. + PublicIpId *string `mandatory:"false" json:"publicIpId"` +} + +func (m NatGateway) String() string { + return common.PointerString(m) +} + +// NatGatewayLifecycleStateEnum Enum with underlying type: string +type NatGatewayLifecycleStateEnum string + +// Set of constants representing the allowable values for NatGatewayLifecycleStateEnum +const ( + NatGatewayLifecycleStateProvisioning NatGatewayLifecycleStateEnum = "PROVISIONING" + NatGatewayLifecycleStateAvailable NatGatewayLifecycleStateEnum = "AVAILABLE" + NatGatewayLifecycleStateTerminating NatGatewayLifecycleStateEnum = "TERMINATING" + NatGatewayLifecycleStateTerminated NatGatewayLifecycleStateEnum = "TERMINATED" +) + +var mappingNatGatewayLifecycleState = map[string]NatGatewayLifecycleStateEnum{ + "PROVISIONING": NatGatewayLifecycleStateProvisioning, + "AVAILABLE": NatGatewayLifecycleStateAvailable, + "TERMINATING": NatGatewayLifecycleStateTerminating, + "TERMINATED": NatGatewayLifecycleStateTerminated, +} + +// GetNatGatewayLifecycleStateEnumValues Enumerates the set of values for NatGatewayLifecycleStateEnum +func GetNatGatewayLifecycleStateEnumValues() []NatGatewayLifecycleStateEnum { + values := make([]NatGatewayLifecycleStateEnum, 0) + for _, v := range mappingNatGatewayLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/network_security_group.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/network_security_group.go new file mode 100644 index 000000000..24cd256fc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/network_security_group.go @@ -0,0 +1,110 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// NetworkSecurityGroup A *network security group* (NSG) provides virtual firewall rules for a specific set of +// Vnic in a VCN. Compare NSGs with SecurityList, +// which provide virtual firewall rules to all the VNICs in a *subnet*. +// A network security group consists of two items: +// * The set of Vnic that all have the same security rule needs (for +// example, a group of Compute instances all running the same application) +// * A set of NSG SecurityRule that apply to the VNICs in the group +// After creating an NSG, you can add VNICs and security rules to it. For example, when you create +// an instance, you can specify one or more NSGs to add the instance to (see +// CreateVnicDetails). Or you can add an existing +// instance to an NSG with UpdateVnic. +// To add security rules to an NSG, see +// AddNetworkSecurityGroupSecurityRules. +// To list the VNICs in an NSG, see +// ListNetworkSecurityGroupVnics. +// To list the security rules in an NSG, see +// ListNetworkSecurityGroupSecurityRules. +// For more information about network security groups, see +// Network Security Groups (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/networksecuritygroups.htm). +// **Important:** Oracle Cloud Infrastructure Compute service images automatically include firewall rules (for example, +// Linux iptables, Windows firewall). If there are issues with some type of access to an instance, +// make sure all of the following are set correctly: +// * Any security rules in any NSGs the instance's VNIC belongs to +// * Any SecurityList associated with the instance's subnet +// * The instance's OS firewall rules +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type NetworkSecurityGroup struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment the network security group is in. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network security group. + Id *string `mandatory:"true" json:"id"` + + // The network security group's current state. + LifecycleState NetworkSecurityGroupLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the network security group was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network security group's VCN. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m NetworkSecurityGroup) String() string { + return common.PointerString(m) +} + +// NetworkSecurityGroupLifecycleStateEnum Enum with underlying type: string +type NetworkSecurityGroupLifecycleStateEnum string + +// Set of constants representing the allowable values for NetworkSecurityGroupLifecycleStateEnum +const ( + NetworkSecurityGroupLifecycleStateProvisioning NetworkSecurityGroupLifecycleStateEnum = "PROVISIONING" + NetworkSecurityGroupLifecycleStateAvailable NetworkSecurityGroupLifecycleStateEnum = "AVAILABLE" + NetworkSecurityGroupLifecycleStateTerminating NetworkSecurityGroupLifecycleStateEnum = "TERMINATING" + NetworkSecurityGroupLifecycleStateTerminated NetworkSecurityGroupLifecycleStateEnum = "TERMINATED" +) + +var mappingNetworkSecurityGroupLifecycleState = map[string]NetworkSecurityGroupLifecycleStateEnum{ + "PROVISIONING": NetworkSecurityGroupLifecycleStateProvisioning, + "AVAILABLE": NetworkSecurityGroupLifecycleStateAvailable, + "TERMINATING": NetworkSecurityGroupLifecycleStateTerminating, + "TERMINATED": NetworkSecurityGroupLifecycleStateTerminated, +} + +// GetNetworkSecurityGroupLifecycleStateEnumValues Enumerates the set of values for NetworkSecurityGroupLifecycleStateEnum +func GetNetworkSecurityGroupLifecycleStateEnumValues() []NetworkSecurityGroupLifecycleStateEnum { + values := make([]NetworkSecurityGroupLifecycleStateEnum, 0) + for _, v := range mappingNetworkSecurityGroupLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/network_security_group_vnic.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/network_security_group_vnic.go new file mode 100644 index 000000000..92a114dc9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/network_security_group_vnic.go @@ -0,0 +1,38 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// NetworkSecurityGroupVnic Information about a VNIC that belongs to a network security group. +type NetworkSecurityGroupVnic struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VNIC. + VnicId *string `mandatory:"true" json:"vnicId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the parent resource that the VNIC + // is attached to (for example, a Compute instance). + ResourceId *string `mandatory:"false" json:"resourceId"` + + // The date and time the VNIC was added to the network security group, in the format + // defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeAssociated *common.SDKTime `mandatory:"false" json:"timeAssociated"` +} + +func (m NetworkSecurityGroupVnic) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/networking_topology.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/networking_topology.go new file mode 100644 index 000000000..2c0b6a2f7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/networking_topology.go @@ -0,0 +1,101 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// NetworkingTopology Defines the representation of a virtual network topology for a region. +type NetworkingTopology struct { + + // Lists entities comprising the virtual network topology. + Entities []interface{} `mandatory:"true" json:"entities"` + + // Lists relationships between entities in the virtual network topology. + Relationships []TopologyEntityRelationship `mandatory:"true" json:"relationships"` + + // Records when the virtual network topology was created, in RFC3339 (https://tools.ietf.org/html/rfc3339) format for date and time. + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` +} + +//GetEntities returns Entities +func (m NetworkingTopology) GetEntities() []interface{} { + return m.Entities +} + +//GetRelationships returns Relationships +func (m NetworkingTopology) GetRelationships() []TopologyEntityRelationship { + return m.Relationships +} + +//GetTimeCreated returns TimeCreated +func (m NetworkingTopology) GetTimeCreated() *common.SDKTime { + return m.TimeCreated +} + +func (m NetworkingTopology) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m NetworkingTopology) MarshalJSON() (buff []byte, e error) { + type MarshalTypeNetworkingTopology NetworkingTopology + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeNetworkingTopology + }{ + "NETWORKING", + (MarshalTypeNetworkingTopology)(m), + } + + return json.Marshal(&s) +} + +// UnmarshalJSON unmarshals from json +func (m *NetworkingTopology) UnmarshalJSON(data []byte) (e error) { + model := struct { + Entities []interface{} `json:"entities"` + Relationships []topologyentityrelationship `json:"relationships"` + TimeCreated *common.SDKTime `json:"timeCreated"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.Entities = make([]interface{}, len(model.Entities)) + for i, n := range model.Entities { + m.Entities[i] = n + } + + m.Relationships = make([]TopologyEntityRelationship, len(model.Relationships)) + for i, n := range model.Relationships { + nn, e = n.UnmarshalPolymorphicJSON(n.JsonData) + if e != nil { + return e + } + if nn != nil { + m.Relationships[i] = nn.(TopologyEntityRelationship) + } else { + m.Relationships[i] = nil + } + } + + m.TimeCreated = model.TimeCreated + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/paravirtualized_volume_attachment.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/paravirtualized_volume_attachment.go new file mode 100644 index 000000000..137cfd825 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/paravirtualized_volume_attachment.go @@ -0,0 +1,160 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ParavirtualizedVolumeAttachment A paravirtualized volume attachment. +type ParavirtualizedVolumeAttachment struct { + + // The availability domain of an instance. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the volume attachment. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the instance the volume is attached to. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // The date and time the volume was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID of the volume. + VolumeId *string `mandatory:"true" json:"volumeId"` + + // The device name. + Device *string `mandatory:"false" json:"device"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Whether the attachment was created in read-only mode. + IsReadOnly *bool `mandatory:"false" json:"isReadOnly"` + + // Whether the attachment should be created in shareable mode. If an attachment + // is created in shareable mode, then other instances can attach the same volume, provided + // that they also create their attachments in shareable mode. Only certain volume types can + // be attached in shareable mode. Defaults to false if not specified. + IsShareable *bool `mandatory:"false" json:"isShareable"` + + // Whether in-transit encryption for the data volume's paravirtualized attachment is enabled or not. + IsPvEncryptionInTransitEnabled *bool `mandatory:"false" json:"isPvEncryptionInTransitEnabled"` + + // Whether the attachment is multipath or not. + IsMultipath *bool `mandatory:"false" json:"isMultipath"` + + // The current state of the volume attachment. + LifecycleState VolumeAttachmentLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The iscsi login state of the volume attachment. For a multipath volume attachment, + // all iscsi sessions need to be all logged-in or logged-out to be in logged-in or logged-out state. + IscsiLoginState VolumeAttachmentIscsiLoginStateEnum `mandatory:"false" json:"iscsiLoginState,omitempty"` +} + +//GetAvailabilityDomain returns AvailabilityDomain +func (m ParavirtualizedVolumeAttachment) GetAvailabilityDomain() *string { + return m.AvailabilityDomain +} + +//GetCompartmentId returns CompartmentId +func (m ParavirtualizedVolumeAttachment) GetCompartmentId() *string { + return m.CompartmentId +} + +//GetDevice returns Device +func (m ParavirtualizedVolumeAttachment) GetDevice() *string { + return m.Device +} + +//GetDisplayName returns DisplayName +func (m ParavirtualizedVolumeAttachment) GetDisplayName() *string { + return m.DisplayName +} + +//GetId returns Id +func (m ParavirtualizedVolumeAttachment) GetId() *string { + return m.Id +} + +//GetInstanceId returns InstanceId +func (m ParavirtualizedVolumeAttachment) GetInstanceId() *string { + return m.InstanceId +} + +//GetIsReadOnly returns IsReadOnly +func (m ParavirtualizedVolumeAttachment) GetIsReadOnly() *bool { + return m.IsReadOnly +} + +//GetIsShareable returns IsShareable +func (m ParavirtualizedVolumeAttachment) GetIsShareable() *bool { + return m.IsShareable +} + +//GetLifecycleState returns LifecycleState +func (m ParavirtualizedVolumeAttachment) GetLifecycleState() VolumeAttachmentLifecycleStateEnum { + return m.LifecycleState +} + +//GetTimeCreated returns TimeCreated +func (m ParavirtualizedVolumeAttachment) GetTimeCreated() *common.SDKTime { + return m.TimeCreated +} + +//GetVolumeId returns VolumeId +func (m ParavirtualizedVolumeAttachment) GetVolumeId() *string { + return m.VolumeId +} + +//GetIsPvEncryptionInTransitEnabled returns IsPvEncryptionInTransitEnabled +func (m ParavirtualizedVolumeAttachment) GetIsPvEncryptionInTransitEnabled() *bool { + return m.IsPvEncryptionInTransitEnabled +} + +//GetIsMultipath returns IsMultipath +func (m ParavirtualizedVolumeAttachment) GetIsMultipath() *bool { + return m.IsMultipath +} + +//GetIscsiLoginState returns IscsiLoginState +func (m ParavirtualizedVolumeAttachment) GetIscsiLoginState() VolumeAttachmentIscsiLoginStateEnum { + return m.IscsiLoginState +} + +func (m ParavirtualizedVolumeAttachment) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m ParavirtualizedVolumeAttachment) MarshalJSON() (buff []byte, e error) { + type MarshalTypeParavirtualizedVolumeAttachment ParavirtualizedVolumeAttachment + s := struct { + DiscriminatorParam string `json:"attachmentType"` + MarshalTypeParavirtualizedVolumeAttachment + }{ + "paravirtualized", + (MarshalTypeParavirtualizedVolumeAttachment)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/peer_region_for_remote_peering.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/peer_region_for_remote_peering.go new file mode 100644 index 000000000..fa5052448 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/peer_region_for_remote_peering.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PeerRegionForRemotePeering Details about a region that supports remote VCN peering. For more +// information, see VCN Peering (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/VCNpeering.htm). +type PeerRegionForRemotePeering struct { + + // The region's name. + // Example: `us-phoenix-1` + Name *string `mandatory:"true" json:"name"` +} + +func (m PeerRegionForRemotePeering) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/phase_one_config_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/phase_one_config_details.go new file mode 100644 index 000000000..8f9dcc744 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/phase_one_config_details.go @@ -0,0 +1,122 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PhaseOneConfigDetails Phase 1 Configuration Details +type PhaseOneConfigDetails struct { + + // Indicates whether custom phase one configuration is enabled. + IsCustomPhaseOneConfig *bool `mandatory:"false" json:"isCustomPhaseOneConfig"` + + // Phase one authentication algorithm supported during tunnel negotiation. + AuthenticationAlgorithm PhaseOneConfigDetailsAuthenticationAlgorithmEnum `mandatory:"false" json:"authenticationAlgorithm,omitempty"` + + // Phase one encryption algorithm supported during tunnel negotiation. + EncryptionAlgorithm PhaseOneConfigDetailsEncryptionAlgorithmEnum `mandatory:"false" json:"encryptionAlgorithm,omitempty"` + + // Phase One Diffie Hellman group supported during tunnel negotiation. + DiffieHelmanGroup PhaseOneConfigDetailsDiffieHelmanGroupEnum `mandatory:"false" json:"diffieHelmanGroup,omitempty"` + + // IKE session key lifetime in seconds for IPSec phase one. + LifetimeInSeconds *int `mandatory:"false" json:"lifetimeInSeconds"` +} + +func (m PhaseOneConfigDetails) String() string { + return common.PointerString(m) +} + +// PhaseOneConfigDetailsAuthenticationAlgorithmEnum Enum with underlying type: string +type PhaseOneConfigDetailsAuthenticationAlgorithmEnum string + +// Set of constants representing the allowable values for PhaseOneConfigDetailsAuthenticationAlgorithmEnum +const ( + PhaseOneConfigDetailsAuthenticationAlgorithmSha2384 PhaseOneConfigDetailsAuthenticationAlgorithmEnum = "SHA2_384" + PhaseOneConfigDetailsAuthenticationAlgorithmSha2256 PhaseOneConfigDetailsAuthenticationAlgorithmEnum = "SHA2_256" + PhaseOneConfigDetailsAuthenticationAlgorithmSha196 PhaseOneConfigDetailsAuthenticationAlgorithmEnum = "SHA1_96" +) + +var mappingPhaseOneConfigDetailsAuthenticationAlgorithm = map[string]PhaseOneConfigDetailsAuthenticationAlgorithmEnum{ + "SHA2_384": PhaseOneConfigDetailsAuthenticationAlgorithmSha2384, + "SHA2_256": PhaseOneConfigDetailsAuthenticationAlgorithmSha2256, + "SHA1_96": PhaseOneConfigDetailsAuthenticationAlgorithmSha196, +} + +// GetPhaseOneConfigDetailsAuthenticationAlgorithmEnumValues Enumerates the set of values for PhaseOneConfigDetailsAuthenticationAlgorithmEnum +func GetPhaseOneConfigDetailsAuthenticationAlgorithmEnumValues() []PhaseOneConfigDetailsAuthenticationAlgorithmEnum { + values := make([]PhaseOneConfigDetailsAuthenticationAlgorithmEnum, 0) + for _, v := range mappingPhaseOneConfigDetailsAuthenticationAlgorithm { + values = append(values, v) + } + return values +} + +// PhaseOneConfigDetailsEncryptionAlgorithmEnum Enum with underlying type: string +type PhaseOneConfigDetailsEncryptionAlgorithmEnum string + +// Set of constants representing the allowable values for PhaseOneConfigDetailsEncryptionAlgorithmEnum +const ( + PhaseOneConfigDetailsEncryptionAlgorithm256Cbc PhaseOneConfigDetailsEncryptionAlgorithmEnum = "AES_256_CBC" + PhaseOneConfigDetailsEncryptionAlgorithm192Cbc PhaseOneConfigDetailsEncryptionAlgorithmEnum = "AES_192_CBC" + PhaseOneConfigDetailsEncryptionAlgorithm128Cbc PhaseOneConfigDetailsEncryptionAlgorithmEnum = "AES_128_CBC" +) + +var mappingPhaseOneConfigDetailsEncryptionAlgorithm = map[string]PhaseOneConfigDetailsEncryptionAlgorithmEnum{ + "AES_256_CBC": PhaseOneConfigDetailsEncryptionAlgorithm256Cbc, + "AES_192_CBC": PhaseOneConfigDetailsEncryptionAlgorithm192Cbc, + "AES_128_CBC": PhaseOneConfigDetailsEncryptionAlgorithm128Cbc, +} + +// GetPhaseOneConfigDetailsEncryptionAlgorithmEnumValues Enumerates the set of values for PhaseOneConfigDetailsEncryptionAlgorithmEnum +func GetPhaseOneConfigDetailsEncryptionAlgorithmEnumValues() []PhaseOneConfigDetailsEncryptionAlgorithmEnum { + values := make([]PhaseOneConfigDetailsEncryptionAlgorithmEnum, 0) + for _, v := range mappingPhaseOneConfigDetailsEncryptionAlgorithm { + values = append(values, v) + } + return values +} + +// PhaseOneConfigDetailsDiffieHelmanGroupEnum Enum with underlying type: string +type PhaseOneConfigDetailsDiffieHelmanGroupEnum string + +// Set of constants representing the allowable values for PhaseOneConfigDetailsDiffieHelmanGroupEnum +const ( + PhaseOneConfigDetailsDiffieHelmanGroupGroup2 PhaseOneConfigDetailsDiffieHelmanGroupEnum = "GROUP2" + PhaseOneConfigDetailsDiffieHelmanGroupGroup5 PhaseOneConfigDetailsDiffieHelmanGroupEnum = "GROUP5" + PhaseOneConfigDetailsDiffieHelmanGroupGroup14 PhaseOneConfigDetailsDiffieHelmanGroupEnum = "GROUP14" + PhaseOneConfigDetailsDiffieHelmanGroupGroup19 PhaseOneConfigDetailsDiffieHelmanGroupEnum = "GROUP19" + PhaseOneConfigDetailsDiffieHelmanGroupGroup20 PhaseOneConfigDetailsDiffieHelmanGroupEnum = "GROUP20" + PhaseOneConfigDetailsDiffieHelmanGroupGroup24 PhaseOneConfigDetailsDiffieHelmanGroupEnum = "GROUP24" +) + +var mappingPhaseOneConfigDetailsDiffieHelmanGroup = map[string]PhaseOneConfigDetailsDiffieHelmanGroupEnum{ + "GROUP2": PhaseOneConfigDetailsDiffieHelmanGroupGroup2, + "GROUP5": PhaseOneConfigDetailsDiffieHelmanGroupGroup5, + "GROUP14": PhaseOneConfigDetailsDiffieHelmanGroupGroup14, + "GROUP19": PhaseOneConfigDetailsDiffieHelmanGroupGroup19, + "GROUP20": PhaseOneConfigDetailsDiffieHelmanGroupGroup20, + "GROUP24": PhaseOneConfigDetailsDiffieHelmanGroupGroup24, +} + +// GetPhaseOneConfigDetailsDiffieHelmanGroupEnumValues Enumerates the set of values for PhaseOneConfigDetailsDiffieHelmanGroupEnum +func GetPhaseOneConfigDetailsDiffieHelmanGroupEnumValues() []PhaseOneConfigDetailsDiffieHelmanGroupEnum { + values := make([]PhaseOneConfigDetailsDiffieHelmanGroupEnum, 0) + for _, v := range mappingPhaseOneConfigDetailsDiffieHelmanGroup { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/phase_two_config_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/phase_two_config_details.go new file mode 100644 index 000000000..72cfa69ce --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/phase_two_config_details.go @@ -0,0 +1,129 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PhaseTwoConfigDetails Phase 2 Configuration Details +type PhaseTwoConfigDetails struct { + + // Indicates whether custom phase two configuration is enabled. + IsCustomPhaseTwoConfig *bool `mandatory:"false" json:"isCustomPhaseTwoConfig"` + + // Phase two authentication algorithm supported during tunnel negotiation. + AuthenticationAlgorithm PhaseTwoConfigDetailsAuthenticationAlgorithmEnum `mandatory:"false" json:"authenticationAlgorithm,omitempty"` + + // Phase two encryption algorithm supported during tunnel negotiation. + EncryptionAlgorithm PhaseTwoConfigDetailsEncryptionAlgorithmEnum `mandatory:"false" json:"encryptionAlgorithm,omitempty"` + + // Lifetime in seconds for IPSec phase two. + LifetimeInSeconds *int `mandatory:"false" json:"lifetimeInSeconds"` + + // Indicates whether perfect forward secrecy (PFS) is enabled. + IsPfsEnabled *bool `mandatory:"false" json:"isPfsEnabled"` + + // Diffie-Hellman group used for PFS. + PfsDhGroup PhaseTwoConfigDetailsPfsDhGroupEnum `mandatory:"false" json:"pfsDhGroup,omitempty"` +} + +func (m PhaseTwoConfigDetails) String() string { + return common.PointerString(m) +} + +// PhaseTwoConfigDetailsAuthenticationAlgorithmEnum Enum with underlying type: string +type PhaseTwoConfigDetailsAuthenticationAlgorithmEnum string + +// Set of constants representing the allowable values for PhaseTwoConfigDetailsAuthenticationAlgorithmEnum +const ( + PhaseTwoConfigDetailsAuthenticationAlgorithmSha2256128 PhaseTwoConfigDetailsAuthenticationAlgorithmEnum = "HMAC_SHA2_256_128" + PhaseTwoConfigDetailsAuthenticationAlgorithmSha1128 PhaseTwoConfigDetailsAuthenticationAlgorithmEnum = "HMAC_SHA1_128" +) + +var mappingPhaseTwoConfigDetailsAuthenticationAlgorithm = map[string]PhaseTwoConfigDetailsAuthenticationAlgorithmEnum{ + "HMAC_SHA2_256_128": PhaseTwoConfigDetailsAuthenticationAlgorithmSha2256128, + "HMAC_SHA1_128": PhaseTwoConfigDetailsAuthenticationAlgorithmSha1128, +} + +// GetPhaseTwoConfigDetailsAuthenticationAlgorithmEnumValues Enumerates the set of values for PhaseTwoConfigDetailsAuthenticationAlgorithmEnum +func GetPhaseTwoConfigDetailsAuthenticationAlgorithmEnumValues() []PhaseTwoConfigDetailsAuthenticationAlgorithmEnum { + values := make([]PhaseTwoConfigDetailsAuthenticationAlgorithmEnum, 0) + for _, v := range mappingPhaseTwoConfigDetailsAuthenticationAlgorithm { + values = append(values, v) + } + return values +} + +// PhaseTwoConfigDetailsEncryptionAlgorithmEnum Enum with underlying type: string +type PhaseTwoConfigDetailsEncryptionAlgorithmEnum string + +// Set of constants representing the allowable values for PhaseTwoConfigDetailsEncryptionAlgorithmEnum +const ( + PhaseTwoConfigDetailsEncryptionAlgorithm256Gcm PhaseTwoConfigDetailsEncryptionAlgorithmEnum = "AES_256_GCM" + PhaseTwoConfigDetailsEncryptionAlgorithm192Gcm PhaseTwoConfigDetailsEncryptionAlgorithmEnum = "AES_192_GCM" + PhaseTwoConfigDetailsEncryptionAlgorithm128Gcm PhaseTwoConfigDetailsEncryptionAlgorithmEnum = "AES_128_GCM" + PhaseTwoConfigDetailsEncryptionAlgorithm256Cbc PhaseTwoConfigDetailsEncryptionAlgorithmEnum = "AES_256_CBC" + PhaseTwoConfigDetailsEncryptionAlgorithm192Cbc PhaseTwoConfigDetailsEncryptionAlgorithmEnum = "AES_192_CBC" + PhaseTwoConfigDetailsEncryptionAlgorithm128Cbc PhaseTwoConfigDetailsEncryptionAlgorithmEnum = "AES_128_CBC" +) + +var mappingPhaseTwoConfigDetailsEncryptionAlgorithm = map[string]PhaseTwoConfigDetailsEncryptionAlgorithmEnum{ + "AES_256_GCM": PhaseTwoConfigDetailsEncryptionAlgorithm256Gcm, + "AES_192_GCM": PhaseTwoConfigDetailsEncryptionAlgorithm192Gcm, + "AES_128_GCM": PhaseTwoConfigDetailsEncryptionAlgorithm128Gcm, + "AES_256_CBC": PhaseTwoConfigDetailsEncryptionAlgorithm256Cbc, + "AES_192_CBC": PhaseTwoConfigDetailsEncryptionAlgorithm192Cbc, + "AES_128_CBC": PhaseTwoConfigDetailsEncryptionAlgorithm128Cbc, +} + +// GetPhaseTwoConfigDetailsEncryptionAlgorithmEnumValues Enumerates the set of values for PhaseTwoConfigDetailsEncryptionAlgorithmEnum +func GetPhaseTwoConfigDetailsEncryptionAlgorithmEnumValues() []PhaseTwoConfigDetailsEncryptionAlgorithmEnum { + values := make([]PhaseTwoConfigDetailsEncryptionAlgorithmEnum, 0) + for _, v := range mappingPhaseTwoConfigDetailsEncryptionAlgorithm { + values = append(values, v) + } + return values +} + +// PhaseTwoConfigDetailsPfsDhGroupEnum Enum with underlying type: string +type PhaseTwoConfigDetailsPfsDhGroupEnum string + +// Set of constants representing the allowable values for PhaseTwoConfigDetailsPfsDhGroupEnum +const ( + PhaseTwoConfigDetailsPfsDhGroupGroup2 PhaseTwoConfigDetailsPfsDhGroupEnum = "GROUP2" + PhaseTwoConfigDetailsPfsDhGroupGroup5 PhaseTwoConfigDetailsPfsDhGroupEnum = "GROUP5" + PhaseTwoConfigDetailsPfsDhGroupGroup14 PhaseTwoConfigDetailsPfsDhGroupEnum = "GROUP14" + PhaseTwoConfigDetailsPfsDhGroupGroup19 PhaseTwoConfigDetailsPfsDhGroupEnum = "GROUP19" + PhaseTwoConfigDetailsPfsDhGroupGroup20 PhaseTwoConfigDetailsPfsDhGroupEnum = "GROUP20" + PhaseTwoConfigDetailsPfsDhGroupGroup24 PhaseTwoConfigDetailsPfsDhGroupEnum = "GROUP24" +) + +var mappingPhaseTwoConfigDetailsPfsDhGroup = map[string]PhaseTwoConfigDetailsPfsDhGroupEnum{ + "GROUP2": PhaseTwoConfigDetailsPfsDhGroupGroup2, + "GROUP5": PhaseTwoConfigDetailsPfsDhGroupGroup5, + "GROUP14": PhaseTwoConfigDetailsPfsDhGroupGroup14, + "GROUP19": PhaseTwoConfigDetailsPfsDhGroupGroup19, + "GROUP20": PhaseTwoConfigDetailsPfsDhGroupGroup20, + "GROUP24": PhaseTwoConfigDetailsPfsDhGroupGroup24, +} + +// GetPhaseTwoConfigDetailsPfsDhGroupEnumValues Enumerates the set of values for PhaseTwoConfigDetailsPfsDhGroupEnum +func GetPhaseTwoConfigDetailsPfsDhGroupEnumValues() []PhaseTwoConfigDetailsPfsDhGroupEnum { + values := make([]PhaseTwoConfigDetailsPfsDhGroupEnum, 0) + for _, v := range mappingPhaseTwoConfigDetailsPfsDhGroup { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/platform_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/platform_config.go new file mode 100644 index 000000000..b6e5d58e8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/platform_config.go @@ -0,0 +1,141 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PlatformConfig The platform configuration for the instance. +type PlatformConfig interface { + + // Whether Secure Boot is enabled on the instance. + GetIsSecureBootEnabled() *bool + + // Whether the Trusted Platform Module (TPM) is enabled on the instance. + GetIsTrustedPlatformModuleEnabled() *bool + + // Whether the Measured Boot feature is enabled on the instance. + GetIsMeasuredBootEnabled() *bool +} + +type platformconfig struct { + JsonData []byte + IsSecureBootEnabled *bool `mandatory:"false" json:"isSecureBootEnabled"` + IsTrustedPlatformModuleEnabled *bool `mandatory:"false" json:"isTrustedPlatformModuleEnabled"` + IsMeasuredBootEnabled *bool `mandatory:"false" json:"isMeasuredBootEnabled"` + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *platformconfig) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerplatformconfig platformconfig + s := struct { + Model Unmarshalerplatformconfig + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.IsSecureBootEnabled = s.Model.IsSecureBootEnabled + m.IsTrustedPlatformModuleEnabled = s.Model.IsTrustedPlatformModuleEnabled + m.IsMeasuredBootEnabled = s.Model.IsMeasuredBootEnabled + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *platformconfig) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "AMD_MILAN_BM": + mm := AmdMilanBmPlatformConfig{} + err = json.Unmarshal(data, &mm) + return mm, err + case "AMD_ROME_BM": + mm := AmdRomeBmPlatformConfig{} + err = json.Unmarshal(data, &mm) + return mm, err + case "INTEL_SKYLAKE_BM": + mm := IntelSkylakeBmPlatformConfig{} + err = json.Unmarshal(data, &mm) + return mm, err + case "AMD_VM": + mm := AmdVmPlatformConfig{} + err = json.Unmarshal(data, &mm) + return mm, err + case "INTEL_VM": + mm := IntelVmPlatformConfig{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetIsSecureBootEnabled returns IsSecureBootEnabled +func (m platformconfig) GetIsSecureBootEnabled() *bool { + return m.IsSecureBootEnabled +} + +//GetIsTrustedPlatformModuleEnabled returns IsTrustedPlatformModuleEnabled +func (m platformconfig) GetIsTrustedPlatformModuleEnabled() *bool { + return m.IsTrustedPlatformModuleEnabled +} + +//GetIsMeasuredBootEnabled returns IsMeasuredBootEnabled +func (m platformconfig) GetIsMeasuredBootEnabled() *bool { + return m.IsMeasuredBootEnabled +} + +func (m platformconfig) String() string { + return common.PointerString(m) +} + +// PlatformConfigTypeEnum Enum with underlying type: string +type PlatformConfigTypeEnum string + +// Set of constants representing the allowable values for PlatformConfigTypeEnum +const ( + PlatformConfigTypeAmdMilanBm PlatformConfigTypeEnum = "AMD_MILAN_BM" + PlatformConfigTypeAmdRomeBm PlatformConfigTypeEnum = "AMD_ROME_BM" + PlatformConfigTypeIntelSkylakeBm PlatformConfigTypeEnum = "INTEL_SKYLAKE_BM" + PlatformConfigTypeAmdVm PlatformConfigTypeEnum = "AMD_VM" + PlatformConfigTypeIntelVm PlatformConfigTypeEnum = "INTEL_VM" +) + +var mappingPlatformConfigType = map[string]PlatformConfigTypeEnum{ + "AMD_MILAN_BM": PlatformConfigTypeAmdMilanBm, + "AMD_ROME_BM": PlatformConfigTypeAmdRomeBm, + "INTEL_SKYLAKE_BM": PlatformConfigTypeIntelSkylakeBm, + "AMD_VM": PlatformConfigTypeAmdVm, + "INTEL_VM": PlatformConfigTypeIntelVm, +} + +// GetPlatformConfigTypeEnumValues Enumerates the set of values for PlatformConfigTypeEnum +func GetPlatformConfigTypeEnumValues() []PlatformConfigTypeEnum { + values := make([]PlatformConfigTypeEnum, 0) + for _, v := range mappingPlatformConfigType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/port_range.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/port_range.go new file mode 100644 index 000000000..82c40aebf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/port_range.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PortRange The representation of PortRange +type PortRange struct { + + // The maximum port number, which must not be less than the minimum port number. To specify + // a single port number, set both the min and max to the same value. + Max *int `mandatory:"true" json:"max"` + + // The minimum port number, which must not be greater than the maximum port number. + Min *int `mandatory:"true" json:"min"` +} + +func (m PortRange) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/preemptible_instance_config_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/preemptible_instance_config_details.go new file mode 100644 index 000000000..3b391e5be --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/preemptible_instance_config_details.go @@ -0,0 +1,52 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PreemptibleInstanceConfigDetails Configuration options for preemptible instances. +type PreemptibleInstanceConfigDetails struct { + PreemptionAction PreemptionAction `mandatory:"true" json:"preemptionAction"` +} + +func (m PreemptibleInstanceConfigDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *PreemptibleInstanceConfigDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + PreemptionAction preemptionaction `json:"preemptionAction"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + nn, e = model.PreemptionAction.UnmarshalPolymorphicJSON(model.PreemptionAction.JsonData) + if e != nil { + return + } + if nn != nil { + m.PreemptionAction = nn.(PreemptionAction) + } else { + m.PreemptionAction = nil + } + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/preemption_action.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/preemption_action.go new file mode 100644 index 000000000..8423b9b91 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/preemption_action.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PreemptionAction The action to run when the preemptible instance is interrupted for eviction. +type PreemptionAction interface { +} + +type preemptionaction struct { + JsonData []byte + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *preemptionaction) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerpreemptionaction preemptionaction + s := struct { + Model Unmarshalerpreemptionaction + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *preemptionaction) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "TERMINATE": + mm := TerminatePreemptionAction{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +func (m preemptionaction) String() string { + return common.PointerString(m) +} + +// PreemptionActionTypeEnum Enum with underlying type: string +type PreemptionActionTypeEnum string + +// Set of constants representing the allowable values for PreemptionActionTypeEnum +const ( + PreemptionActionTypeTerminate PreemptionActionTypeEnum = "TERMINATE" +) + +var mappingPreemptionActionType = map[string]PreemptionActionTypeEnum{ + "TERMINATE": PreemptionActionTypeTerminate, +} + +// GetPreemptionActionTypeEnumValues Enumerates the set of values for PreemptionActionTypeEnum +func GetPreemptionActionTypeEnumValues() []PreemptionActionTypeEnum { + values := make([]PreemptionActionTypeEnum, 0) + for _, v := range mappingPreemptionActionType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/private_ip.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/private_ip.go new file mode 100644 index 000000000..38e807a98 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/private_ip.go @@ -0,0 +1,122 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PrivateIp A *private IP* is a conceptual term that refers to an IPv4 private IP address and related properties. +// The `privateIp` object is the API representation of a private IP. +// **Note:** For information about IPv6 addresses, see Ipv6. +// Each instance has a *primary private IP* that is automatically created and +// assigned to the primary VNIC during instance launch. If you add a secondary +// VNIC to the instance, it also automatically gets a primary private IP. You +// can't remove a primary private IP from its VNIC. The primary private IP is +// automatically deleted when the VNIC is terminated. +// You can add *secondary private IPs* to a VNIC after it's created. For more +// information, see the `privateIp` operations and also +// IP Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingIPaddresses.htm). +// **Note:** Only +// ListPrivateIps and +// GetPrivateIp work with +// *primary* private IPs. To create and update primary private IPs, you instead +// work with instance and VNIC operations. For example, a primary private IP's +// properties come from the values you specify in +// CreateVnicDetails when calling either +// LaunchInstance or +// AttachVnic. To update the hostname +// for a primary private IP, you use UpdateVnic. +// `PrivateIp` objects that are created for use with the Oracle Cloud VMware Solution are +// assigned to a VLAN and not a VNIC in a subnet. See the +// descriptions of the relevant attributes in the `PrivateIp` object. Also see +// Vlan. +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type PrivateIp struct { + + // The private IP's availability domain. This attribute will be null if this is a *secondary* + // private IP assigned to a VNIC that is in a *regional* subnet. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" json:"availabilityDomain"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the private IP. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The hostname for the private IP. Used for DNS. The value is the hostname + // portion of the private IP's fully qualified domain name (FQDN) + // (for example, `bminstance-1` in FQDN `bminstance-1.subnet123.vcn1.oraclevcn.com`). + // Must be unique across all VNICs in the subnet and comply with + // RFC 952 (https://tools.ietf.org/html/rfc952) and + // RFC 1123 (https://tools.ietf.org/html/rfc1123). + // For more information, see + // DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). + // Example: `bminstance-1` + HostnameLabel *string `mandatory:"false" json:"hostnameLabel"` + + // The private IP's Oracle ID (OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"false" json:"id"` + + // The private IP address of the `privateIp` object. The address is within the CIDR + // of the VNIC's subnet. + // However, if the `PrivateIp` object is being used with a VLAN as part of + // the Oracle Cloud VMware Solution, the address is from the range specified by the + // `cidrBlock` attribute for the VLAN. See Vlan. + // Example: `10.0.3.3` + IpAddress *string `mandatory:"false" json:"ipAddress"` + + // Whether this private IP is the primary one on the VNIC. Primary private IPs + // are unassigned and deleted automatically when the VNIC is terminated. + // Example: `true` + IsPrimary *bool `mandatory:"false" json:"isPrimary"` + + // Applicable only if the `PrivateIp` object is being used with a VLAN as part of + // the Oracle Cloud VMware Solution. The `vlanId` is the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VLAN. See + // Vlan. + VlanId *string `mandatory:"false" json:"vlanId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the subnet the VNIC is in. + // However, if the `PrivateIp` object is being used with a VLAN as part of + // the Oracle Cloud VMware Solution, the `subnetId` is null. + SubnetId *string `mandatory:"false" json:"subnetId"` + + // The date and time the private IP was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VNIC the private IP is assigned to. The VNIC and private IP + // must be in the same subnet. + // However, if the `PrivateIp` object is being used with a VLAN as part of + // the Oracle Cloud VMware Solution, the `vnicId` is null. + VnicId *string `mandatory:"false" json:"vnicId"` +} + +func (m PrivateIp) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip.go new file mode 100644 index 000000000..c2b5792c7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip.go @@ -0,0 +1,217 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PublicIp A *public IP* is a conceptual term that refers to a public IP address and related properties. +// The `publicIp` object is the API representation of a public IP. +// There are two types of public IPs: +// 1. Ephemeral +// 2. Reserved +// For more information and comparison of the two types, +// see Public IP Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingpublicIPs.htm). +type PublicIp struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the entity the public IP is assigned to, or in the process of + // being assigned to. + AssignedEntityId *string `mandatory:"false" json:"assignedEntityId"` + + // The type of entity the public IP is assigned to, or in the process of being + // assigned to. + AssignedEntityType PublicIpAssignedEntityTypeEnum `mandatory:"false" json:"assignedEntityType,omitempty"` + + // The public IP's availability domain. This property is set only for ephemeral public IPs + // that are assigned to a private IP (that is, when the `scope` of the public IP is set to + // AVAILABILITY_DOMAIN). The value is the availability domain of the assigned private IP. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" json:"availabilityDomain"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the public IP. For an ephemeral public IP, this is + // the compartment of its assigned entity (which can be a private IP or a regional entity such + // as a NAT gateway). For a reserved public IP that is currently assigned, + // its compartment can be different from the assigned private IP's. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The public IP's Oracle ID (OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"false" json:"id"` + + // The public IP address of the `publicIp` object. + // Example: `203.0.113.2` + IpAddress *string `mandatory:"false" json:"ipAddress"` + + // The public IP's current state. + LifecycleState PublicIpLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // Defines when the public IP is deleted and released back to Oracle's public IP pool. + // * `EPHEMERAL`: The lifetime is tied to the lifetime of its assigned entity. An ephemeral + // public IP must always be assigned to an entity. If the assigned entity is a private IP, + // the ephemeral public IP is automatically deleted when the private IP is deleted, when + // the VNIC is terminated, or when the instance is terminated. If the assigned entity is a + // NatGateway, the ephemeral public IP is automatically + // deleted when the NAT gateway is terminated. + // * `RESERVED`: You control the public IP's lifetime. You can delete a reserved public IP + // whenever you like. It does not need to be assigned to a private IP at all times. + // For more information and comparison of the two types, + // see Public IP Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingpublicIPs.htm). + Lifetime PublicIpLifetimeEnum `mandatory:"false" json:"lifetime,omitempty"` + + // Deprecated. Use `assignedEntityId` instead. + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the private IP that the public IP is currently assigned to, or in the + // process of being assigned to. + // **Note:** This is `null` if the public IP is not assigned to a private IP, or is + // in the process of being assigned to one. + PrivateIpId *string `mandatory:"false" json:"privateIpId"` + + // Whether the public IP is regional or specific to a particular availability domain. + // * `REGION`: The public IP exists within a region and is assigned to a regional entity + // (such as a NatGateway), or can be assigned to a private + // IP in any availability domain in the region. Reserved public IPs and ephemeral public IPs + // assigned to a regional entity have `scope` = `REGION`. + // * `AVAILABILITY_DOMAIN`: The public IP exists within the availability domain of the entity + // it's assigned to, which is specified by the `availabilityDomain` property of the public IP object. + // Ephemeral public IPs that are assigned to private IPs have `scope` = `AVAILABILITY_DOMAIN`. + Scope PublicIpScopeEnum `mandatory:"false" json:"scope,omitempty"` + + // The date and time the public IP was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the pool object created in the current tenancy. + PublicIpPoolId *string `mandatory:"false" json:"publicIpPoolId"` +} + +func (m PublicIp) String() string { + return common.PointerString(m) +} + +// PublicIpAssignedEntityTypeEnum Enum with underlying type: string +type PublicIpAssignedEntityTypeEnum string + +// Set of constants representing the allowable values for PublicIpAssignedEntityTypeEnum +const ( + PublicIpAssignedEntityTypePrivateIp PublicIpAssignedEntityTypeEnum = "PRIVATE_IP" + PublicIpAssignedEntityTypeNatGateway PublicIpAssignedEntityTypeEnum = "NAT_GATEWAY" +) + +var mappingPublicIpAssignedEntityType = map[string]PublicIpAssignedEntityTypeEnum{ + "PRIVATE_IP": PublicIpAssignedEntityTypePrivateIp, + "NAT_GATEWAY": PublicIpAssignedEntityTypeNatGateway, +} + +// GetPublicIpAssignedEntityTypeEnumValues Enumerates the set of values for PublicIpAssignedEntityTypeEnum +func GetPublicIpAssignedEntityTypeEnumValues() []PublicIpAssignedEntityTypeEnum { + values := make([]PublicIpAssignedEntityTypeEnum, 0) + for _, v := range mappingPublicIpAssignedEntityType { + values = append(values, v) + } + return values +} + +// PublicIpLifecycleStateEnum Enum with underlying type: string +type PublicIpLifecycleStateEnum string + +// Set of constants representing the allowable values for PublicIpLifecycleStateEnum +const ( + PublicIpLifecycleStateProvisioning PublicIpLifecycleStateEnum = "PROVISIONING" + PublicIpLifecycleStateAvailable PublicIpLifecycleStateEnum = "AVAILABLE" + PublicIpLifecycleStateAssigning PublicIpLifecycleStateEnum = "ASSIGNING" + PublicIpLifecycleStateAssigned PublicIpLifecycleStateEnum = "ASSIGNED" + PublicIpLifecycleStateUnassigning PublicIpLifecycleStateEnum = "UNASSIGNING" + PublicIpLifecycleStateUnassigned PublicIpLifecycleStateEnum = "UNASSIGNED" + PublicIpLifecycleStateTerminating PublicIpLifecycleStateEnum = "TERMINATING" + PublicIpLifecycleStateTerminated PublicIpLifecycleStateEnum = "TERMINATED" +) + +var mappingPublicIpLifecycleState = map[string]PublicIpLifecycleStateEnum{ + "PROVISIONING": PublicIpLifecycleStateProvisioning, + "AVAILABLE": PublicIpLifecycleStateAvailable, + "ASSIGNING": PublicIpLifecycleStateAssigning, + "ASSIGNED": PublicIpLifecycleStateAssigned, + "UNASSIGNING": PublicIpLifecycleStateUnassigning, + "UNASSIGNED": PublicIpLifecycleStateUnassigned, + "TERMINATING": PublicIpLifecycleStateTerminating, + "TERMINATED": PublicIpLifecycleStateTerminated, +} + +// GetPublicIpLifecycleStateEnumValues Enumerates the set of values for PublicIpLifecycleStateEnum +func GetPublicIpLifecycleStateEnumValues() []PublicIpLifecycleStateEnum { + values := make([]PublicIpLifecycleStateEnum, 0) + for _, v := range mappingPublicIpLifecycleState { + values = append(values, v) + } + return values +} + +// PublicIpLifetimeEnum Enum with underlying type: string +type PublicIpLifetimeEnum string + +// Set of constants representing the allowable values for PublicIpLifetimeEnum +const ( + PublicIpLifetimeEphemeral PublicIpLifetimeEnum = "EPHEMERAL" + PublicIpLifetimeReserved PublicIpLifetimeEnum = "RESERVED" +) + +var mappingPublicIpLifetime = map[string]PublicIpLifetimeEnum{ + "EPHEMERAL": PublicIpLifetimeEphemeral, + "RESERVED": PublicIpLifetimeReserved, +} + +// GetPublicIpLifetimeEnumValues Enumerates the set of values for PublicIpLifetimeEnum +func GetPublicIpLifetimeEnumValues() []PublicIpLifetimeEnum { + values := make([]PublicIpLifetimeEnum, 0) + for _, v := range mappingPublicIpLifetime { + values = append(values, v) + } + return values +} + +// PublicIpScopeEnum Enum with underlying type: string +type PublicIpScopeEnum string + +// Set of constants representing the allowable values for PublicIpScopeEnum +const ( + PublicIpScopeRegion PublicIpScopeEnum = "REGION" + PublicIpScopeAvailabilityDomain PublicIpScopeEnum = "AVAILABILITY_DOMAIN" +) + +var mappingPublicIpScope = map[string]PublicIpScopeEnum{ + "REGION": PublicIpScopeRegion, + "AVAILABILITY_DOMAIN": PublicIpScopeAvailabilityDomain, +} + +// GetPublicIpScopeEnumValues Enumerates the set of values for PublicIpScopeEnum +func GetPublicIpScopeEnumValues() []PublicIpScopeEnum { + values := make([]PublicIpScopeEnum, 0) + for _, v := range mappingPublicIpScope { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip_pool.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip_pool.go new file mode 100644 index 000000000..aa7f82c33 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip_pool.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PublicIpPool A public IP pool is a set of public IP addresses represented as one or more IPv4 CIDR blocks. Resources like load balancers and compute instances can be allocated public IP addresses from a public IP pool. +type PublicIpPool struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing this pool. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the public IP pool. + Id *string `mandatory:"true" json:"id"` + + // The date and time the public IP pool was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The CIDR blocks added to this pool. This could be all or a portion of a BYOIP CIDR block. + CidrBlocks []string `mandatory:"false" json:"cidrBlocks"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The public IP pool's current state. + LifecycleState PublicIpPoolLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` +} + +func (m PublicIpPool) String() string { + return common.PointerString(m) +} + +// PublicIpPoolLifecycleStateEnum Enum with underlying type: string +type PublicIpPoolLifecycleStateEnum string + +// Set of constants representing the allowable values for PublicIpPoolLifecycleStateEnum +const ( + PublicIpPoolLifecycleStateInactive PublicIpPoolLifecycleStateEnum = "INACTIVE" + PublicIpPoolLifecycleStateUpdating PublicIpPoolLifecycleStateEnum = "UPDATING" + PublicIpPoolLifecycleStateActive PublicIpPoolLifecycleStateEnum = "ACTIVE" + PublicIpPoolLifecycleStateDeleting PublicIpPoolLifecycleStateEnum = "DELETING" + PublicIpPoolLifecycleStateDeleted PublicIpPoolLifecycleStateEnum = "DELETED" +) + +var mappingPublicIpPoolLifecycleState = map[string]PublicIpPoolLifecycleStateEnum{ + "INACTIVE": PublicIpPoolLifecycleStateInactive, + "UPDATING": PublicIpPoolLifecycleStateUpdating, + "ACTIVE": PublicIpPoolLifecycleStateActive, + "DELETING": PublicIpPoolLifecycleStateDeleting, + "DELETED": PublicIpPoolLifecycleStateDeleted, +} + +// GetPublicIpPoolLifecycleStateEnumValues Enumerates the set of values for PublicIpPoolLifecycleStateEnum +func GetPublicIpPoolLifecycleStateEnumValues() []PublicIpPoolLifecycleStateEnum { + values := make([]PublicIpPoolLifecycleStateEnum, 0) + for _, v := range mappingPublicIpPoolLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip_pool_collection.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip_pool_collection.go new file mode 100644 index 000000000..a8b38b7a1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip_pool_collection.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PublicIpPoolCollection Results of a `ListPublicIpPool` operation. +type PublicIpPoolCollection struct { + + // A list of public IP pool summaries. + Items []PublicIpPoolSummary `mandatory:"true" json:"items"` +} + +func (m PublicIpPoolCollection) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip_pool_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip_pool_summary.go new file mode 100644 index 000000000..dda98b4f6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/public_ip_pool_summary.go @@ -0,0 +1,53 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PublicIpPoolSummary Summary information about a public IP pool. +type PublicIpPoolSummary struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the public IP pool. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the public IP pool. + Id *string `mandatory:"false" json:"id"` + + // The public IP pool's current state. + LifecycleState PublicIpPoolLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The date and time the public IP pool was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` +} + +func (m PublicIpPoolSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/remote_peering_connection.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/remote_peering_connection.go new file mode 100644 index 000000000..d70bf841c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/remote_peering_connection.go @@ -0,0 +1,138 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RemotePeeringConnection A remote peering connection (RPC) is an object on a DRG that lets the VCN that is attached +// to the DRG peer with a VCN in a different region. *Peering* means that the two VCNs can +// communicate using private IP addresses, but without the traffic traversing the internet or +// routing through your on-premises network. For more information, see +// VCN Peering (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/VCNpeering.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type RemotePeeringConnection struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment that contains the RPC. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG that this RPC belongs to. + DrgId *string `mandatory:"true" json:"drgId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the RPC. + Id *string `mandatory:"true" json:"id"` + + // Whether the VCN at the other end of the peering is in a different tenancy. + // Example: `false` + IsCrossTenancyPeering *bool `mandatory:"true" json:"isCrossTenancyPeering"` + + // The RPC's current lifecycle state. + LifecycleState RemotePeeringConnectionLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // 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. + PeeringStatus RemotePeeringConnectionPeeringStatusEnum `mandatory:"true" json:"peeringStatus"` + + // The date and time the RPC was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // If this RPC is peered, this value is the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the other RPC. + PeerId *string `mandatory:"false" json:"peerId"` + + // If this RPC is peered, this value is the region that contains the other RPC. + // Example: `us-ashburn-1` + PeerRegionName *string `mandatory:"false" json:"peerRegionName"` + + // If this RPC is peered, this value is the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the other RPC's tenancy. + PeerTenancyId *string `mandatory:"false" json:"peerTenancyId"` +} + +func (m RemotePeeringConnection) String() string { + return common.PointerString(m) +} + +// RemotePeeringConnectionLifecycleStateEnum Enum with underlying type: string +type RemotePeeringConnectionLifecycleStateEnum string + +// Set of constants representing the allowable values for RemotePeeringConnectionLifecycleStateEnum +const ( + RemotePeeringConnectionLifecycleStateAvailable RemotePeeringConnectionLifecycleStateEnum = "AVAILABLE" + RemotePeeringConnectionLifecycleStateProvisioning RemotePeeringConnectionLifecycleStateEnum = "PROVISIONING" + RemotePeeringConnectionLifecycleStateTerminating RemotePeeringConnectionLifecycleStateEnum = "TERMINATING" + RemotePeeringConnectionLifecycleStateTerminated RemotePeeringConnectionLifecycleStateEnum = "TERMINATED" +) + +var mappingRemotePeeringConnectionLifecycleState = map[string]RemotePeeringConnectionLifecycleStateEnum{ + "AVAILABLE": RemotePeeringConnectionLifecycleStateAvailable, + "PROVISIONING": RemotePeeringConnectionLifecycleStateProvisioning, + "TERMINATING": RemotePeeringConnectionLifecycleStateTerminating, + "TERMINATED": RemotePeeringConnectionLifecycleStateTerminated, +} + +// GetRemotePeeringConnectionLifecycleStateEnumValues Enumerates the set of values for RemotePeeringConnectionLifecycleStateEnum +func GetRemotePeeringConnectionLifecycleStateEnumValues() []RemotePeeringConnectionLifecycleStateEnum { + values := make([]RemotePeeringConnectionLifecycleStateEnum, 0) + for _, v := range mappingRemotePeeringConnectionLifecycleState { + values = append(values, v) + } + return values +} + +// RemotePeeringConnectionPeeringStatusEnum Enum with underlying type: string +type RemotePeeringConnectionPeeringStatusEnum string + +// Set of constants representing the allowable values for RemotePeeringConnectionPeeringStatusEnum +const ( + RemotePeeringConnectionPeeringStatusInvalid RemotePeeringConnectionPeeringStatusEnum = "INVALID" + RemotePeeringConnectionPeeringStatusNew RemotePeeringConnectionPeeringStatusEnum = "NEW" + RemotePeeringConnectionPeeringStatusPending RemotePeeringConnectionPeeringStatusEnum = "PENDING" + RemotePeeringConnectionPeeringStatusPeered RemotePeeringConnectionPeeringStatusEnum = "PEERED" + RemotePeeringConnectionPeeringStatusRevoked RemotePeeringConnectionPeeringStatusEnum = "REVOKED" +) + +var mappingRemotePeeringConnectionPeeringStatus = map[string]RemotePeeringConnectionPeeringStatusEnum{ + "INVALID": RemotePeeringConnectionPeeringStatusInvalid, + "NEW": RemotePeeringConnectionPeeringStatusNew, + "PENDING": RemotePeeringConnectionPeeringStatusPending, + "PEERED": RemotePeeringConnectionPeeringStatusPeered, + "REVOKED": RemotePeeringConnectionPeeringStatusRevoked, +} + +// GetRemotePeeringConnectionPeeringStatusEnumValues Enumerates the set of values for RemotePeeringConnectionPeeringStatusEnum +func GetRemotePeeringConnectionPeeringStatusEnumValues() []RemotePeeringConnectionPeeringStatusEnum { + values := make([]RemotePeeringConnectionPeeringStatusEnum, 0) + for _, v := range mappingRemotePeeringConnectionPeeringStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/remote_peering_connection_drg_attachment_network_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/remote_peering_connection_drg_attachment_network_details.go new file mode 100644 index 000000000..8322e5a57 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/remote_peering_connection_drg_attachment_network_details.go @@ -0,0 +1,49 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RemotePeeringConnectionDrgAttachmentNetworkDetails Specifies the DRG attachment to another DRG. +type RemotePeeringConnectionDrgAttachmentNetworkDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network attached to the DRG. + Id *string `mandatory:"true" json:"id"` +} + +//GetId returns Id +func (m RemotePeeringConnectionDrgAttachmentNetworkDetails) GetId() *string { + return m.Id +} + +func (m RemotePeeringConnectionDrgAttachmentNetworkDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m RemotePeeringConnectionDrgAttachmentNetworkDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeRemotePeeringConnectionDrgAttachmentNetworkDetails RemotePeeringConnectionDrgAttachmentNetworkDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeRemotePeeringConnectionDrgAttachmentNetworkDetails + }{ + "REMOTE_PEERING_CONNECTION", + (MarshalTypeRemotePeeringConnectionDrgAttachmentNetworkDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_distribution_statements_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_distribution_statements_details.go new file mode 100644 index 000000000..7db4616f7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_distribution_statements_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RemoveDrgRouteDistributionStatementsDetails Details request to remove statements from a route distribution. +type RemoveDrgRouteDistributionStatementsDetails struct { + + // The Oracle-assigned ID of each route distribution to remove. + StatementIds []string `mandatory:"false" json:"statementIds"` +} + +func (m RemoveDrgRouteDistributionStatementsDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_distribution_statements_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_distribution_statements_request_response.go new file mode 100644 index 000000000..7c6eba5ad --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_distribution_statements_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// RemoveDrgRouteDistributionStatementsRequest wrapper for the RemoveDrgRouteDistributionStatements operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemoveDrgRouteDistributionStatements.go.html to see an example of how to use RemoveDrgRouteDistributionStatementsRequest. +type RemoveDrgRouteDistributionStatementsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route distribution. + DrgRouteDistributionId *string `mandatory:"true" contributesTo:"path" name:"drgRouteDistributionId"` + + // Request with one or more route distribution statements to remove from the route distribution. + RemoveDrgRouteDistributionStatementsDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request RemoveDrgRouteDistributionStatementsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request RemoveDrgRouteDistributionStatementsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request RemoveDrgRouteDistributionStatementsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request RemoveDrgRouteDistributionStatementsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// RemoveDrgRouteDistributionStatementsResponse wrapper for the RemoveDrgRouteDistributionStatements operation +type RemoveDrgRouteDistributionStatementsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response RemoveDrgRouteDistributionStatementsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response RemoveDrgRouteDistributionStatementsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_rules_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_rules_details.go new file mode 100644 index 000000000..636c88b76 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_rules_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RemoveDrgRouteRulesDetails Details used in a request to remove static routes from a DRG route table. +type RemoveDrgRouteRulesDetails struct { + + // The Oracle-assigned ID of each DRG route rule to be deleted. + RouteRuleIds []string `mandatory:"false" json:"routeRuleIds"` +} + +func (m RemoveDrgRouteRulesDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_rules_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_rules_request_response.go new file mode 100644 index 000000000..acfafe8c6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_drg_route_rules_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// RemoveDrgRouteRulesRequest wrapper for the RemoveDrgRouteRules operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemoveDrgRouteRules.go.html to see an example of how to use RemoveDrgRouteRulesRequest. +type RemoveDrgRouteRulesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG route table. + DrgRouteTableId *string `mandatory:"true" contributesTo:"path" name:"drgRouteTableId"` + + // Request to remove one or more route rules in the DRG route table. + RemoveDrgRouteRulesDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request RemoveDrgRouteRulesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request RemoveDrgRouteRulesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request RemoveDrgRouteRulesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request RemoveDrgRouteRulesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// RemoveDrgRouteRulesResponse wrapper for the RemoveDrgRouteRules operation +type RemoveDrgRouteRulesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response RemoveDrgRouteRulesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response RemoveDrgRouteRulesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_export_drg_route_distribution_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_export_drg_route_distribution_request_response.go new file mode 100644 index 000000000..5021e0cb5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_export_drg_route_distribution_request_response.go @@ -0,0 +1,82 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// RemoveExportDrgRouteDistributionRequest wrapper for the RemoveExportDrgRouteDistribution operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemoveExportDrgRouteDistribution.go.html to see an example of how to use RemoveExportDrgRouteDistributionRequest. +type RemoveExportDrgRouteDistributionRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG attachment. + DrgAttachmentId *string `mandatory:"true" contributesTo:"path" name:"drgAttachmentId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request RemoveExportDrgRouteDistributionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request RemoveExportDrgRouteDistributionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request RemoveExportDrgRouteDistributionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request RemoveExportDrgRouteDistributionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// RemoveExportDrgRouteDistributionResponse wrapper for the RemoveExportDrgRouteDistribution operation +type RemoveExportDrgRouteDistributionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DrgAttachment instance + DrgAttachment `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response RemoveExportDrgRouteDistributionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response RemoveExportDrgRouteDistributionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_image_shape_compatibility_entry_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_image_shape_compatibility_entry_request_response.go new file mode 100644 index 000000000..e1a37c78a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_image_shape_compatibility_entry_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// RemoveImageShapeCompatibilityEntryRequest wrapper for the RemoveImageShapeCompatibilityEntry operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemoveImageShapeCompatibilityEntry.go.html to see an example of how to use RemoveImageShapeCompatibilityEntryRequest. +type RemoveImageShapeCompatibilityEntryRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the image. + ImageId *string `mandatory:"true" contributesTo:"path" name:"imageId"` + + // Shape name. + ShapeName *string `mandatory:"true" contributesTo:"path" name:"shapeName"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request RemoveImageShapeCompatibilityEntryRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request RemoveImageShapeCompatibilityEntryRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request RemoveImageShapeCompatibilityEntryRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request RemoveImageShapeCompatibilityEntryRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// RemoveImageShapeCompatibilityEntryResponse wrapper for the RemoveImageShapeCompatibilityEntry operation +type RemoveImageShapeCompatibilityEntryResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response RemoveImageShapeCompatibilityEntryResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response RemoveImageShapeCompatibilityEntryResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_import_drg_route_distribution_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_import_drg_route_distribution_request_response.go new file mode 100644 index 000000000..a26a3eb6e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_import_drg_route_distribution_request_response.go @@ -0,0 +1,82 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// RemoveImportDrgRouteDistributionRequest wrapper for the RemoveImportDrgRouteDistribution operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemoveImportDrgRouteDistribution.go.html to see an example of how to use RemoveImportDrgRouteDistributionRequest. +type RemoveImportDrgRouteDistributionRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG route table. + DrgRouteTableId *string `mandatory:"true" contributesTo:"path" name:"drgRouteTableId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request RemoveImportDrgRouteDistributionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request RemoveImportDrgRouteDistributionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request RemoveImportDrgRouteDistributionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request RemoveImportDrgRouteDistributionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// RemoveImportDrgRouteDistributionResponse wrapper for the RemoveImportDrgRouteDistribution operation +type RemoveImportDrgRouteDistributionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DrgRouteTable instance + DrgRouteTable `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response RemoveImportDrgRouteDistributionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response RemoveImportDrgRouteDistributionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_network_security_group_security_rules_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_network_security_group_security_rules_details.go new file mode 100644 index 000000000..5d584bbfe --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_network_security_group_security_rules_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RemoveNetworkSecurityGroupSecurityRulesDetails The representation of RemoveNetworkSecurityGroupSecurityRulesDetails +type RemoveNetworkSecurityGroupSecurityRulesDetails struct { + + // The Oracle-assigned ID of each SecurityRule to be deleted. + SecurityRuleIds []string `mandatory:"false" json:"securityRuleIds"` +} + +func (m RemoveNetworkSecurityGroupSecurityRulesDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_network_security_group_security_rules_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_network_security_group_security_rules_request_response.go new file mode 100644 index 000000000..ea31a74b6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_network_security_group_security_rules_request_response.go @@ -0,0 +1,75 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// RemoveNetworkSecurityGroupSecurityRulesRequest wrapper for the RemoveNetworkSecurityGroupSecurityRules operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemoveNetworkSecurityGroupSecurityRules.go.html to see an example of how to use RemoveNetworkSecurityGroupSecurityRulesRequest. +type RemoveNetworkSecurityGroupSecurityRulesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network security group. + NetworkSecurityGroupId *string `mandatory:"true" contributesTo:"path" name:"networkSecurityGroupId"` + + // Request with one or more security rules associated with the network security group that + // will be removed. + RemoveNetworkSecurityGroupSecurityRulesDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request RemoveNetworkSecurityGroupSecurityRulesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request RemoveNetworkSecurityGroupSecurityRulesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request RemoveNetworkSecurityGroupSecurityRulesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request RemoveNetworkSecurityGroupSecurityRulesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// RemoveNetworkSecurityGroupSecurityRulesResponse wrapper for the RemoveNetworkSecurityGroupSecurityRules operation +type RemoveNetworkSecurityGroupSecurityRulesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response RemoveNetworkSecurityGroupSecurityRulesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response RemoveNetworkSecurityGroupSecurityRulesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_public_ip_pool_capacity_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_public_ip_pool_capacity_details.go new file mode 100644 index 000000000..48e5ef7bf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_public_ip_pool_capacity_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RemovePublicIpPoolCapacityDetails The information needed to remove capacity from a public IP pool. +type RemovePublicIpPoolCapacityDetails struct { + + // The CIDR block to remove from the public IP pool. + // Example: `10.0.1.0/24` + CidrBlock *string `mandatory:"true" json:"cidrBlock"` +} + +func (m RemovePublicIpPoolCapacityDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_public_ip_pool_capacity_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_public_ip_pool_capacity_request_response.go new file mode 100644 index 000000000..6c643e1b5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_public_ip_pool_capacity_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// RemovePublicIpPoolCapacityRequest wrapper for the RemovePublicIpPoolCapacity operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemovePublicIpPoolCapacity.go.html to see an example of how to use RemovePublicIpPoolCapacityRequest. +type RemovePublicIpPoolCapacityRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the public IP pool. + PublicIpPoolId *string `mandatory:"true" contributesTo:"path" name:"publicIpPoolId"` + + // The CIDR block to remove from the IP pool. + RemovePublicIpPoolCapacityDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request RemovePublicIpPoolCapacityRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request RemovePublicIpPoolCapacityRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request RemovePublicIpPoolCapacityRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request RemovePublicIpPoolCapacityRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// RemovePublicIpPoolCapacityResponse wrapper for the RemovePublicIpPoolCapacity operation +type RemovePublicIpPoolCapacityResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The PublicIpPool instance + PublicIpPool `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response RemovePublicIpPoolCapacityResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response RemovePublicIpPoolCapacityResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_vcn_cidr_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_vcn_cidr_details.go new file mode 100644 index 000000000..f4742ef0b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_vcn_cidr_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RemoveVcnCidrDetails Details for removing a CIDR block from a VCN. +type RemoveVcnCidrDetails struct { + + // The CIDR block to remove. + CidrBlock *string `mandatory:"true" json:"cidrBlock"` +} + +func (m RemoveVcnCidrDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_vcn_cidr_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_vcn_cidr_request_response.go new file mode 100644 index 000000000..ea3f71a05 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/remove_vcn_cidr_request_response.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// RemoveVcnCidrRequest wrapper for the RemoveVcnCidr operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/RemoveVcnCidr.go.html to see an example of how to use RemoveVcnCidrRequest. +type RemoveVcnCidrRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"true" contributesTo:"path" name:"vcnId"` + + // Details object for removing a VCN CIDR. + RemoveVcnCidrDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request RemoveVcnCidrRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request RemoveVcnCidrRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request RemoveVcnCidrRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request RemoveVcnCidrRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// RemoveVcnCidrResponse wrapper for the RemoveVcnCidr operation +type RemoveVcnCidrResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response RemoveVcnCidrResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response RemoveVcnCidrResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/reset_instance_pool_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/reset_instance_pool_request_response.go new file mode 100644 index 000000000..e4ca0369f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/reset_instance_pool_request_response.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ResetInstancePoolRequest wrapper for the ResetInstancePool operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ResetInstancePool.go.html to see an example of how to use ResetInstancePoolRequest. +type ResetInstancePoolRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" contributesTo:"path" name:"instancePoolId"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ResetInstancePoolRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ResetInstancePoolRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ResetInstancePoolRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ResetInstancePoolRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ResetInstancePoolResponse wrapper for the ResetInstancePool operation +type ResetInstancePoolResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstancePool instance + InstancePool `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ResetInstancePoolResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ResetInstancePoolResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/route_rule.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/route_rule.go new file mode 100644 index 000000000..b1d69f405 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/route_rule.go @@ -0,0 +1,86 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RouteRule A mapping between a destination IP address range and a virtual device to route matching +// packets to (a target). +type RouteRule struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) for the route rule's target. For information about the type of + // targets you can specify, see + // Route Tables (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingroutetables.htm). + NetworkEntityId *string `mandatory:"true" json:"networkEntityId"` + + // Deprecated. Instead use `destination` and `destinationType`. Requests that include both + // `cidrBlock` and `destination` will be rejected. + // A destination IP address range in CIDR notation. Matching packets will + // be routed to the indicated network entity (the target). + // Cannot be an IPv6 CIDR. + // Example: `0.0.0.0/0` + CidrBlock *string `mandatory:"false" json:"cidrBlock"` + + // Conceptually, this is the range of IP addresses used for matching when routing + // traffic. Required if you provide a `destinationType`. + // Allowed values: + // * IP address range in CIDR notation. Can be an IPv4 or IPv6 CIDR. For example: `192.168.1.0/24` + // or `2001:0db8:0123:45::/56`. If you set this to an IPv6 CIDR, the route rule's target + // can only be a DRG or internet gateway. + // IPv6 addressing is supported for all commercial and government regions. + // See IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // * The `cidrBlock` value for a Service, if you're + // setting up a route rule for traffic destined for a particular `Service` through + // a service gateway. For example: `oci-phx-objectstorage`. + Destination *string `mandatory:"false" json:"destination"` + + // Type of destination for the rule. Required if you provide a `destination`. + // * `CIDR_BLOCK`: If the rule's `destination` is an IP address range in CIDR notation. + // * `SERVICE_CIDR_BLOCK`: If the rule's `destination` is the `cidrBlock` value for a + // Service (the rule is for traffic destined for a + // particular `Service` through a service gateway). + DestinationType RouteRuleDestinationTypeEnum `mandatory:"false" json:"destinationType,omitempty"` + + // An optional description of your choice for the rule. + Description *string `mandatory:"false" json:"description"` +} + +func (m RouteRule) String() string { + return common.PointerString(m) +} + +// RouteRuleDestinationTypeEnum Enum with underlying type: string +type RouteRuleDestinationTypeEnum string + +// Set of constants representing the allowable values for RouteRuleDestinationTypeEnum +const ( + RouteRuleDestinationTypeCidrBlock RouteRuleDestinationTypeEnum = "CIDR_BLOCK" + RouteRuleDestinationTypeServiceCidrBlock RouteRuleDestinationTypeEnum = "SERVICE_CIDR_BLOCK" +) + +var mappingRouteRuleDestinationType = map[string]RouteRuleDestinationTypeEnum{ + "CIDR_BLOCK": RouteRuleDestinationTypeCidrBlock, + "SERVICE_CIDR_BLOCK": RouteRuleDestinationTypeServiceCidrBlock, +} + +// GetRouteRuleDestinationTypeEnumValues Enumerates the set of values for RouteRuleDestinationTypeEnum +func GetRouteRuleDestinationTypeEnumValues() []RouteRuleDestinationTypeEnum { + values := make([]RouteRuleDestinationTypeEnum, 0) + for _, v := range mappingRouteRuleDestinationType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/route_table.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/route_table.go new file mode 100644 index 000000000..5412beaaa --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/route_table.go @@ -0,0 +1,91 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RouteTable A collection of `RouteRule` objects, which are used to route packets +// based on destination IP to a particular network entity. For more information, see +// Overview of the Networking Service (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type RouteTable struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the route table. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The route table's Oracle ID (OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"true" json:"id"` + + // The route table's current state. + LifecycleState RouteTableLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The collection of rules for routing destination IPs to network devices. + RouteRules []RouteRule `mandatory:"true" json:"routeRules"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the VCN the route table list belongs to. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The date and time the route table was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` +} + +func (m RouteTable) String() string { + return common.PointerString(m) +} + +// RouteTableLifecycleStateEnum Enum with underlying type: string +type RouteTableLifecycleStateEnum string + +// Set of constants representing the allowable values for RouteTableLifecycleStateEnum +const ( + RouteTableLifecycleStateProvisioning RouteTableLifecycleStateEnum = "PROVISIONING" + RouteTableLifecycleStateAvailable RouteTableLifecycleStateEnum = "AVAILABLE" + RouteTableLifecycleStateTerminating RouteTableLifecycleStateEnum = "TERMINATING" + RouteTableLifecycleStateTerminated RouteTableLifecycleStateEnum = "TERMINATED" +) + +var mappingRouteTableLifecycleState = map[string]RouteTableLifecycleStateEnum{ + "PROVISIONING": RouteTableLifecycleStateProvisioning, + "AVAILABLE": RouteTableLifecycleStateAvailable, + "TERMINATING": RouteTableLifecycleStateTerminating, + "TERMINATED": RouteTableLifecycleStateTerminated, +} + +// GetRouteTableLifecycleStateEnumValues Enumerates the set of values for RouteTableLifecycleStateEnum +func GetRouteTableLifecycleStateEnumValues() []RouteTableLifecycleStateEnum { + values := make([]RouteTableLifecycleStateEnum, 0) + for _, v := range mappingRouteTableLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/security_list.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/security_list.go new file mode 100644 index 000000000..ea6d9cf74 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/security_list.go @@ -0,0 +1,103 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// SecurityList A set of virtual firewall rules for your VCN. Security lists are configured at the subnet +// level, but the rules are applied to the ingress and egress traffic for the individual instances +// in the subnet. The rules can be stateful or stateless. For more information, see +// Security Lists (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/securitylists.htm). +// **Note:** Compare security lists to NetworkSecurityGroups, +// which let you apply a set of security rules to a *specific set of VNICs* instead of an entire +// subnet. Oracle recommends using network security groups instead of security lists, although you +// can use either or both together. +// **Important:** Oracle Cloud Infrastructure Compute service images automatically include firewall rules (for example, +// Linux iptables, Windows firewall). If there are issues with some type of access to an instance, +// make sure both the security lists associated with the instance's subnet and the instance's +// firewall rules are set correctly. +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type SecurityList struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the security list. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // Rules for allowing egress IP packets. + EgressSecurityRules []EgressSecurityRule `mandatory:"true" json:"egressSecurityRules"` + + // The security list's Oracle Cloud ID (OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"true" json:"id"` + + // Rules for allowing ingress IP packets. + IngressSecurityRules []IngressSecurityRule `mandatory:"true" json:"ingressSecurityRules"` + + // The security list's current state. + LifecycleState SecurityListLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the security list was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN the security list belongs to. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m SecurityList) String() string { + return common.PointerString(m) +} + +// SecurityListLifecycleStateEnum Enum with underlying type: string +type SecurityListLifecycleStateEnum string + +// Set of constants representing the allowable values for SecurityListLifecycleStateEnum +const ( + SecurityListLifecycleStateProvisioning SecurityListLifecycleStateEnum = "PROVISIONING" + SecurityListLifecycleStateAvailable SecurityListLifecycleStateEnum = "AVAILABLE" + SecurityListLifecycleStateTerminating SecurityListLifecycleStateEnum = "TERMINATING" + SecurityListLifecycleStateTerminated SecurityListLifecycleStateEnum = "TERMINATED" +) + +var mappingSecurityListLifecycleState = map[string]SecurityListLifecycleStateEnum{ + "PROVISIONING": SecurityListLifecycleStateProvisioning, + "AVAILABLE": SecurityListLifecycleStateAvailable, + "TERMINATING": SecurityListLifecycleStateTerminating, + "TERMINATED": SecurityListLifecycleStateTerminated, +} + +// GetSecurityListLifecycleStateEnumValues Enumerates the set of values for SecurityListLifecycleStateEnum +func GetSecurityListLifecycleStateEnumValues() []SecurityListLifecycleStateEnum { + values := make([]SecurityListLifecycleStateEnum, 0) + for _, v := range mappingSecurityListLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/security_rule.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/security_rule.go new file mode 100644 index 000000000..01b41d9ad --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/security_rule.go @@ -0,0 +1,187 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// SecurityRule A security rule is one of the items in a NetworkSecurityGroup. +// It is a virtual firewall rule for the VNICs in the network security group. A rule can be for +// either inbound (`direction`= INGRESS) or outbound (`direction`= EGRESS) IP packets. +type SecurityRule struct { + + // Direction of the security rule. Set to `EGRESS` for rules to allow outbound IP packets, + // or `INGRESS` for rules to allow inbound IP packets. + Direction SecurityRuleDirectionEnum `mandatory:"true" json:"direction"` + + // The transport protocol. Specify either `all` or an IPv4 protocol number as + // defined in + // Protocol Numbers (http://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml). + // Options are supported only for ICMP ("1"), TCP ("6"), UDP ("17"), and ICMPv6 ("58"). + Protocol *string `mandatory:"true" json:"protocol"` + + // An optional description of your choice for the rule. + Description *string `mandatory:"false" json:"description"` + + // Conceptually, this is the range of IP addresses that a packet originating from the instance + // can go to. + // Allowed values: + // * An IP address range in CIDR notation. For example: `192.168.1.0/24` or `2001:0db8:0123:45::/56` + // IPv6 addressing is supported for all commercial and government regions. + // See IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // * The `cidrBlock` value for a Service, if you're + // setting up a security rule for traffic destined for a particular `Service` through + // a service gateway. For example: `oci-phx-objectstorage`. + // * The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of a NetworkSecurityGroup in the same + // VCN. The value can be the NSG that the rule belongs to if the rule's intent is to control + // traffic between VNICs in the same NSG. + Destination *string `mandatory:"false" json:"destination"` + + // Type of destination for the rule. Required if `direction` = `EGRESS`. + // Allowed values: + // * `CIDR_BLOCK`: If the rule's `destination` is an IP address range in CIDR notation. + // * `SERVICE_CIDR_BLOCK`: If the rule's `destination` is the `cidrBlock` value for a + // Service (the rule is for traffic destined for a + // particular `Service` through a service gateway). + // * `NETWORK_SECURITY_GROUP`: If the rule's `destination` is the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of a + // NetworkSecurityGroup. + DestinationType SecurityRuleDestinationTypeEnum `mandatory:"false" json:"destinationType,omitempty"` + + IcmpOptions *IcmpOptions `mandatory:"false" json:"icmpOptions"` + + // An Oracle-assigned identifier for the security rule. You specify this ID when you want to + // update or delete the rule. + // Example: `04ABEC` + Id *string `mandatory:"false" json:"id"` + + // A stateless rule allows traffic in one direction. Remember to add a corresponding + // stateless rule in the other direction if you need to support bidirectional traffic. For + // example, if egress traffic allows TCP destination port 80, there should be an ingress + // rule to allow TCP source port 80. Defaults to false, which means the rule is stateful + // and a corresponding rule is not necessary for bidirectional traffic. + IsStateless *bool `mandatory:"false" json:"isStateless"` + + // Whether the rule is valid. The value is `True` when the rule is first created. If + // the rule's `source` or `destination` is a network security group, the value changes to + // `False` if that network security group is deleted. + IsValid *bool `mandatory:"false" json:"isValid"` + + // Conceptually, this is the range of IP addresses that a packet coming into the instance + // can come from. + // Allowed values: + // * An IP address range in CIDR notation. For example: `192.168.1.0/24` or `2001:0db8:0123:45::/56` + // IPv6 addressing is supported for all commercial and government regions. + // See IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // * The `cidrBlock` value for a Service, if you're + // setting up a security rule for traffic coming from a particular `Service` through + // a service gateway. For example: `oci-phx-objectstorage`. + // * The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of a NetworkSecurityGroup in the same + // VCN. The value can be the NSG that the rule belongs to if the rule's intent is to control + // traffic between VNICs in the same NSG. + Source *string `mandatory:"false" json:"source"` + + // Type of source for the rule. Required if `direction` = `INGRESS`. + // * `CIDR_BLOCK`: If the rule's `source` is an IP address range in CIDR notation. + // * `SERVICE_CIDR_BLOCK`: If the rule's `source` is the `cidrBlock` value for a + // Service (the rule is for traffic coming from a + // particular `Service` through a service gateway). + // * `NETWORK_SECURITY_GROUP`: If the rule's `source` is the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of a + // NetworkSecurityGroup. + SourceType SecurityRuleSourceTypeEnum `mandatory:"false" json:"sourceType,omitempty"` + + TcpOptions *TcpOptions `mandatory:"false" json:"tcpOptions"` + + // The date and time the security rule was created. Format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + UdpOptions *UdpOptions `mandatory:"false" json:"udpOptions"` +} + +func (m SecurityRule) String() string { + return common.PointerString(m) +} + +// SecurityRuleDestinationTypeEnum Enum with underlying type: string +type SecurityRuleDestinationTypeEnum string + +// Set of constants representing the allowable values for SecurityRuleDestinationTypeEnum +const ( + SecurityRuleDestinationTypeCidrBlock SecurityRuleDestinationTypeEnum = "CIDR_BLOCK" + SecurityRuleDestinationTypeServiceCidrBlock SecurityRuleDestinationTypeEnum = "SERVICE_CIDR_BLOCK" + SecurityRuleDestinationTypeNetworkSecurityGroup SecurityRuleDestinationTypeEnum = "NETWORK_SECURITY_GROUP" +) + +var mappingSecurityRuleDestinationType = map[string]SecurityRuleDestinationTypeEnum{ + "CIDR_BLOCK": SecurityRuleDestinationTypeCidrBlock, + "SERVICE_CIDR_BLOCK": SecurityRuleDestinationTypeServiceCidrBlock, + "NETWORK_SECURITY_GROUP": SecurityRuleDestinationTypeNetworkSecurityGroup, +} + +// GetSecurityRuleDestinationTypeEnumValues Enumerates the set of values for SecurityRuleDestinationTypeEnum +func GetSecurityRuleDestinationTypeEnumValues() []SecurityRuleDestinationTypeEnum { + values := make([]SecurityRuleDestinationTypeEnum, 0) + for _, v := range mappingSecurityRuleDestinationType { + values = append(values, v) + } + return values +} + +// SecurityRuleDirectionEnum Enum with underlying type: string +type SecurityRuleDirectionEnum string + +// Set of constants representing the allowable values for SecurityRuleDirectionEnum +const ( + SecurityRuleDirectionEgress SecurityRuleDirectionEnum = "EGRESS" + SecurityRuleDirectionIngress SecurityRuleDirectionEnum = "INGRESS" +) + +var mappingSecurityRuleDirection = map[string]SecurityRuleDirectionEnum{ + "EGRESS": SecurityRuleDirectionEgress, + "INGRESS": SecurityRuleDirectionIngress, +} + +// GetSecurityRuleDirectionEnumValues Enumerates the set of values for SecurityRuleDirectionEnum +func GetSecurityRuleDirectionEnumValues() []SecurityRuleDirectionEnum { + values := make([]SecurityRuleDirectionEnum, 0) + for _, v := range mappingSecurityRuleDirection { + values = append(values, v) + } + return values +} + +// SecurityRuleSourceTypeEnum Enum with underlying type: string +type SecurityRuleSourceTypeEnum string + +// Set of constants representing the allowable values for SecurityRuleSourceTypeEnum +const ( + SecurityRuleSourceTypeCidrBlock SecurityRuleSourceTypeEnum = "CIDR_BLOCK" + SecurityRuleSourceTypeServiceCidrBlock SecurityRuleSourceTypeEnum = "SERVICE_CIDR_BLOCK" + SecurityRuleSourceTypeNetworkSecurityGroup SecurityRuleSourceTypeEnum = "NETWORK_SECURITY_GROUP" +) + +var mappingSecurityRuleSourceType = map[string]SecurityRuleSourceTypeEnum{ + "CIDR_BLOCK": SecurityRuleSourceTypeCidrBlock, + "SERVICE_CIDR_BLOCK": SecurityRuleSourceTypeServiceCidrBlock, + "NETWORK_SECURITY_GROUP": SecurityRuleSourceTypeNetworkSecurityGroup, +} + +// GetSecurityRuleSourceTypeEnumValues Enumerates the set of values for SecurityRuleSourceTypeEnum +func GetSecurityRuleSourceTypeEnumValues() []SecurityRuleSourceTypeEnum { + values := make([]SecurityRuleSourceTypeEnum, 0) + for _, v := range mappingSecurityRuleSourceType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/service.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/service.go new file mode 100644 index 000000000..964c05edb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/service.go @@ -0,0 +1,53 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Service An object that represents one or multiple Oracle services that you can enable for a +// ServiceGateway. In the User Guide topic +// Access to Oracle Services: Service Gateway (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/servicegateway.htm), the +// term *service CIDR label* is used to refer to the string that represents the regional public +// IP address ranges of the Oracle service or services covered by a given `Service` object. That +// unique string is the value of the `Service` object's `cidrBlock` attribute. +type Service struct { + + // A string that represents the regional public IP address ranges for the Oracle service or + // services covered by this `Service` object. Also known as the `Service` object's *service + // CIDR label*. + // When you set up a route rule to route traffic to the service gateway, use this value as the + // rule's destination. See RouteTable. Also, when you set up + // a security list rule to cover traffic with the service gateway, use the `cidrBlock` value + // as the rule's destination (for an egress rule) or the source (for an ingress rule). + // See SecurityList. + // Example: `oci-phx-objectstorage` + CidrBlock *string `mandatory:"true" json:"cidrBlock"` + + // Description of the Oracle service or services covered by this `Service` object. + // Example: `OCI PHX Object Storage` + Description *string `mandatory:"true" json:"description"` + + // The `Service` object's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + Id *string `mandatory:"true" json:"id"` + + // Name of the `Service` object. This name can change and is not guaranteed to be unique. + // Example: `OCI PHX Object Storage` + Name *string `mandatory:"true" json:"name"` +} + +func (m Service) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/service_gateway.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/service_gateway.go new file mode 100644 index 000000000..7750715f1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/service_gateway.go @@ -0,0 +1,110 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ServiceGateway Represents a router that lets your VCN privately access specific Oracle services such as Object +// Storage without exposing the VCN to the public internet. Traffic leaving the VCN and destined +// for a supported Oracle service (see ListServices) is +// routed through the service gateway and does not traverse the internet. The instances in the VCN +// do not need to have public IP addresses nor be in a public subnet. The VCN does not need an internet gateway +// for this traffic. For more information, see +// Access to Oracle Services: Service Gateway (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/servicegateway.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type ServiceGateway struct { + + // Whether the service gateway blocks all traffic through it. The default is `false`. When + // this is `true`, traffic is not routed to any services, regardless of route rules. + // Example: `true` + BlockTraffic *bool `mandatory:"true" json:"blockTraffic"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment that contains the + // service gateway. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the service gateway. + Id *string `mandatory:"true" json:"id"` + + // The service gateway's current state. + LifecycleState ServiceGatewayLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // List of the Service objects enabled for this service gateway. + // The list can be empty. You can enable a particular `Service` by using + // AttachServiceId or + // UpdateServiceGateway. + Services []ServiceIdResponseDetails `mandatory:"true" json:"services"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN the service gateway + // belongs to. + VcnId *string `mandatory:"true" json:"vcnId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route table the service gateway is using. + // For information about why you would associate a route table with a service gateway, see + // Transit Routing: Private Access to Oracle Services (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitroutingoracleservices.htm). + RouteTableId *string `mandatory:"false" json:"routeTableId"` + + // The date and time the service gateway was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` +} + +func (m ServiceGateway) String() string { + return common.PointerString(m) +} + +// ServiceGatewayLifecycleStateEnum Enum with underlying type: string +type ServiceGatewayLifecycleStateEnum string + +// Set of constants representing the allowable values for ServiceGatewayLifecycleStateEnum +const ( + ServiceGatewayLifecycleStateProvisioning ServiceGatewayLifecycleStateEnum = "PROVISIONING" + ServiceGatewayLifecycleStateAvailable ServiceGatewayLifecycleStateEnum = "AVAILABLE" + ServiceGatewayLifecycleStateTerminating ServiceGatewayLifecycleStateEnum = "TERMINATING" + ServiceGatewayLifecycleStateTerminated ServiceGatewayLifecycleStateEnum = "TERMINATED" +) + +var mappingServiceGatewayLifecycleState = map[string]ServiceGatewayLifecycleStateEnum{ + "PROVISIONING": ServiceGatewayLifecycleStateProvisioning, + "AVAILABLE": ServiceGatewayLifecycleStateAvailable, + "TERMINATING": ServiceGatewayLifecycleStateTerminating, + "TERMINATED": ServiceGatewayLifecycleStateTerminated, +} + +// GetServiceGatewayLifecycleStateEnumValues Enumerates the set of values for ServiceGatewayLifecycleStateEnum +func GetServiceGatewayLifecycleStateEnumValues() []ServiceGatewayLifecycleStateEnum { + values := make([]ServiceGatewayLifecycleStateEnum, 0) + for _, v := range mappingServiceGatewayLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/service_id_request_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/service_id_request_details.go new file mode 100644 index 000000000..440dcb615 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/service_id_request_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ServiceIdRequestDetails The representation of ServiceIdRequestDetails +type ServiceIdRequestDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the Service. + ServiceId *string `mandatory:"true" json:"serviceId"` +} + +func (m ServiceIdRequestDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/service_id_response_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/service_id_response_details.go new file mode 100644 index 000000000..c37fa0ddb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/service_id_response_details.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ServiceIdResponseDetails The representation of ServiceIdResponseDetails +type ServiceIdResponseDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the service. + ServiceId *string `mandatory:"true" json:"serviceId"` + + // The name of the service. + ServiceName *string `mandatory:"true" json:"serviceName"` +} + +func (m ServiceIdResponseDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/shape.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape.go new file mode 100644 index 000000000..b3256d65c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape.go @@ -0,0 +1,110 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Shape A compute instance shape that can be used in LaunchInstance. +// For more information, see Overview of the Compute Service (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm) and +// Compute Shapes (https://docs.cloud.oracle.com/iaas/Content/Compute/References/computeshapes.htm). +type Shape struct { + + // The name of the shape. You can enumerate all available shapes by calling + // ListShapes. + Shape *string `mandatory:"true" json:"shape"` + + // For a subcore burstable VM, the supported baseline OCPU utilization for instances that use this shape. + BaselineOcpuUtilizations []ShapeBaselineOcpuUtilizationsEnum `mandatory:"false" json:"baselineOcpuUtilizations,omitempty"` + + // For a subcore burstable VM, the minimum total baseline OCPUs required. The total baseline OCPUs is equal to + // baselineOcpuUtilization chosen multiplied by the number of OCPUs chosen. + MinTotalBaselineOcpusRequired *float32 `mandatory:"false" json:"minTotalBaselineOcpusRequired"` + + // A short description of the shape's processor (CPU). + ProcessorDescription *string `mandatory:"false" json:"processorDescription"` + + // The default number of OCPUs available for this shape. + Ocpus *float32 `mandatory:"false" json:"ocpus"` + + // The default amount of memory available for this shape, in gigabytes. + MemoryInGBs *float32 `mandatory:"false" json:"memoryInGBs"` + + // The networking bandwidth available for this shape, in gigabits per second. + NetworkingBandwidthInGbps *float32 `mandatory:"false" json:"networkingBandwidthInGbps"` + + // The maximum number of VNIC attachments available for this shape. + MaxVnicAttachments *int `mandatory:"false" json:"maxVnicAttachments"` + + // The number of GPUs available for this shape. + Gpus *int `mandatory:"false" json:"gpus"` + + // A short description of the graphics processing unit (GPU) available for this shape. + // If the shape does not have any GPUs, this field is `null`. + GpuDescription *string `mandatory:"false" json:"gpuDescription"` + + // The number of local disks available for this shape. + LocalDisks *int `mandatory:"false" json:"localDisks"` + + // The aggregate size of the local disks available for this shape, in gigabytes. + // If the shape does not have any local disks, this field is `null`. + LocalDisksTotalSizeInGBs *float32 `mandatory:"false" json:"localDisksTotalSizeInGBs"` + + // A short description of the local disks available for this shape. + // If the shape does not have any local disks, this field is `null`. + LocalDiskDescription *string `mandatory:"false" json:"localDiskDescription"` + + // Whether live migration is supported for this shape. + IsLiveMigrationSupported *bool `mandatory:"false" json:"isLiveMigrationSupported"` + + OcpuOptions *ShapeOcpuOptions `mandatory:"false" json:"ocpuOptions"` + + MemoryOptions *ShapeMemoryOptions `mandatory:"false" json:"memoryOptions"` + + NetworkingBandwidthOptions *ShapeNetworkingBandwidthOptions `mandatory:"false" json:"networkingBandwidthOptions"` + + MaxVnicAttachmentOptions *ShapeMaxVnicAttachmentOptions `mandatory:"false" json:"maxVnicAttachmentOptions"` + + PlatformConfigOptions *ShapePlatformConfigOptions `mandatory:"false" json:"platformConfigOptions"` +} + +func (m Shape) String() string { + return common.PointerString(m) +} + +// ShapeBaselineOcpuUtilizationsEnum Enum with underlying type: string +type ShapeBaselineOcpuUtilizationsEnum string + +// Set of constants representing the allowable values for ShapeBaselineOcpuUtilizationsEnum +const ( + ShapeBaselineOcpuUtilizations8 ShapeBaselineOcpuUtilizationsEnum = "BASELINE_1_8" + ShapeBaselineOcpuUtilizations2 ShapeBaselineOcpuUtilizationsEnum = "BASELINE_1_2" + ShapeBaselineOcpuUtilizations1 ShapeBaselineOcpuUtilizationsEnum = "BASELINE_1_1" +) + +var mappingShapeBaselineOcpuUtilizations = map[string]ShapeBaselineOcpuUtilizationsEnum{ + "BASELINE_1_8": ShapeBaselineOcpuUtilizations8, + "BASELINE_1_2": ShapeBaselineOcpuUtilizations2, + "BASELINE_1_1": ShapeBaselineOcpuUtilizations1, +} + +// GetShapeBaselineOcpuUtilizationsEnumValues Enumerates the set of values for ShapeBaselineOcpuUtilizationsEnum +func GetShapeBaselineOcpuUtilizationsEnumValues() []ShapeBaselineOcpuUtilizationsEnum { + values := make([]ShapeBaselineOcpuUtilizationsEnum, 0) + for _, v := range mappingShapeBaselineOcpuUtilizations { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_max_vnic_attachment_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_max_vnic_attachment_options.go new file mode 100644 index 000000000..b4a312f44 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_max_vnic_attachment_options.go @@ -0,0 +1,36 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ShapeMaxVnicAttachmentOptions For a flexible shape, the number of VNIC attachments that are available for instances that use this shape. +// If this field is null, then this shape has a fixed maximum number of VNIC attachments equal to `maxVnicAttachments`. +type ShapeMaxVnicAttachmentOptions struct { + + // The lowest maximum value of VNIC attachments. + Min *int `mandatory:"false" json:"min"` + + // The highest maximum value of VNIC attachments. + Max *float32 `mandatory:"false" json:"max"` + + // The default number of VNIC attachments allowed per OCPU. + DefaultPerOcpu *float32 `mandatory:"false" json:"defaultPerOcpu"` +} + +func (m ShapeMaxVnicAttachmentOptions) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_measured_boot_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_measured_boot_options.go new file mode 100644 index 000000000..ceef1d6d5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_measured_boot_options.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ShapeMeasuredBootOptions Configuration options for the Measured Boot feature. +type ShapeMeasuredBootOptions struct { + + // Boolean values that indicate whether the Measured Boot feature can be enabled or disabled. + AllowedValues []bool `mandatory:"false" json:"allowedValues"` + + // Whether the Measured Boot feature is enabled by default. + IsDefaultEnabled *bool `mandatory:"false" json:"isDefaultEnabled"` +} + +func (m ShapeMeasuredBootOptions) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_memory_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_memory_options.go new file mode 100644 index 000000000..078b3121f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_memory_options.go @@ -0,0 +1,42 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ShapeMemoryOptions For a flexible shape, the amount of memory available for instances that use this shape. +// If this field is null, then this shape has a fixed amount of memory equivalent to `memoryInGBs`. +type ShapeMemoryOptions struct { + + // The minimum amount of memory, in gigabytes. + MinInGBs *float32 `mandatory:"false" json:"minInGBs"` + + // The maximum amount of memory, in gigabytes. + MaxInGBs *float32 `mandatory:"false" json:"maxInGBs"` + + // The default amount of memory per OCPU available for this shape, in gigabytes. + DefaultPerOcpuInGBs *float32 `mandatory:"false" json:"defaultPerOcpuInGBs"` + + // The minimum amount of memory per OCPU available for this shape, in gigabytes. + MinPerOcpuInGBs *float32 `mandatory:"false" json:"minPerOcpuInGBs"` + + // The maximum amount of memory per OCPU available for this shape, in gigabytes. + MaxPerOcpuInGBs *float32 `mandatory:"false" json:"maxPerOcpuInGBs"` +} + +func (m ShapeMemoryOptions) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_networking_bandwidth_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_networking_bandwidth_options.go new file mode 100644 index 000000000..e969f9abf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_networking_bandwidth_options.go @@ -0,0 +1,36 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ShapeNetworkingBandwidthOptions For a flexible shape, the amount of networking bandwidth available for instances that use this shape. +// If this field is null, then this shape has a fixed amount of bandwidth equivalent to `networkingBandwidthInGbps`. +type ShapeNetworkingBandwidthOptions struct { + + // The minimum amount of networking bandwidth, in gigabits per second. + MinInGbps *float32 `mandatory:"false" json:"minInGbps"` + + // The maximum amount of networking bandwidth, in gigabits per second. + MaxInGbps *float32 `mandatory:"false" json:"maxInGbps"` + + // The default amount of networking bandwidth per OCPU, in gigabits per second. + DefaultPerOcpuInGbps *float32 `mandatory:"false" json:"defaultPerOcpuInGbps"` +} + +func (m ShapeNetworkingBandwidthOptions) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_numa_nodes_per_socket_platform_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_numa_nodes_per_socket_platform_options.go new file mode 100644 index 000000000..aaf119d1f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_numa_nodes_per_socket_platform_options.go @@ -0,0 +1,59 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ShapeNumaNodesPerSocketPlatformOptions Configuration options for NUMA nodes per socket. +type ShapeNumaNodesPerSocketPlatformOptions struct { + + // The supported values for this platform configuration property. + AllowedValues []ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesEnum `mandatory:"false" json:"allowedValues,omitempty"` + + // The default NUMA nodes per socket configuration. + DefaultValue *string `mandatory:"false" json:"defaultValue"` +} + +func (m ShapeNumaNodesPerSocketPlatformOptions) String() string { + return common.PointerString(m) +} + +// ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesEnum Enum with underlying type: string +type ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesEnum string + +// Set of constants representing the allowable values for ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesEnum +const ( + ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesNps0 ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesEnum = "NPS0" + ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesNps1 ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesEnum = "NPS1" + ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesNps2 ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesEnum = "NPS2" + ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesNps4 ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesEnum = "NPS4" +) + +var mappingShapeNumaNodesPerSocketPlatformOptionsAllowedValues = map[string]ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesEnum{ + "NPS0": ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesNps0, + "NPS1": ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesNps1, + "NPS2": ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesNps2, + "NPS4": ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesNps4, +} + +// GetShapeNumaNodesPerSocketPlatformOptionsAllowedValuesEnumValues Enumerates the set of values for ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesEnum +func GetShapeNumaNodesPerSocketPlatformOptionsAllowedValuesEnumValues() []ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesEnum { + values := make([]ShapeNumaNodesPerSocketPlatformOptionsAllowedValuesEnum, 0) + for _, v := range mappingShapeNumaNodesPerSocketPlatformOptionsAllowedValues { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_ocpu_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_ocpu_options.go new file mode 100644 index 000000000..72c7a4771 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_ocpu_options.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ShapeOcpuOptions For a flexible shape, the number of OCPUs available for instances that use this shape. +// If this field is null, then this shape has a fixed number of OCPUs equal to `ocpus`. +type ShapeOcpuOptions struct { + + // The minimum number of OCPUs. + Min *float32 `mandatory:"false" json:"min"` + + // The maximum number of OCPUs. + Max *float32 `mandatory:"false" json:"max"` +} + +func (m ShapeOcpuOptions) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_platform_config_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_platform_config_options.go new file mode 100644 index 000000000..0a5096660 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_platform_config_options.go @@ -0,0 +1,66 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ShapePlatformConfigOptions The list of supported platform configuration options for this shape. +type ShapePlatformConfigOptions struct { + + // The type of platform being configured. + Type ShapePlatformConfigOptionsTypeEnum `mandatory:"false" json:"type,omitempty"` + + SecureBootOptions *ShapeSecureBootOptions `mandatory:"false" json:"secureBootOptions"` + + MeasuredBootOptions *ShapeMeasuredBootOptions `mandatory:"false" json:"measuredBootOptions"` + + TrustedPlatformModuleOptions *ShapeTrustedPlatformModuleOptions `mandatory:"false" json:"trustedPlatformModuleOptions"` + + NumaNodesPerSocketPlatformOptions *ShapeNumaNodesPerSocketPlatformOptions `mandatory:"false" json:"numaNodesPerSocketPlatformOptions"` +} + +func (m ShapePlatformConfigOptions) String() string { + return common.PointerString(m) +} + +// ShapePlatformConfigOptionsTypeEnum Enum with underlying type: string +type ShapePlatformConfigOptionsTypeEnum string + +// Set of constants representing the allowable values for ShapePlatformConfigOptionsTypeEnum +const ( + ShapePlatformConfigOptionsTypeAmdMilanBm ShapePlatformConfigOptionsTypeEnum = "AMD_MILAN_BM" + ShapePlatformConfigOptionsTypeAmdRomeBm ShapePlatformConfigOptionsTypeEnum = "AMD_ROME_BM" + ShapePlatformConfigOptionsTypeIntelSkylakeBm ShapePlatformConfigOptionsTypeEnum = "INTEL_SKYLAKE_BM" + ShapePlatformConfigOptionsTypeAmdVm ShapePlatformConfigOptionsTypeEnum = "AMD_VM" + ShapePlatformConfigOptionsTypeIntelVm ShapePlatformConfigOptionsTypeEnum = "INTEL_VM" +) + +var mappingShapePlatformConfigOptionsType = map[string]ShapePlatformConfigOptionsTypeEnum{ + "AMD_MILAN_BM": ShapePlatformConfigOptionsTypeAmdMilanBm, + "AMD_ROME_BM": ShapePlatformConfigOptionsTypeAmdRomeBm, + "INTEL_SKYLAKE_BM": ShapePlatformConfigOptionsTypeIntelSkylakeBm, + "AMD_VM": ShapePlatformConfigOptionsTypeAmdVm, + "INTEL_VM": ShapePlatformConfigOptionsTypeIntelVm, +} + +// GetShapePlatformConfigOptionsTypeEnumValues Enumerates the set of values for ShapePlatformConfigOptionsTypeEnum +func GetShapePlatformConfigOptionsTypeEnumValues() []ShapePlatformConfigOptionsTypeEnum { + values := make([]ShapePlatformConfigOptionsTypeEnum, 0) + for _, v := range mappingShapePlatformConfigOptionsType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_secure_boot_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_secure_boot_options.go new file mode 100644 index 000000000..e31eac49f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_secure_boot_options.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ShapeSecureBootOptions Configuration options for Secure Boot. +type ShapeSecureBootOptions struct { + + // Boolean values that indicate whether Secure Boot can be enabled or disabled. + AllowedValues []bool `mandatory:"false" json:"allowedValues"` + + // Whether Secure Boot is enabled by default. + IsDefaultEnabled *bool `mandatory:"false" json:"isDefaultEnabled"` +} + +func (m ShapeSecureBootOptions) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_trusted_platform_module_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_trusted_platform_module_options.go new file mode 100644 index 000000000..7bd458f2c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/shape_trusted_platform_module_options.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ShapeTrustedPlatformModuleOptions Configuration options for the Trusted Platform Module (TPM). +type ShapeTrustedPlatformModuleOptions struct { + + // Boolean values that indicate whether the Trusted Platform Module can be enabled or disabled. + AllowedValues []bool `mandatory:"false" json:"allowedValues"` + + // Whether the Trusted Platform Module is enabled by default. + IsDefaultEnabled *bool `mandatory:"false" json:"isDefaultEnabled"` +} + +func (m ShapeTrustedPlatformModuleOptions) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/softreset_instance_pool_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/softreset_instance_pool_request_response.go new file mode 100644 index 000000000..09382357f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/softreset_instance_pool_request_response.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// SoftresetInstancePoolRequest wrapper for the SoftresetInstancePool operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/SoftresetInstancePool.go.html to see an example of how to use SoftresetInstancePoolRequest. +type SoftresetInstancePoolRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" contributesTo:"path" name:"instancePoolId"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request SoftresetInstancePoolRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request SoftresetInstancePoolRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request SoftresetInstancePoolRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request SoftresetInstancePoolRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// SoftresetInstancePoolResponse wrapper for the SoftresetInstancePool operation +type SoftresetInstancePoolResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstancePool instance + InstancePool `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response SoftresetInstancePoolResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response SoftresetInstancePoolResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/start_instance_pool_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/start_instance_pool_request_response.go new file mode 100644 index 000000000..c5e38d954 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/start_instance_pool_request_response.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// StartInstancePoolRequest wrapper for the StartInstancePool operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/StartInstancePool.go.html to see an example of how to use StartInstancePoolRequest. +type StartInstancePoolRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" contributesTo:"path" name:"instancePoolId"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request StartInstancePoolRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request StartInstancePoolRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request StartInstancePoolRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request StartInstancePoolRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// StartInstancePoolResponse wrapper for the StartInstancePool operation +type StartInstancePoolResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstancePool instance + InstancePool `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response StartInstancePoolResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response StartInstancePoolResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/stop_instance_pool_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/stop_instance_pool_request_response.go new file mode 100644 index 000000000..eaa6f7770 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/stop_instance_pool_request_response.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// StopInstancePoolRequest wrapper for the StopInstancePool operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/StopInstancePool.go.html to see an example of how to use StopInstancePoolRequest. +type StopInstancePoolRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" contributesTo:"path" name:"instancePoolId"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request StopInstancePoolRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request StopInstancePoolRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request StopInstancePoolRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request StopInstancePoolRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// StopInstancePoolResponse wrapper for the StopInstancePool operation +type StopInstancePoolResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstancePool instance + InstancePool `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response StopInstancePoolResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response StopInstancePoolResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/subnet.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/subnet.go new file mode 100644 index 000000000..f25daceea --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/subnet.go @@ -0,0 +1,172 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Subnet A logical subdivision of a VCN. Each subnet +// consists of a contiguous range of IP addresses that do not overlap with +// other subnets in the VCN. Example: 172.16.1.0/24. For more information, see +// Overview of the Networking Service (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm) and +// VCNs and Subnets (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingVCNs.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type Subnet struct { + + // The subnet's CIDR block. + // Example: `10.0.1.0/24` + CidrBlock *string `mandatory:"true" json:"cidrBlock"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the subnet. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The subnet's Oracle ID (OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"true" json:"id"` + + // The subnet's current state. + LifecycleState SubnetLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route table that the subnet uses. + RouteTableId *string `mandatory:"true" json:"routeTableId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN the subnet is in. + VcnId *string `mandatory:"true" json:"vcnId"` + + // The IP address of the virtual router. + // Example: `10.0.14.1` + VirtualRouterIp *string `mandatory:"true" json:"virtualRouterIp"` + + // The MAC address of the virtual router. + // Example: `00:00:00:00:00:01` + VirtualRouterMac *string `mandatory:"true" json:"virtualRouterMac"` + + // The subnet's availability domain. This attribute will be null if this is a regional subnet + // instead of an AD-specific subnet. Oracle recommends creating regional subnets. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" json:"availabilityDomain"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the set of DHCP options that the subnet uses. + DhcpOptionsId *string `mandatory:"false" json:"dhcpOptionsId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // A DNS label for the subnet, used in conjunction with the VNIC's hostname and + // VCN's DNS label to form a fully qualified domain name (FQDN) for each VNIC + // within this subnet (for example, `bminstance-1.subnet123.vcn1.oraclevcn.com`). + // Must be an alphanumeric string that begins with a letter and is unique within the VCN. + // The value cannot be changed. + // The absence of this parameter means the Internet and VCN Resolver + // will not resolve hostnames of instances in this subnet. + // For more information, see + // DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). + // Example: `subnet123` + DnsLabel *string `mandatory:"false" json:"dnsLabel"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // For an IPv6-enabled subnet, this is the IPv6 CIDR block for the subnet's IP address space. + // The subnet size is always /64. See IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // Example: `2001:0db8:0123:1111::/64` + Ipv6CidrBlock *string `mandatory:"false" json:"ipv6CidrBlock"` + + // For an IPv6-enabled subnet, this is the IPv6 address of the virtual router. + // Example: `2001:0db8:0123:1111:89ab:cdef:1234:5678` + Ipv6VirtualRouterIp *string `mandatory:"false" json:"ipv6VirtualRouterIp"` + + // Whether to disallow ingress internet traffic to VNICs within this subnet. Defaults to false. + // For IPV4, `prohibitInternetIngress` behaves similarly to `prohibitPublicIpOnVnic`. + // If it is set to false, VNICs created in this subnet will automatically be assigned public IP + // addresses unless specified otherwise during instance launch or VNIC creation (with the `assignPublicIp` + // flag in CreateVnicDetails). + // If `prohibitInternetIngress` is set to true, VNICs created in this subnet cannot have public IP addresses + // (that is, it's a privatesubnet). + // For IPv6, if `prohibitInternetIngress` is set to `true`, internet access is not allowed for any + // IPv6s assigned to VNICs in the subnet. Otherwise, ingress internet traffic is allowed by default. + // Example: `true` + ProhibitInternetIngress *bool `mandatory:"false" json:"prohibitInternetIngress"` + + // Whether VNICs within this subnet can have public IP addresses. + // Defaults to false, which means VNICs created in this subnet will + // automatically be assigned public IP addresses unless specified + // otherwise during instance launch or VNIC creation (with the + // `assignPublicIp` flag in + // CreateVnicDetails). + // If `prohibitPublicIpOnVnic` is set to true, VNICs created in this + // subnet cannot have public IP addresses (that is, it's a private + // subnet). + // Example: `true` + ProhibitPublicIpOnVnic *bool `mandatory:"false" json:"prohibitPublicIpOnVnic"` + + // The OCIDs of the security list or lists that the subnet uses. Remember + // that security lists are associated *with the subnet*, but the + // rules are applied to the individual VNICs in the subnet. + SecurityListIds []string `mandatory:"false" json:"securityListIds"` + + // The subnet's domain name, which consists of the subnet's DNS label, + // the VCN's DNS label, and the `oraclevcn.com` domain. + // For more information, see + // DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). + // Example: `subnet123.vcn1.oraclevcn.com` + SubnetDomainName *string `mandatory:"false" json:"subnetDomainName"` + + // The date and time the subnet was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` +} + +func (m Subnet) String() string { + return common.PointerString(m) +} + +// SubnetLifecycleStateEnum Enum with underlying type: string +type SubnetLifecycleStateEnum string + +// Set of constants representing the allowable values for SubnetLifecycleStateEnum +const ( + SubnetLifecycleStateProvisioning SubnetLifecycleStateEnum = "PROVISIONING" + SubnetLifecycleStateAvailable SubnetLifecycleStateEnum = "AVAILABLE" + SubnetLifecycleStateTerminating SubnetLifecycleStateEnum = "TERMINATING" + SubnetLifecycleStateTerminated SubnetLifecycleStateEnum = "TERMINATED" + SubnetLifecycleStateUpdating SubnetLifecycleStateEnum = "UPDATING" +) + +var mappingSubnetLifecycleState = map[string]SubnetLifecycleStateEnum{ + "PROVISIONING": SubnetLifecycleStateProvisioning, + "AVAILABLE": SubnetLifecycleStateAvailable, + "TERMINATING": SubnetLifecycleStateTerminating, + "TERMINATED": SubnetLifecycleStateTerminated, + "UPDATING": SubnetLifecycleStateUpdating, +} + +// GetSubnetLifecycleStateEnumValues Enumerates the set of values for SubnetLifecycleStateEnum +func GetSubnetLifecycleStateEnumValues() []SubnetLifecycleStateEnum { + values := make([]SubnetLifecycleStateEnum, 0) + for _, v := range mappingSubnetLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/subnet_topology.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/subnet_topology.go new file mode 100644 index 000000000..e7ad5b14e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/subnet_topology.go @@ -0,0 +1,107 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// SubnetTopology Defines the visualization of a subnet in a VCN. +type SubnetTopology struct { + + // Lists entities comprising the virtual network topology. + Entities []interface{} `mandatory:"true" json:"entities"` + + // Lists relationships between entities in the virtual network topology. + Relationships []TopologyEntityRelationship `mandatory:"true" json:"relationships"` + + // Records when the virtual network topology was created, in RFC3339 (https://tools.ietf.org/html/rfc3339) format for date and time. + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the subnet for which the visualization is generated. + SubnetId *string `mandatory:"false" json:"subnetId"` +} + +//GetEntities returns Entities +func (m SubnetTopology) GetEntities() []interface{} { + return m.Entities +} + +//GetRelationships returns Relationships +func (m SubnetTopology) GetRelationships() []TopologyEntityRelationship { + return m.Relationships +} + +//GetTimeCreated returns TimeCreated +func (m SubnetTopology) GetTimeCreated() *common.SDKTime { + return m.TimeCreated +} + +func (m SubnetTopology) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m SubnetTopology) MarshalJSON() (buff []byte, e error) { + type MarshalTypeSubnetTopology SubnetTopology + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeSubnetTopology + }{ + "SUBNET", + (MarshalTypeSubnetTopology)(m), + } + + return json.Marshal(&s) +} + +// UnmarshalJSON unmarshals from json +func (m *SubnetTopology) UnmarshalJSON(data []byte) (e error) { + model := struct { + SubnetId *string `json:"subnetId"` + Entities []interface{} `json:"entities"` + Relationships []topologyentityrelationship `json:"relationships"` + TimeCreated *common.SDKTime `json:"timeCreated"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.SubnetId = model.SubnetId + + m.Entities = make([]interface{}, len(model.Entities)) + for i, n := range model.Entities { + m.Entities[i] = n + } + + m.Relationships = make([]TopologyEntityRelationship, len(model.Relationships)) + for i, n := range model.Relationships { + nn, e = n.UnmarshalPolymorphicJSON(n.JsonData) + if e != nil { + return e + } + if nn != nil { + m.Relationships[i] = nn.(TopologyEntityRelationship) + } else { + m.Relationships[i] = nil + } + } + + m.TimeCreated = model.TimeCreated + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/tcp_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/tcp_options.go new file mode 100644 index 000000000..08d7212ec --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/tcp_options.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TcpOptions Optional and valid only for TCP. Use to specify particular destination ports for TCP rules. +// If you specify TCP as the protocol but omit this object, then all destination ports are allowed. +type TcpOptions struct { + DestinationPortRange *PortRange `mandatory:"false" json:"destinationPortRange"` + + SourcePortRange *PortRange `mandatory:"false" json:"sourcePortRange"` +} + +func (m TcpOptions) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_cluster_network_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_cluster_network_request_response.go new file mode 100644 index 000000000..7515c264d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_cluster_network_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// TerminateClusterNetworkRequest wrapper for the TerminateClusterNetwork operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/TerminateClusterNetwork.go.html to see an example of how to use TerminateClusterNetworkRequest. +type TerminateClusterNetworkRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the cluster network. + ClusterNetworkId *string `mandatory:"true" contributesTo:"path" name:"clusterNetworkId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request TerminateClusterNetworkRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request TerminateClusterNetworkRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request TerminateClusterNetworkRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request TerminateClusterNetworkRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// TerminateClusterNetworkResponse wrapper for the TerminateClusterNetwork operation +type TerminateClusterNetworkResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response TerminateClusterNetworkResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response TerminateClusterNetworkResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_instance_pool_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_instance_pool_request_response.go new file mode 100644 index 000000000..c542617d9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_instance_pool_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// TerminateInstancePoolRequest wrapper for the TerminateInstancePool operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/TerminateInstancePool.go.html to see an example of how to use TerminateInstancePoolRequest. +type TerminateInstancePoolRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" contributesTo:"path" name:"instancePoolId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request TerminateInstancePoolRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request TerminateInstancePoolRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request TerminateInstancePoolRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request TerminateInstancePoolRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// TerminateInstancePoolResponse wrapper for the TerminateInstancePool operation +type TerminateInstancePoolResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response TerminateInstancePoolResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response TerminateInstancePoolResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_instance_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_instance_request_response.go new file mode 100644 index 000000000..ec155b334 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_instance_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// TerminateInstanceRequest wrapper for the TerminateInstance operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/TerminateInstance.go.html to see an example of how to use TerminateInstanceRequest. +type TerminateInstanceRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance. + InstanceId *string `mandatory:"true" contributesTo:"path" name:"instanceId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Specifies whether to delete or preserve the boot volume when terminating an instance. + // When set to `true`, the boot volume is preserved. The default value is `false`. + PreserveBootVolume *bool `mandatory:"false" contributesTo:"query" name:"preserveBootVolume"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request TerminateInstanceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request TerminateInstanceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request TerminateInstanceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request TerminateInstanceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// TerminateInstanceResponse wrapper for the TerminateInstance operation +type TerminateInstanceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response TerminateInstanceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response TerminateInstanceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_preemption_action.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_preemption_action.go new file mode 100644 index 000000000..8d09a2ff0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/terminate_preemption_action.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TerminatePreemptionAction Terminates the preemptible instance when it is interrupted for eviction. +type TerminatePreemptionAction struct { + + // Whether to preserve the boot volume that was used to launch the preemptible instance when the instance is terminated. Defaults to false if not specified. + PreserveBootVolume *bool `mandatory:"false" json:"preserveBootVolume"` +} + +func (m TerminatePreemptionAction) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m TerminatePreemptionAction) MarshalJSON() (buff []byte, e error) { + type MarshalTypeTerminatePreemptionAction TerminatePreemptionAction + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeTerminatePreemptionAction + }{ + "TERMINATE", + (MarshalTypeTerminatePreemptionAction)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/topology.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/topology.go new file mode 100644 index 000000000..0e30d4146 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/topology.go @@ -0,0 +1,129 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Topology Defines the representation of a virtual network topology. +type Topology interface { + + // Lists entities comprising the virtual network topology. + GetEntities() []interface{} + + // Lists relationships between entities in the virtual network topology. + GetRelationships() []TopologyEntityRelationship + + // Records when the virtual network topology was created, in RFC3339 (https://tools.ietf.org/html/rfc3339) format for date and time. + GetTimeCreated() *common.SDKTime +} + +type topology struct { + JsonData []byte + Entities []interface{} `mandatory:"true" json:"entities"` + Relationships json.RawMessage `mandatory:"true" json:"relationships"` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *topology) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalertopology topology + s := struct { + Model Unmarshalertopology + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.Entities = s.Model.Entities + m.Relationships = s.Model.Relationships + m.TimeCreated = s.Model.TimeCreated + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *topology) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "VCN": + mm := VcnTopology{} + err = json.Unmarshal(data, &mm) + return mm, err + case "NETWORKING": + mm := NetworkingTopology{} + err = json.Unmarshal(data, &mm) + return mm, err + case "SUBNET": + mm := SubnetTopology{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetEntities returns Entities +func (m topology) GetEntities() []interface{} { + return m.Entities +} + +//GetRelationships returns Relationships +func (m topology) GetRelationships() json.RawMessage { + return m.Relationships +} + +//GetTimeCreated returns TimeCreated +func (m topology) GetTimeCreated() *common.SDKTime { + return m.TimeCreated +} + +func (m topology) String() string { + return common.PointerString(m) +} + +// TopologyTypeEnum Enum with underlying type: string +type TopologyTypeEnum string + +// Set of constants representing the allowable values for TopologyTypeEnum +const ( + TopologyTypeNetworking TopologyTypeEnum = "NETWORKING" + TopologyTypeVcn TopologyTypeEnum = "VCN" + TopologyTypeSubnet TopologyTypeEnum = "SUBNET" +) + +var mappingTopologyType = map[string]TopologyTypeEnum{ + "NETWORKING": TopologyTypeNetworking, + "VCN": TopologyTypeVcn, + "SUBNET": TopologyTypeSubnet, +} + +// GetTopologyTypeEnumValues Enumerates the set of values for TopologyTypeEnum +func GetTopologyTypeEnumValues() []TopologyTypeEnum { + values := make([]TopologyTypeEnum, 0) + for _, v := range mappingTopologyType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_associated_with_entity_relationship.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_associated_with_entity_relationship.go new file mode 100644 index 000000000..ae36867b3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_associated_with_entity_relationship.go @@ -0,0 +1,62 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TopologyAssociatedWithEntityRelationship Defines the `AssociatedWith` relationship between virtual network topology entities. An `AssociatedWith` relationship +// is defined when there is no obvious `contains` relationship but entities are still related. +// For example, a DRG is associated with a VCN because a DRG is not managed by VCN but can be +// attached to a VCN. +type TopologyAssociatedWithEntityRelationship struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the first entity in the relationship. + Id1 *string `mandatory:"true" json:"id1"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the second entity in the relationship. + Id2 *string `mandatory:"true" json:"id2"` + + AssociatedWithDetails *TopologyAssociatedWithRelationshipDetails `mandatory:"false" json:"associatedWithDetails"` +} + +//GetId1 returns Id1 +func (m TopologyAssociatedWithEntityRelationship) GetId1() *string { + return m.Id1 +} + +//GetId2 returns Id2 +func (m TopologyAssociatedWithEntityRelationship) GetId2() *string { + return m.Id2 +} + +func (m TopologyAssociatedWithEntityRelationship) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m TopologyAssociatedWithEntityRelationship) MarshalJSON() (buff []byte, e error) { + type MarshalTypeTopologyAssociatedWithEntityRelationship TopologyAssociatedWithEntityRelationship + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeTopologyAssociatedWithEntityRelationship + }{ + "ASSOCIATED_WITH", + (MarshalTypeTopologyAssociatedWithEntityRelationship)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_associated_with_relationship_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_associated_with_relationship_details.go new file mode 100644 index 000000000..ceda12dff --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_associated_with_relationship_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TopologyAssociatedWithRelationshipDetails Defines association details for an `associatedWith` relationship. +type TopologyAssociatedWithRelationshipDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the entities via which the relationship is created. For example an instance is associated with a network security group via the VNIC attachment and the VNIC. + Via []string `mandatory:"false" json:"via"` +} + +func (m TopologyAssociatedWithRelationshipDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_contains_entity_relationship.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_contains_entity_relationship.go new file mode 100644 index 000000000..5ce438474 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_contains_entity_relationship.go @@ -0,0 +1,60 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TopologyContainsEntityRelationship Defines the `contains` relationship between virtual network topology entities. A `Contains` relationship +// is defined when an entity fully owns, contains or manages another entity. +// For example, a subnet is contained and managed in the scope of a VCN, therefore a VCN has a +// `contains` relationship to a subnet. +type TopologyContainsEntityRelationship struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the first entity in the relationship. + Id1 *string `mandatory:"true" json:"id1"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the second entity in the relationship. + Id2 *string `mandatory:"true" json:"id2"` +} + +//GetId1 returns Id1 +func (m TopologyContainsEntityRelationship) GetId1() *string { + return m.Id1 +} + +//GetId2 returns Id2 +func (m TopologyContainsEntityRelationship) GetId2() *string { + return m.Id2 +} + +func (m TopologyContainsEntityRelationship) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m TopologyContainsEntityRelationship) MarshalJSON() (buff []byte, e error) { + type MarshalTypeTopologyContainsEntityRelationship TopologyContainsEntityRelationship + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeTopologyContainsEntityRelationship + }{ + "CONTAINS", + (MarshalTypeTopologyContainsEntityRelationship)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_entity_relationship.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_entity_relationship.go new file mode 100644 index 000000000..6bb58c22a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_entity_relationship.go @@ -0,0 +1,119 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TopologyEntityRelationship Defines the relationship between Virtual Network topology entities. +type TopologyEntityRelationship interface { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the first entity in the relationship. + GetId1() *string + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the second entity in the relationship. + GetId2() *string +} + +type topologyentityrelationship struct { + JsonData []byte + Id1 *string `mandatory:"true" json:"id1"` + Id2 *string `mandatory:"true" json:"id2"` + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *topologyentityrelationship) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalertopologyentityrelationship topologyentityrelationship + s := struct { + Model Unmarshalertopologyentityrelationship + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.Id1 = s.Model.Id1 + m.Id2 = s.Model.Id2 + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *topologyentityrelationship) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "ROUTES_TO": + mm := TopologyRoutesToEntityRelationship{} + err = json.Unmarshal(data, &mm) + return mm, err + case "ASSOCIATED_WITH": + mm := TopologyAssociatedWithEntityRelationship{} + err = json.Unmarshal(data, &mm) + return mm, err + case "CONTAINS": + mm := TopologyContainsEntityRelationship{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetId1 returns Id1 +func (m topologyentityrelationship) GetId1() *string { + return m.Id1 +} + +//GetId2 returns Id2 +func (m topologyentityrelationship) GetId2() *string { + return m.Id2 +} + +func (m topologyentityrelationship) String() string { + return common.PointerString(m) +} + +// TopologyEntityRelationshipTypeEnum Enum with underlying type: string +type TopologyEntityRelationshipTypeEnum string + +// Set of constants representing the allowable values for TopologyEntityRelationshipTypeEnum +const ( + TopologyEntityRelationshipTypeContains TopologyEntityRelationshipTypeEnum = "CONTAINS" + TopologyEntityRelationshipTypeAssociatedWith TopologyEntityRelationshipTypeEnum = "ASSOCIATED_WITH" + TopologyEntityRelationshipTypeRoutesTo TopologyEntityRelationshipTypeEnum = "ROUTES_TO" +) + +var mappingTopologyEntityRelationshipType = map[string]TopologyEntityRelationshipTypeEnum{ + "CONTAINS": TopologyEntityRelationshipTypeContains, + "ASSOCIATED_WITH": TopologyEntityRelationshipTypeAssociatedWith, + "ROUTES_TO": TopologyEntityRelationshipTypeRoutesTo, +} + +// GetTopologyEntityRelationshipTypeEnumValues Enumerates the set of values for TopologyEntityRelationshipTypeEnum +func GetTopologyEntityRelationshipTypeEnumValues() []TopologyEntityRelationshipTypeEnum { + values := make([]TopologyEntityRelationshipTypeEnum, 0) + for _, v := range mappingTopologyEntityRelationshipType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_routes_to_entity_relationship.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_routes_to_entity_relationship.go new file mode 100644 index 000000000..d119e3d3f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_routes_to_entity_relationship.go @@ -0,0 +1,61 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TopologyRoutesToEntityRelationship Defines the `routesTo` relationship between virtual network topology entities. A `RoutesTo` relationship +// is defined when a routing table and a routing rule are used to govern how to route traffic +// from one entity to another. For example, a DRG might have a routing rule to send certain traffic to an LPG. +type TopologyRoutesToEntityRelationship struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the first entity in the relationship. + Id1 *string `mandatory:"true" json:"id1"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the second entity in the relationship. + Id2 *string `mandatory:"true" json:"id2"` + + RouteRuleDetails *TopologyRoutesToRelationshipDetails `mandatory:"true" json:"routeRuleDetails"` +} + +//GetId1 returns Id1 +func (m TopologyRoutesToEntityRelationship) GetId1() *string { + return m.Id1 +} + +//GetId2 returns Id2 +func (m TopologyRoutesToEntityRelationship) GetId2() *string { + return m.Id2 +} + +func (m TopologyRoutesToEntityRelationship) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m TopologyRoutesToEntityRelationship) MarshalJSON() (buff []byte, e error) { + type MarshalTypeTopologyRoutesToEntityRelationship TopologyRoutesToEntityRelationship + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeTopologyRoutesToEntityRelationship + }{ + "ROUTES_TO", + (MarshalTypeTopologyRoutesToEntityRelationship)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_routes_to_relationship_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_routes_to_relationship_details.go new file mode 100644 index 000000000..2f4462817 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/topology_routes_to_relationship_details.go @@ -0,0 +1,63 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TopologyRoutesToRelationshipDetails Defines route rule details for a `routesTo` relationship. +type TopologyRoutesToRelationshipDetails struct { + + // The destinationType can be set to one of two values: + // * Use `CIDR_BLOCK` if the rule's `destination` is an IP address range in CIDR notation. + // * Use `SERVICE_CIDR_BLOCK` if the rule's `destination` is the `cidrBlock` value for a Service. + DestinationType *string `mandatory:"true" json:"destinationType"` + + // An IP address range in CIDR notation or the `cidrBlock` value for a Service. + Destination *string `mandatory:"true" json:"destination"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the routing table that contains the route rule. + RouteTableId *string `mandatory:"true" json:"routeTableId"` + + // A route rule can be `STATIC` if manually added to the route table or `DYNAMIC` if imported from another route table. + RouteType TopologyRoutesToRelationshipDetailsRouteTypeEnum `mandatory:"false" json:"routeType,omitempty"` +} + +func (m TopologyRoutesToRelationshipDetails) String() string { + return common.PointerString(m) +} + +// TopologyRoutesToRelationshipDetailsRouteTypeEnum Enum with underlying type: string +type TopologyRoutesToRelationshipDetailsRouteTypeEnum string + +// Set of constants representing the allowable values for TopologyRoutesToRelationshipDetailsRouteTypeEnum +const ( + TopologyRoutesToRelationshipDetailsRouteTypeStatic TopologyRoutesToRelationshipDetailsRouteTypeEnum = "STATIC" + TopologyRoutesToRelationshipDetailsRouteTypeDynamic TopologyRoutesToRelationshipDetailsRouteTypeEnum = "DYNAMIC" +) + +var mappingTopologyRoutesToRelationshipDetailsRouteType = map[string]TopologyRoutesToRelationshipDetailsRouteTypeEnum{ + "STATIC": TopologyRoutesToRelationshipDetailsRouteTypeStatic, + "DYNAMIC": TopologyRoutesToRelationshipDetailsRouteTypeDynamic, +} + +// GetTopologyRoutesToRelationshipDetailsRouteTypeEnumValues Enumerates the set of values for TopologyRoutesToRelationshipDetailsRouteTypeEnum +func GetTopologyRoutesToRelationshipDetailsRouteTypeEnumValues() []TopologyRoutesToRelationshipDetailsRouteTypeEnum { + values := make([]TopologyRoutesToRelationshipDetailsRouteTypeEnum, 0) + for _, v := range mappingTopologyRoutesToRelationshipDetailsRouteType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_config.go new file mode 100644 index 000000000..67e7ee0d2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_config.go @@ -0,0 +1,39 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TunnelConfig Deprecated. For tunnel information, instead see: +// * IPSecConnectionTunnel +// * IPSecConnectionTunnelSharedSecret +type TunnelConfig struct { + + // The IP address of Oracle's VPN headend. + // Example: `203.0.113.50 ` + IpAddress *string `mandatory:"true" json:"ipAddress"` + + // The shared secret of the IPSec tunnel. + SharedSecret *string `mandatory:"true" json:"sharedSecret"` + + // The date and time the IPSec connection was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` +} + +func (m TunnelConfig) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_cpe_device_config.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_cpe_device_config.go new file mode 100644 index 000000000..e54291a47 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_cpe_device_config.go @@ -0,0 +1,35 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TunnelCpeDeviceConfig The set of CPE configuration answers for the tunnel, which the customer provides in +// UpdateTunnelCpeDeviceConfig. +// The answers correlate to the questions that are specific to the CPE device type (see the +// `parameters` attribute of CpeDeviceShapeDetail). +// See these related operations: +// * GetTunnelCpeDeviceConfig +// * GetTunnelCpeDeviceConfigContent +// * GetIpsecCpeDeviceConfigContent +// * GetCpeDeviceConfigContent +type TunnelCpeDeviceConfig struct { + TunnelCpeDeviceConfigParameter []CpeDeviceConfigAnswer `mandatory:"false" json:"tunnelCpeDeviceConfigParameter"` +} + +func (m TunnelCpeDeviceConfig) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_phase_one_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_phase_one_details.go new file mode 100644 index 000000000..41ecd332a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_phase_one_details.go @@ -0,0 +1,60 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TunnelPhaseOneDetails Tunnel detail information specific to IPSec phase 1. +type TunnelPhaseOneDetails struct { + + // Indicates whether custom phase one configuration is enabled. + IsCustomPhaseOneConfig *bool `mandatory:"false" json:"isCustomPhaseOneConfig"` + + // The total configured lifetime of an IKE security association. + Lifetime *int64 `mandatory:"false" json:"lifetime"` + + // The lifetime remaining before the key is refreshed. + RemainingLifetime *int64 `mandatory:"false" json:"remainingLifetime"` + + // Custom authentication algorithm + CustomAuthenticationAlgorithm *string `mandatory:"false" json:"customAuthenticationAlgorithm"` + + // The negotiated authentication algorithm. + NegotiatedAuthenticationAlgorithm *string `mandatory:"false" json:"negotiatedAuthenticationAlgorithm"` + + // Custom encryption algorithm. + CustomEncryptionAlgorithm *string `mandatory:"false" json:"customEncryptionAlgorithm"` + + // The negotiated encryption algorithm. + NegotiatedEncryptionAlgorithm *string `mandatory:"false" json:"negotiatedEncryptionAlgorithm"` + + // Custom Diffie-Hellman group. + CustomDhGroup *string `mandatory:"false" json:"customDhGroup"` + + // The negotiated Diffie-Hellman group. + NegotiatedDhGroup *string `mandatory:"false" json:"negotiatedDhGroup"` + + // Indicates whether IKE Phase 1 is established. + IsIkeEstablished *bool `mandatory:"false" json:"isIkeEstablished"` + + // The date and time we retrieved the remaining lifetime, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + RemainingLifetimeLastRetrieved *common.SDKTime `mandatory:"false" json:"remainingLifetimeLastRetrieved"` +} + +func (m TunnelPhaseOneDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_phase_two_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_phase_two_details.go new file mode 100644 index 000000000..205f55114 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_phase_two_details.go @@ -0,0 +1,63 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TunnelPhaseTwoDetails Tunnel detail information specific to IPSec phase 2. +type TunnelPhaseTwoDetails struct { + + // Indicates whether custom phase two configuration is enabled. + IsCustomPhaseTwoConfig *bool `mandatory:"false" json:"isCustomPhaseTwoConfig"` + + // The total configured lifetime of an IKE security association. + Lifetime *int64 `mandatory:"false" json:"lifetime"` + + // The lifetime remaining before the key is refreshed. + RemainingLifetime *int64 `mandatory:"false" json:"remainingLifetime"` + + // Phase Two authentication algorithm supported during tunnel negotiation. + CustomAuthenticationAlgorithm *string `mandatory:"false" json:"customAuthenticationAlgorithm"` + + // The negotiated authentication algorithm. + NegotiatedAuthenticationAlgorithm *string `mandatory:"false" json:"negotiatedAuthenticationAlgorithm"` + + // Custom Encryption Algorithm + CustomEncryptionAlgorithm *string `mandatory:"false" json:"customEncryptionAlgorithm"` + + // The negotiated encryption algorithm. + NegotiatedEncryptionAlgorithm *string `mandatory:"false" json:"negotiatedEncryptionAlgorithm"` + + // Proposed Diffie-Hellman group. + DhGroup *string `mandatory:"false" json:"dhGroup"` + + // The negotiated Diffie-Hellman group. + NegotiatedDhGroup *string `mandatory:"false" json:"negotiatedDhGroup"` + + // ESP Phase 2 established + IsEspEstablished *bool `mandatory:"false" json:"isEspEstablished"` + + // Is PFS (perfect forward secrecy) enabled + IsPfsEnabled *bool `mandatory:"false" json:"isPfsEnabled"` + + // The date and time we retrieved the remaining lifetime, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + RemainingLifetimeLastRetrieved *common.SDKTime `mandatory:"false" json:"remainingLifetimeLastRetrieved"` +} + +func (m TunnelPhaseTwoDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_route_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_route_summary.go new file mode 100644 index 000000000..838f1d4f1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_route_summary.go @@ -0,0 +1,64 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TunnelRouteSummary The routes advertised to the Customer and the routes received from the Customer +type TunnelRouteSummary struct { + + // BGP Network Layer Reachability Information + Prefix *string `mandatory:"false" json:"prefix"` + + // The age of the route + Age *int64 `mandatory:"false" json:"age"` + + // Is this the best route + IsBestPath *bool `mandatory:"false" json:"isBestPath"` + + // List of ASNs in AS Path + AsPath []int `mandatory:"false" json:"asPath"` + + // Route advertiser + Advertiser TunnelRouteSummaryAdvertiserEnum `mandatory:"false" json:"advertiser,omitempty"` +} + +func (m TunnelRouteSummary) String() string { + return common.PointerString(m) +} + +// TunnelRouteSummaryAdvertiserEnum Enum with underlying type: string +type TunnelRouteSummaryAdvertiserEnum string + +// Set of constants representing the allowable values for TunnelRouteSummaryAdvertiserEnum +const ( + TunnelRouteSummaryAdvertiserCustomer TunnelRouteSummaryAdvertiserEnum = "CUSTOMER" + TunnelRouteSummaryAdvertiserOracle TunnelRouteSummaryAdvertiserEnum = "ORACLE" +) + +var mappingTunnelRouteSummaryAdvertiser = map[string]TunnelRouteSummaryAdvertiserEnum{ + "CUSTOMER": TunnelRouteSummaryAdvertiserCustomer, + "ORACLE": TunnelRouteSummaryAdvertiserOracle, +} + +// GetTunnelRouteSummaryAdvertiserEnumValues Enumerates the set of values for TunnelRouteSummaryAdvertiserEnum +func GetTunnelRouteSummaryAdvertiserEnumValues() []TunnelRouteSummaryAdvertiserEnum { + values := make([]TunnelRouteSummaryAdvertiserEnum, 0) + for _, v := range mappingTunnelRouteSummaryAdvertiser { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_security_association_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_security_association_summary.go new file mode 100644 index 000000000..13c609115 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_security_association_summary.go @@ -0,0 +1,72 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TunnelSecurityAssociationSummary Detailed Tunnel SA +type TunnelSecurityAssociationSummary struct { + + // IP and mask of the Partner Subnet for Policy Based VPNs or Static Routes + CpeSubnet *string `mandatory:"false" json:"cpeSubnet"` + + // IP and mask of the Local Subnet for Policy Based VPNs or Static Routes + OracleSubnet *string `mandatory:"false" json:"oracleSubnet"` + + // Phase 1 Status of the Tunnel + TunnelSaStatus TunnelSecurityAssociationSummaryTunnelSaStatusEnum `mandatory:"false" json:"tunnelSaStatus,omitempty"` + + // Current state if status is not up, including phase1/phase2 and possible reason for tunnel not up + TunnelSaErrorInfo *string `mandatory:"false" json:"tunnelSaErrorInfo"` + + // Seconds in current state + Time *string `mandatory:"false" json:"time"` +} + +func (m TunnelSecurityAssociationSummary) String() string { + return common.PointerString(m) +} + +// TunnelSecurityAssociationSummaryTunnelSaStatusEnum Enum with underlying type: string +type TunnelSecurityAssociationSummaryTunnelSaStatusEnum string + +// Set of constants representing the allowable values for TunnelSecurityAssociationSummaryTunnelSaStatusEnum +const ( + TunnelSecurityAssociationSummaryTunnelSaStatusInitiating TunnelSecurityAssociationSummaryTunnelSaStatusEnum = "INITIATING" + TunnelSecurityAssociationSummaryTunnelSaStatusListening TunnelSecurityAssociationSummaryTunnelSaStatusEnum = "LISTENING" + TunnelSecurityAssociationSummaryTunnelSaStatusUp TunnelSecurityAssociationSummaryTunnelSaStatusEnum = "UP" + TunnelSecurityAssociationSummaryTunnelSaStatusDown TunnelSecurityAssociationSummaryTunnelSaStatusEnum = "DOWN" + TunnelSecurityAssociationSummaryTunnelSaStatusError TunnelSecurityAssociationSummaryTunnelSaStatusEnum = "ERROR" + TunnelSecurityAssociationSummaryTunnelSaStatusUnknown TunnelSecurityAssociationSummaryTunnelSaStatusEnum = "UNKNOWN" +) + +var mappingTunnelSecurityAssociationSummaryTunnelSaStatus = map[string]TunnelSecurityAssociationSummaryTunnelSaStatusEnum{ + "INITIATING": TunnelSecurityAssociationSummaryTunnelSaStatusInitiating, + "LISTENING": TunnelSecurityAssociationSummaryTunnelSaStatusListening, + "UP": TunnelSecurityAssociationSummaryTunnelSaStatusUp, + "DOWN": TunnelSecurityAssociationSummaryTunnelSaStatusDown, + "ERROR": TunnelSecurityAssociationSummaryTunnelSaStatusError, + "UNKNOWN": TunnelSecurityAssociationSummaryTunnelSaStatusUnknown, +} + +// GetTunnelSecurityAssociationSummaryTunnelSaStatusEnumValues Enumerates the set of values for TunnelSecurityAssociationSummaryTunnelSaStatusEnum +func GetTunnelSecurityAssociationSummaryTunnelSaStatusEnumValues() []TunnelSecurityAssociationSummaryTunnelSaStatusEnum { + values := make([]TunnelSecurityAssociationSummaryTunnelSaStatusEnum, 0) + for _, v := range mappingTunnelSecurityAssociationSummaryTunnelSaStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_status.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_status.go new file mode 100644 index 000000000..c6ba9d8f9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/tunnel_status.go @@ -0,0 +1,68 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TunnelStatus Deprecated. For tunnel information, instead see IPSecConnectionTunnel. +type TunnelStatus struct { + + // The IP address of Oracle's VPN headend. + // Example: `203.0.113.50` + IpAddress *string `mandatory:"true" json:"ipAddress"` + + // The tunnel's current state. + LifecycleState TunnelStatusLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The date and time the IPSec connection was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // When the state of the tunnel last changed, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeStateModified *common.SDKTime `mandatory:"false" json:"timeStateModified"` +} + +func (m TunnelStatus) String() string { + return common.PointerString(m) +} + +// TunnelStatusLifecycleStateEnum Enum with underlying type: string +type TunnelStatusLifecycleStateEnum string + +// Set of constants representing the allowable values for TunnelStatusLifecycleStateEnum +const ( + TunnelStatusLifecycleStateUp TunnelStatusLifecycleStateEnum = "UP" + TunnelStatusLifecycleStateDown TunnelStatusLifecycleStateEnum = "DOWN" + TunnelStatusLifecycleStateDownForMaintenance TunnelStatusLifecycleStateEnum = "DOWN_FOR_MAINTENANCE" + TunnelStatusLifecycleStatePartialUp TunnelStatusLifecycleStateEnum = "PARTIAL_UP" +) + +var mappingTunnelStatusLifecycleState = map[string]TunnelStatusLifecycleStateEnum{ + "UP": TunnelStatusLifecycleStateUp, + "DOWN": TunnelStatusLifecycleStateDown, + "DOWN_FOR_MAINTENANCE": TunnelStatusLifecycleStateDownForMaintenance, + "PARTIAL_UP": TunnelStatusLifecycleStatePartialUp, +} + +// GetTunnelStatusLifecycleStateEnumValues Enumerates the set of values for TunnelStatusLifecycleStateEnum +func GetTunnelStatusLifecycleStateEnumValues() []TunnelStatusLifecycleStateEnum { + values := make([]TunnelStatusLifecycleStateEnum, 0) + for _, v := range mappingTunnelStatusLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/udp_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/udp_options.go new file mode 100644 index 000000000..e637b6989 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/udp_options.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UdpOptions Optional and valid only for UDP. Use to specify particular destination ports for UDP rules. +// If you specify UDP as the protocol but omit this object, then all destination ports are allowed. +type UdpOptions struct { + DestinationPortRange *PortRange `mandatory:"false" json:"destinationPortRange"` + + SourcePortRange *PortRange `mandatory:"false" json:"sourcePortRange"` +} + +func (m UdpOptions) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_backup_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_backup_details.go new file mode 100644 index 000000000..40e667bb2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_backup_details.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateBootVolumeBackupDetails The representation of UpdateBootVolumeBackupDetails +type UpdateBootVolumeBackupDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m UpdateBootVolumeBackupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_backup_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_backup_request_response.go new file mode 100644 index 000000000..b7372eb0c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_backup_request_response.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateBootVolumeBackupRequest wrapper for the UpdateBootVolumeBackup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateBootVolumeBackup.go.html to see an example of how to use UpdateBootVolumeBackupRequest. +type UpdateBootVolumeBackupRequest struct { + + // The OCID of the boot volume backup. + BootVolumeBackupId *string `mandatory:"true" contributesTo:"path" name:"bootVolumeBackupId"` + + // Update boot volume backup fields + UpdateBootVolumeBackupDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateBootVolumeBackupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateBootVolumeBackupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateBootVolumeBackupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateBootVolumeBackupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateBootVolumeBackupResponse wrapper for the UpdateBootVolumeBackup operation +type UpdateBootVolumeBackupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The BootVolumeBackup instance + BootVolumeBackup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateBootVolumeBackupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateBootVolumeBackupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_details.go new file mode 100644 index 000000000..f260e7eac --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_details.go @@ -0,0 +1,58 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateBootVolumeDetails The representation of UpdateBootVolumeDetails +type UpdateBootVolumeDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The size to resize the volume to in GBs. Has to be larger than the current size. + SizeInGBs *int64 `mandatory:"false" json:"sizeInGBs"` + + // The number of volume performance units (VPUs) that will be applied to this volume per GB, + // representing the Block Volume service's elastic performance options. + // See Block Volume Elastic Performance (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/blockvolumeelasticperformance.htm) for more information. + // Allowed values: + // * `10`: Represents Balanced option. + // * `20`: Represents Higher Performance option. + VpusPerGB *int64 `mandatory:"false" json:"vpusPerGB"` + + // Specifies whether the auto-tune performance is enabled for this boot volume. + IsAutoTuneEnabled *bool `mandatory:"false" json:"isAutoTuneEnabled"` + + // The list of boot volume replicas that this boot volume will be updated to have + // in the specified destination availability domains. + BootVolumeReplicas []BootVolumeReplicaDetails `mandatory:"false" json:"bootVolumeReplicas"` +} + +func (m UpdateBootVolumeDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_kms_key_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_kms_key_details.go new file mode 100644 index 000000000..7b6131418 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_kms_key_details.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateBootVolumeKmsKeyDetails The representation of UpdateBootVolumeKmsKeyDetails +type UpdateBootVolumeKmsKeyDetails struct { + + // The OCID of the new Key Management key to assign to protect the specified volume. + // This key has to be a valid Key Management key, and policies must exist to allow the user and the Block Volume service to access this key. + // If you specify the same OCID as the previous key's OCID, the Block Volume service will use it to regenerate a volume encryption key. + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` +} + +func (m UpdateBootVolumeKmsKeyDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_kms_key_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_kms_key_request_response.go new file mode 100644 index 000000000..91c3202fe --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_kms_key_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateBootVolumeKmsKeyRequest wrapper for the UpdateBootVolumeKmsKey operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateBootVolumeKmsKey.go.html to see an example of how to use UpdateBootVolumeKmsKeyRequest. +type UpdateBootVolumeKmsKeyRequest struct { + + // The OCID of the boot volume. + BootVolumeId *string `mandatory:"true" contributesTo:"path" name:"bootVolumeId"` + + // Updates the Key Management master encryption key assigned to the specified boot volume. + UpdateBootVolumeKmsKeyDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateBootVolumeKmsKeyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateBootVolumeKmsKeyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateBootVolumeKmsKeyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateBootVolumeKmsKeyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateBootVolumeKmsKeyResponse wrapper for the UpdateBootVolumeKmsKey operation +type UpdateBootVolumeKmsKeyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The BootVolumeKmsKey instance + BootVolumeKmsKey `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateBootVolumeKmsKeyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateBootVolumeKmsKeyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_request_response.go new file mode 100644 index 000000000..87127ee09 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_boot_volume_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateBootVolumeRequest wrapper for the UpdateBootVolume operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateBootVolume.go.html to see an example of how to use UpdateBootVolumeRequest. +type UpdateBootVolumeRequest struct { + + // The OCID of the boot volume. + BootVolumeId *string `mandatory:"true" contributesTo:"path" name:"bootVolumeId"` + + // Update boot volume's display name. + UpdateBootVolumeDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateBootVolumeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateBootVolumeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateBootVolumeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateBootVolumeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateBootVolumeResponse wrapper for the UpdateBootVolume operation +type UpdateBootVolumeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The BootVolume instance + BootVolume `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateBootVolumeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateBootVolumeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_byoip_range_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_byoip_range_details.go new file mode 100644 index 000000000..3cf19df90 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_byoip_range_details.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateByoipRangeDetails The information used to update a `ByoipRange` resource. +type UpdateByoipRangeDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m UpdateByoipRangeDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_byoip_range_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_byoip_range_request_response.go new file mode 100644 index 000000000..0b04e91fe --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_byoip_range_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateByoipRangeRequest wrapper for the UpdateByoipRange operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateByoipRange.go.html to see an example of how to use UpdateByoipRangeRequest. +type UpdateByoipRangeRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the `ByoipRange` resource containing the BYOIP CIDR block. + ByoipRangeId *string `mandatory:"true" contributesTo:"path" name:"byoipRangeId"` + + // Byoip Range details. + UpdateByoipRangeDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateByoipRangeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateByoipRangeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateByoipRangeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateByoipRangeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateByoipRangeResponse wrapper for the UpdateByoipRange operation +type UpdateByoipRangeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ByoipRange instance + ByoipRange `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateByoipRangeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateByoipRangeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cluster_network_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cluster_network_details.go new file mode 100644 index 000000000..6f86c51dd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cluster_network_details.go @@ -0,0 +1,43 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateClusterNetworkDetails The data to update a cluster network. +type UpdateClusterNetworkDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The instance pools in the cluster network to update. + InstancePools []UpdateClusterNetworkInstancePoolDetails `mandatory:"false" json:"instancePools"` +} + +func (m UpdateClusterNetworkDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cluster_network_instance_pool_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cluster_network_instance_pool_details.go new file mode 100644 index 000000000..912a5893a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cluster_network_instance_pool_details.go @@ -0,0 +1,46 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateClusterNetworkInstancePoolDetails The data to update an instance pool within a cluster network. +type UpdateClusterNetworkInstancePoolDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + Id *string `mandatory:"true" json:"id"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The number of instances that should be in the instance pool. + Size *int `mandatory:"false" json:"size"` +} + +func (m UpdateClusterNetworkInstancePoolDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cluster_network_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cluster_network_request_response.go new file mode 100644 index 000000000..64c72698b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cluster_network_request_response.go @@ -0,0 +1,92 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateClusterNetworkRequest wrapper for the UpdateClusterNetwork operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateClusterNetwork.go.html to see an example of how to use UpdateClusterNetworkRequest. +type UpdateClusterNetworkRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the cluster network. + ClusterNetworkId *string `mandatory:"true" contributesTo:"path" name:"clusterNetworkId"` + + // Update cluster network + UpdateClusterNetworkDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateClusterNetworkRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateClusterNetworkRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateClusterNetworkRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateClusterNetworkRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateClusterNetworkResponse wrapper for the UpdateClusterNetwork operation +type UpdateClusterNetworkResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ClusterNetwork instance + ClusterNetwork `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateClusterNetworkResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateClusterNetworkResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_capacity_reservation_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_capacity_reservation_details.go new file mode 100644 index 000000000..52f2d5c0b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_capacity_reservation_details.go @@ -0,0 +1,49 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateComputeCapacityReservationDetails Details for updating the compute capacity reservation. +type UpdateComputeCapacityReservationDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Whether this capacity reservation is the default. + // For more information, see Capacity Reservations (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/reserve-capacity.htm#default). + IsDefaultReservation *bool `mandatory:"false" json:"isDefaultReservation"` + + // The capacity configurations for the capacity reservation. + // To use the reservation for the desired shape, specify the shape, count, and + // optionally the fault domain where you want this configuration. + InstanceReservationConfigs []InstanceReservationConfigDetails `mandatory:"false" json:"instanceReservationConfigs"` +} + +func (m UpdateComputeCapacityReservationDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_capacity_reservation_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_capacity_reservation_request_response.go new file mode 100644 index 000000000..3cc230323 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_capacity_reservation_request_response.go @@ -0,0 +1,83 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateComputeCapacityReservationRequest wrapper for the UpdateComputeCapacityReservation operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateComputeCapacityReservation.go.html to see an example of how to use UpdateComputeCapacityReservationRequest. +type UpdateComputeCapacityReservationRequest struct { + + // The OCID of the compute capacity reservation. + CapacityReservationId *string `mandatory:"true" contributesTo:"path" name:"capacityReservationId"` + + // Update compute capacity reservation details. + UpdateComputeCapacityReservationDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateComputeCapacityReservationRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateComputeCapacityReservationRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateComputeCapacityReservationRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateComputeCapacityReservationRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateComputeCapacityReservationResponse wrapper for the UpdateComputeCapacityReservation operation +type UpdateComputeCapacityReservationResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response UpdateComputeCapacityReservationResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateComputeCapacityReservationResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_image_capability_schema_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_image_capability_schema_details.go new file mode 100644 index 000000000..9b18f08cc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_image_capability_schema_details.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateComputeImageCapabilitySchemaDetails Create Image Capability Schema for an image. +type UpdateComputeImageCapabilitySchemaDetails struct { + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The map of each capability name to its ImageCapabilitySchemaDescriptor. + SchemaData map[string]ImageCapabilitySchemaDescriptor `mandatory:"false" json:"schemaData"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m UpdateComputeImageCapabilitySchemaDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *UpdateComputeImageCapabilitySchemaDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + DisplayName *string `json:"displayName"` + FreeformTags map[string]string `json:"freeformTags"` + SchemaData map[string]imagecapabilityschemadescriptor `json:"schemaData"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.DisplayName = model.DisplayName + + m.FreeformTags = model.FreeformTags + + m.SchemaData = make(map[string]ImageCapabilitySchemaDescriptor) + for k, v := range model.SchemaData { + nn, e = v.UnmarshalPolymorphicJSON(v.JsonData) + if e != nil { + return e + } + if nn != nil { + m.SchemaData[k] = nn.(ImageCapabilitySchemaDescriptor) + } else { + m.SchemaData[k] = nil + } + } + + m.DefinedTags = model.DefinedTags + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_image_capability_schema_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_image_capability_schema_request_response.go new file mode 100644 index 000000000..dde24ca43 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_compute_image_capability_schema_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateComputeImageCapabilitySchemaRequest wrapper for the UpdateComputeImageCapabilitySchema operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateComputeImageCapabilitySchema.go.html to see an example of how to use UpdateComputeImageCapabilitySchemaRequest. +type UpdateComputeImageCapabilitySchemaRequest struct { + + // The id of the compute image capability schema or the image ocid + ComputeImageCapabilitySchemaId *string `mandatory:"true" contributesTo:"path" name:"computeImageCapabilitySchemaId"` + + // Updates the freeFormTags, definedTags, and display name of the image capability schema + UpdateComputeImageCapabilitySchemaDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateComputeImageCapabilitySchemaRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateComputeImageCapabilitySchemaRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateComputeImageCapabilitySchemaRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateComputeImageCapabilitySchemaRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateComputeImageCapabilitySchemaResponse wrapper for the UpdateComputeImageCapabilitySchema operation +type UpdateComputeImageCapabilitySchemaResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ComputeImageCapabilitySchema instance + ComputeImageCapabilitySchema `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateComputeImageCapabilitySchemaResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateComputeImageCapabilitySchemaResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_console_history_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_console_history_details.go new file mode 100644 index 000000000..85b06886a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_console_history_details.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateConsoleHistoryDetails The representation of UpdateConsoleHistoryDetails +type UpdateConsoleHistoryDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m UpdateConsoleHistoryDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_console_history_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_console_history_request_response.go new file mode 100644 index 000000000..c5117a318 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_console_history_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateConsoleHistoryRequest wrapper for the UpdateConsoleHistory operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateConsoleHistory.go.html to see an example of how to use UpdateConsoleHistoryRequest. +type UpdateConsoleHistoryRequest struct { + + // The OCID of the console history. + InstanceConsoleHistoryId *string `mandatory:"true" contributesTo:"path" name:"instanceConsoleHistoryId"` + + // Update instance fields + UpdateConsoleHistoryDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateConsoleHistoryRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateConsoleHistoryRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateConsoleHistoryRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateConsoleHistoryRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateConsoleHistoryResponse wrapper for the UpdateConsoleHistory operation +type UpdateConsoleHistoryResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ConsoleHistory instance + ConsoleHistory `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateConsoleHistoryResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateConsoleHistoryResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cpe_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cpe_details.go new file mode 100644 index 000000000..1b7787761 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cpe_details.go @@ -0,0 +1,51 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateCpeDetails The representation of UpdateCpeDetails +type UpdateCpeDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the CPE device type. You can provide + // a value if you want to generate CPE device configuration content for IPSec connections + // that use this CPE. For a list of possible values, see + // ListCpeDeviceShapes. + // For more information about generating CPE device configuration content, see: + // * GetCpeDeviceConfigContent + // * GetIpsecCpeDeviceConfigContent + // * GetTunnelCpeDeviceConfigContent + // * GetTunnelCpeDeviceConfig + CpeDeviceShapeId *string `mandatory:"false" json:"cpeDeviceShapeId"` +} + +func (m UpdateCpeDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cpe_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cpe_request_response.go new file mode 100644 index 000000000..5bd153344 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cpe_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateCpeRequest wrapper for the UpdateCpe operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateCpe.go.html to see an example of how to use UpdateCpeRequest. +type UpdateCpeRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the CPE. + CpeId *string `mandatory:"true" contributesTo:"path" name:"cpeId"` + + // Details object for updating a CPE. + UpdateCpeDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateCpeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateCpeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateCpeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateCpeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateCpeResponse wrapper for the UpdateCpe operation +type UpdateCpeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Cpe instance + Cpe `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateCpeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateCpeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_details.go new file mode 100644 index 000000000..68c979d98 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_details.go @@ -0,0 +1,51 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateCrossConnectDetails Update a CrossConnect +type UpdateCrossConnectDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Set to true to activate the cross-connect. You activate it after the physical cabling + // is complete, and you've confirmed the cross-connect's light levels are good and your side + // of the interface is up. Activation indicates to Oracle that the physical connection is ready. + // Example: `true` + IsActive *bool `mandatory:"false" json:"isActive"` + + // A reference name or identifier for the physical fiber connection this cross-connect uses. + CustomerReferenceName *string `mandatory:"false" json:"customerReferenceName"` + + MacsecProperties *UpdateMacsecProperties `mandatory:"false" json:"macsecProperties"` +} + +func (m UpdateCrossConnectDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_group_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_group_details.go new file mode 100644 index 000000000..fbf710f25 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_group_details.go @@ -0,0 +1,45 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateCrossConnectGroupDetails The representation of UpdateCrossConnectGroupDetails +type UpdateCrossConnectGroupDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // A reference name or identifier for the physical fiber connection this cross-connect group uses. + CustomerReferenceName *string `mandatory:"false" json:"customerReferenceName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + MacsecProperties *UpdateMacsecProperties `mandatory:"false" json:"macsecProperties"` +} + +func (m UpdateCrossConnectGroupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_group_request_response.go new file mode 100644 index 000000000..caf6c299c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_group_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateCrossConnectGroupRequest wrapper for the UpdateCrossConnectGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateCrossConnectGroup.go.html to see an example of how to use UpdateCrossConnectGroupRequest. +type UpdateCrossConnectGroupRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the cross-connect group. + CrossConnectGroupId *string `mandatory:"true" contributesTo:"path" name:"crossConnectGroupId"` + + // Update CrossConnectGroup fields + UpdateCrossConnectGroupDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateCrossConnectGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateCrossConnectGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateCrossConnectGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateCrossConnectGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateCrossConnectGroupResponse wrapper for the UpdateCrossConnectGroup operation +type UpdateCrossConnectGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The CrossConnectGroup instance + CrossConnectGroup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateCrossConnectGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateCrossConnectGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_request_response.go new file mode 100644 index 000000000..dfbc1e745 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_cross_connect_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateCrossConnectRequest wrapper for the UpdateCrossConnect operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateCrossConnect.go.html to see an example of how to use UpdateCrossConnectRequest. +type UpdateCrossConnectRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the cross-connect. + CrossConnectId *string `mandatory:"true" contributesTo:"path" name:"crossConnectId"` + + // Update CrossConnect fields. + UpdateCrossConnectDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateCrossConnectRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateCrossConnectRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateCrossConnectRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateCrossConnectRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateCrossConnectResponse wrapper for the UpdateCrossConnect operation +type UpdateCrossConnectResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The CrossConnect instance + CrossConnect `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateCrossConnectResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateCrossConnectResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_dedicated_vm_host_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_dedicated_vm_host_details.go new file mode 100644 index 000000000..42d048cf7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_dedicated_vm_host_details.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateDedicatedVmHostDetails Details for updating the dedicated virtual machine host details. +type UpdateDedicatedVmHostDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m UpdateDedicatedVmHostDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_dedicated_vm_host_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_dedicated_vm_host_request_response.go new file mode 100644 index 000000000..48768f354 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_dedicated_vm_host_request_response.go @@ -0,0 +1,92 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateDedicatedVmHostRequest wrapper for the UpdateDedicatedVmHost operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDedicatedVmHost.go.html to see an example of how to use UpdateDedicatedVmHostRequest. +type UpdateDedicatedVmHostRequest struct { + + // The OCID of the dedicated VM host. + DedicatedVmHostId *string `mandatory:"true" contributesTo:"path" name:"dedicatedVmHostId"` + + // Update dedicated VM host details + UpdateDedicatedVmHostDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateDedicatedVmHostRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateDedicatedVmHostRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateDedicatedVmHostRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateDedicatedVmHostRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateDedicatedVmHostResponse wrapper for the UpdateDedicatedVmHost operation +type UpdateDedicatedVmHostResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DedicatedVmHost instance + DedicatedVmHost `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateDedicatedVmHostResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateDedicatedVmHostResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_dhcp_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_dhcp_details.go new file mode 100644 index 000000000..5d3755009 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_dhcp_details.go @@ -0,0 +1,110 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateDhcpDetails The representation of UpdateDhcpDetails +type UpdateDhcpDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + Options []DhcpOption `mandatory:"false" json:"options"` + + // The search domain name type of DHCP options + DomainNameType UpdateDhcpDetailsDomainNameTypeEnum `mandatory:"false" json:"domainNameType,omitempty"` +} + +func (m UpdateDhcpDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *UpdateDhcpDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + DisplayName *string `json:"displayName"` + FreeformTags map[string]string `json:"freeformTags"` + Options []dhcpoption `json:"options"` + DomainNameType UpdateDhcpDetailsDomainNameTypeEnum `json:"domainNameType"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.DefinedTags = model.DefinedTags + + m.DisplayName = model.DisplayName + + m.FreeformTags = model.FreeformTags + + m.Options = make([]DhcpOption, len(model.Options)) + for i, n := range model.Options { + nn, e = n.UnmarshalPolymorphicJSON(n.JsonData) + if e != nil { + return e + } + if nn != nil { + m.Options[i] = nn.(DhcpOption) + } else { + m.Options[i] = nil + } + } + + m.DomainNameType = model.DomainNameType + + return +} + +// UpdateDhcpDetailsDomainNameTypeEnum Enum with underlying type: string +type UpdateDhcpDetailsDomainNameTypeEnum string + +// Set of constants representing the allowable values for UpdateDhcpDetailsDomainNameTypeEnum +const ( + UpdateDhcpDetailsDomainNameTypeSubnetDomain UpdateDhcpDetailsDomainNameTypeEnum = "SUBNET_DOMAIN" + UpdateDhcpDetailsDomainNameTypeVcnDomain UpdateDhcpDetailsDomainNameTypeEnum = "VCN_DOMAIN" + UpdateDhcpDetailsDomainNameTypeCustomDomain UpdateDhcpDetailsDomainNameTypeEnum = "CUSTOM_DOMAIN" +) + +var mappingUpdateDhcpDetailsDomainNameType = map[string]UpdateDhcpDetailsDomainNameTypeEnum{ + "SUBNET_DOMAIN": UpdateDhcpDetailsDomainNameTypeSubnetDomain, + "VCN_DOMAIN": UpdateDhcpDetailsDomainNameTypeVcnDomain, + "CUSTOM_DOMAIN": UpdateDhcpDetailsDomainNameTypeCustomDomain, +} + +// GetUpdateDhcpDetailsDomainNameTypeEnumValues Enumerates the set of values for UpdateDhcpDetailsDomainNameTypeEnum +func GetUpdateDhcpDetailsDomainNameTypeEnumValues() []UpdateDhcpDetailsDomainNameTypeEnum { + values := make([]UpdateDhcpDetailsDomainNameTypeEnum, 0) + for _, v := range mappingUpdateDhcpDetailsDomainNameType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_dhcp_options_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_dhcp_options_request_response.go new file mode 100644 index 000000000..a7bdbc91e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_dhcp_options_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateDhcpOptionsRequest wrapper for the UpdateDhcpOptions operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDhcpOptions.go.html to see an example of how to use UpdateDhcpOptionsRequest. +type UpdateDhcpOptionsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) for the set of DHCP options. + DhcpId *string `mandatory:"true" contributesTo:"path" name:"dhcpId"` + + // Request object for updating a set of DHCP options. + UpdateDhcpDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateDhcpOptionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateDhcpOptionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateDhcpOptionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateDhcpOptionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateDhcpOptionsResponse wrapper for the UpdateDhcpOptions operation +type UpdateDhcpOptionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DhcpOptions instance + DhcpOptions `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateDhcpOptionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateDhcpOptionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_attachment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_attachment_details.go new file mode 100644 index 000000000..79172270f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_attachment_details.go @@ -0,0 +1,102 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateDrgAttachmentDetails The representation of UpdateDrgAttachmentDetails +type UpdateDrgAttachmentDetails struct { + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the DRG route table that is assigned to this attachment. + // The DRG route table manages traffic inside the DRG. + // You can't remove a DRG route table from a DRG attachment, but you can reassign which + // DRG route table it uses. + DrgRouteTableId *string `mandatory:"false" json:"drgRouteTableId"` + + NetworkDetails DrgAttachmentNetworkUpdateDetails `mandatory:"false" json:"networkDetails"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the export route distribution used to specify how routes in the assigned DRG route table + // are advertised out through the attachment. + // If this value is null, no routes are advertised through this attachment. + ExportDrgRouteDistributionId *string `mandatory:"false" json:"exportDrgRouteDistributionId"` + + // This is the OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the route table that is used to route the traffic as it enters a VCN through this attachment. + // For information about why you would associate a route table with a DRG attachment, see: + // * Transit Routing: Access to Multiple VCNs in Same Region (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitrouting.htm) + // * Transit Routing: Private Access to Oracle Services (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitroutingoracleservices.htm) + RouteTableId *string `mandatory:"false" json:"routeTableId"` +} + +func (m UpdateDrgAttachmentDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *UpdateDrgAttachmentDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + DisplayName *string `json:"displayName"` + DrgRouteTableId *string `json:"drgRouteTableId"` + NetworkDetails drgattachmentnetworkupdatedetails `json:"networkDetails"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + FreeformTags map[string]string `json:"freeformTags"` + ExportDrgRouteDistributionId *string `json:"exportDrgRouteDistributionId"` + RouteTableId *string `json:"routeTableId"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.DisplayName = model.DisplayName + + m.DrgRouteTableId = model.DrgRouteTableId + + nn, e = model.NetworkDetails.UnmarshalPolymorphicJSON(model.NetworkDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.NetworkDetails = nn.(DrgAttachmentNetworkUpdateDetails) + } else { + m.NetworkDetails = nil + } + + m.DefinedTags = model.DefinedTags + + m.FreeformTags = model.FreeformTags + + m.ExportDrgRouteDistributionId = model.ExportDrgRouteDistributionId + + m.RouteTableId = model.RouteTableId + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_attachment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_attachment_request_response.go new file mode 100644 index 000000000..568e1baa3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_attachment_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateDrgAttachmentRequest wrapper for the UpdateDrgAttachment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDrgAttachment.go.html to see an example of how to use UpdateDrgAttachmentRequest. +type UpdateDrgAttachmentRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG attachment. + DrgAttachmentId *string `mandatory:"true" contributesTo:"path" name:"drgAttachmentId"` + + // Details object for updating a `DrgAttachment`. + UpdateDrgAttachmentDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateDrgAttachmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateDrgAttachmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateDrgAttachmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateDrgAttachmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateDrgAttachmentResponse wrapper for the UpdateDrgAttachment operation +type UpdateDrgAttachmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DrgAttachment instance + DrgAttachment `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateDrgAttachmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateDrgAttachmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_details.go new file mode 100644 index 000000000..235576851 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_details.go @@ -0,0 +1,42 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateDrgDetails The representation of UpdateDrgDetails +type UpdateDrgDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + DefaultDrgRouteTables *DefaultDrgRouteTables `mandatory:"false" json:"defaultDrgRouteTables"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m UpdateDrgDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_request_response.go new file mode 100644 index 000000000..fc33e1375 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateDrgRequest wrapper for the UpdateDrg operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDrg.go.html to see an example of how to use UpdateDrgRequest. +type UpdateDrgRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"true" contributesTo:"path" name:"drgId"` + + // Details object for updating a DRG. + UpdateDrgDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateDrgRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateDrgRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateDrgRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateDrgRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateDrgResponse wrapper for the UpdateDrg operation +type UpdateDrgResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Drg instance + Drg `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateDrgResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateDrgResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_details.go new file mode 100644 index 000000000..9c2670fcb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_details.go @@ -0,0 +1,41 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateDrgRouteDistributionDetails Details used in a request to update a route distribution. +// You cannot assign a table to a virtual circuit or IPSec tunnel attachment if there is a static route rule for an RPC attachment. +type UpdateDrgRouteDistributionDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m UpdateDrgRouteDistributionDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_request_response.go new file mode 100644 index 000000000..619c0d2fe --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateDrgRouteDistributionRequest wrapper for the UpdateDrgRouteDistribution operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDrgRouteDistribution.go.html to see an example of how to use UpdateDrgRouteDistributionRequest. +type UpdateDrgRouteDistributionRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route distribution. + DrgRouteDistributionId *string `mandatory:"true" contributesTo:"path" name:"drgRouteDistributionId"` + + // Details object for updating a route distribution + UpdateDrgRouteDistributionDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateDrgRouteDistributionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateDrgRouteDistributionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateDrgRouteDistributionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateDrgRouteDistributionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateDrgRouteDistributionResponse wrapper for the UpdateDrgRouteDistribution operation +type UpdateDrgRouteDistributionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DrgRouteDistribution instance + DrgRouteDistribution `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateDrgRouteDistributionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateDrgRouteDistributionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_statement_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_statement_details.go new file mode 100644 index 000000000..885a0ab8a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_statement_details.go @@ -0,0 +1,70 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateDrgRouteDistributionStatementDetails Route distribution statements to update in the route distribution. +type UpdateDrgRouteDistributionStatementDetails struct { + + // The Oracle-assigned ID of each route distribution statement to be updated. + Id *string `mandatory:"true" json:"id"` + + // The action is applied only if all of the match criteria is met. + // If there are no match criteria in a statement, match ALL is implied. + MatchCriteria []DrgRouteDistributionMatchCriteria `mandatory:"false" json:"matchCriteria"` + + // The priority of the statement you'd like to update. + Priority *int `mandatory:"false" json:"priority"` +} + +func (m UpdateDrgRouteDistributionStatementDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *UpdateDrgRouteDistributionStatementDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + MatchCriteria []drgroutedistributionmatchcriteria `json:"matchCriteria"` + Priority *int `json:"priority"` + Id *string `json:"id"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.MatchCriteria = make([]DrgRouteDistributionMatchCriteria, len(model.MatchCriteria)) + for i, n := range model.MatchCriteria { + nn, e = n.UnmarshalPolymorphicJSON(n.JsonData) + if e != nil { + return e + } + if nn != nil { + m.MatchCriteria[i] = nn.(DrgRouteDistributionMatchCriteria) + } else { + m.MatchCriteria[i] = nil + } + } + + m.Priority = model.Priority + + m.Id = model.Id + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_statements_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_statements_details.go new file mode 100644 index 000000000..c620c4a81 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_statements_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateDrgRouteDistributionStatementsDetails Details request to update statements in a route distribution. +type UpdateDrgRouteDistributionStatementsDetails struct { + + // The route distribution statements to update, and the details to be updated. + Statements []UpdateDrgRouteDistributionStatementDetails `mandatory:"true" json:"statements"` +} + +func (m UpdateDrgRouteDistributionStatementsDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_statements_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_statements_request_response.go new file mode 100644 index 000000000..5b3ee2610 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_distribution_statements_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateDrgRouteDistributionStatementsRequest wrapper for the UpdateDrgRouteDistributionStatements operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDrgRouteDistributionStatements.go.html to see an example of how to use UpdateDrgRouteDistributionStatementsRequest. +type UpdateDrgRouteDistributionStatementsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route distribution. + DrgRouteDistributionId *string `mandatory:"true" contributesTo:"path" name:"drgRouteDistributionId"` + + // Request to update one or more route distribution statements in the route distribution. + UpdateDrgRouteDistributionStatementsDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateDrgRouteDistributionStatementsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateDrgRouteDistributionStatementsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateDrgRouteDistributionStatementsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateDrgRouteDistributionStatementsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateDrgRouteDistributionStatementsResponse wrapper for the UpdateDrgRouteDistributionStatements operation +type UpdateDrgRouteDistributionStatementsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []DrgRouteDistributionStatement instance + Items []DrgRouteDistributionStatement `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateDrgRouteDistributionStatementsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateDrgRouteDistributionStatementsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_rule_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_rule_details.go new file mode 100644 index 000000000..627587035 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_rule_details.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateDrgRouteRuleDetails Details used to update a route rule in the DRG route table. +type UpdateDrgRouteRuleDetails struct { + + // The Oracle-assigned ID of each DRG route rule to update. + Id *string `mandatory:"true" json:"id"` + + // The range of IP addresses used for matching when routing traffic. + // Potential values: + // * IP address range in CIDR notation. Can be an IPv4 or IPv6 CIDR. For example: `192.168.1.0/24` + // or `2001:0db8:0123:45::/56`. + Destination *string `mandatory:"false" json:"destination"` + + // Type of destination for the rule. Required if `direction` = `EGRESS`. + // Allowed values: + // * `CIDR_BLOCK`: If the rule's `destination` is an IP address range in CIDR notation. + DestinationType UpdateDrgRouteRuleDetailsDestinationTypeEnum `mandatory:"false" json:"destinationType,omitempty"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the next hop DRG attachment. The next hop DRG attachment is responsible + // for reaching the network destination. + NextHopDrgAttachmentId *string `mandatory:"false" json:"nextHopDrgAttachmentId"` +} + +func (m UpdateDrgRouteRuleDetails) String() string { + return common.PointerString(m) +} + +// UpdateDrgRouteRuleDetailsDestinationTypeEnum Enum with underlying type: string +type UpdateDrgRouteRuleDetailsDestinationTypeEnum string + +// Set of constants representing the allowable values for UpdateDrgRouteRuleDetailsDestinationTypeEnum +const ( + UpdateDrgRouteRuleDetailsDestinationTypeCidrBlock UpdateDrgRouteRuleDetailsDestinationTypeEnum = "CIDR_BLOCK" +) + +var mappingUpdateDrgRouteRuleDetailsDestinationType = map[string]UpdateDrgRouteRuleDetailsDestinationTypeEnum{ + "CIDR_BLOCK": UpdateDrgRouteRuleDetailsDestinationTypeCidrBlock, +} + +// GetUpdateDrgRouteRuleDetailsDestinationTypeEnumValues Enumerates the set of values for UpdateDrgRouteRuleDetailsDestinationTypeEnum +func GetUpdateDrgRouteRuleDetailsDestinationTypeEnumValues() []UpdateDrgRouteRuleDetailsDestinationTypeEnum { + values := make([]UpdateDrgRouteRuleDetailsDestinationTypeEnum, 0) + for _, v := range mappingUpdateDrgRouteRuleDetailsDestinationType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_rules_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_rules_details.go new file mode 100644 index 000000000..1a30650e3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_rules_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateDrgRouteRulesDetails Details used to update route rules in a DRG route table. +type UpdateDrgRouteRulesDetails struct { + + // The DRG rute rules to update. + RouteRules []UpdateDrgRouteRuleDetails `mandatory:"false" json:"routeRules"` +} + +func (m UpdateDrgRouteRulesDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_rules_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_rules_request_response.go new file mode 100644 index 000000000..18cf0f7c8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_rules_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateDrgRouteRulesRequest wrapper for the UpdateDrgRouteRules operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDrgRouteRules.go.html to see an example of how to use UpdateDrgRouteRulesRequest. +type UpdateDrgRouteRulesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG route table. + DrgRouteTableId *string `mandatory:"true" contributesTo:"path" name:"drgRouteTableId"` + + // Request to update one or more route rules in the DRG route table. + UpdateDrgRouteRulesDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateDrgRouteRulesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateDrgRouteRulesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateDrgRouteRulesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateDrgRouteRulesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateDrgRouteRulesResponse wrapper for the UpdateDrgRouteRules operation +type UpdateDrgRouteRulesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []DrgRouteRule instance + Items []DrgRouteRule `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateDrgRouteRulesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateDrgRouteRulesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_table_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_table_details.go new file mode 100644 index 000000000..19596179b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_table_details.go @@ -0,0 +1,49 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateDrgRouteTableDetails Details used in a request to update a DRG route table. +// You can't assign a table to a virtual circuit or IPSec tunnel attachment if there is a static route rule for an RPC attachment. +type UpdateDrgRouteTableDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the import route distribution used to specify how incoming route advertisements through + // referenced attachements are inserted into the DRG route table. + ImportDrgRouteDistributionId *string `mandatory:"false" json:"importDrgRouteDistributionId"` + + // If you want traffic to be routed using ECMP across your virtual circuits or IPSec tunnels to + // your on-prem networks, set this value to true on the route table. + IsEcmpEnabled *bool `mandatory:"false" json:"isEcmpEnabled"` +} + +func (m UpdateDrgRouteTableDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_table_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_table_request_response.go new file mode 100644 index 000000000..a5881c9a3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_drg_route_table_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateDrgRouteTableRequest wrapper for the UpdateDrgRouteTable operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateDrgRouteTable.go.html to see an example of how to use UpdateDrgRouteTableRequest. +type UpdateDrgRouteTableRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DRG route table. + DrgRouteTableId *string `mandatory:"true" contributesTo:"path" name:"drgRouteTableId"` + + // Details object used to updating a DRG route table. + UpdateDrgRouteTableDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateDrgRouteTableRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateDrgRouteTableRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateDrgRouteTableRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateDrgRouteTableRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateDrgRouteTableResponse wrapper for the UpdateDrgRouteTable operation +type UpdateDrgRouteTableResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DrgRouteTable instance + DrgRouteTable `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateDrgRouteTableResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateDrgRouteTableResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_i_p_sec_connection_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_i_p_sec_connection_request_response.go new file mode 100644 index 000000000..e5bd6aaa2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_i_p_sec_connection_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateIPSecConnectionRequest wrapper for the UpdateIPSecConnection operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateIPSecConnection.go.html to see an example of how to use UpdateIPSecConnectionRequest. +type UpdateIPSecConnectionRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // Details object for updating an IPSec connection. + UpdateIpSecConnectionDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateIPSecConnectionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateIPSecConnectionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateIPSecConnectionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateIPSecConnectionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateIPSecConnectionResponse wrapper for the UpdateIPSecConnection operation +type UpdateIPSecConnectionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IpSecConnection instance + IpSecConnection `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateIPSecConnectionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateIPSecConnectionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_i_p_sec_connection_tunnel_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_i_p_sec_connection_tunnel_request_response.go new file mode 100644 index 000000000..320a6c499 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_i_p_sec_connection_tunnel_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateIPSecConnectionTunnelRequest wrapper for the UpdateIPSecConnectionTunnel operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateIPSecConnectionTunnel.go.html to see an example of how to use UpdateIPSecConnectionTunnelRequest. +type UpdateIPSecConnectionTunnelRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the tunnel. + TunnelId *string `mandatory:"true" contributesTo:"path" name:"tunnelId"` + + // Details object for updating a IPSecConnection tunnel's details. + UpdateIpSecConnectionTunnelDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateIPSecConnectionTunnelRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateIPSecConnectionTunnelRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateIPSecConnectionTunnelRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateIPSecConnectionTunnelRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateIPSecConnectionTunnelResponse wrapper for the UpdateIPSecConnectionTunnel operation +type UpdateIPSecConnectionTunnelResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IpSecConnectionTunnel instance + IpSecConnectionTunnel `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateIPSecConnectionTunnelResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateIPSecConnectionTunnelResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_i_p_sec_connection_tunnel_shared_secret_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_i_p_sec_connection_tunnel_shared_secret_request_response.go new file mode 100644 index 000000000..c8e03f3eb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_i_p_sec_connection_tunnel_shared_secret_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateIPSecConnectionTunnelSharedSecretRequest wrapper for the UpdateIPSecConnectionTunnelSharedSecret operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateIPSecConnectionTunnelSharedSecret.go.html to see an example of how to use UpdateIPSecConnectionTunnelSharedSecretRequest. +type UpdateIPSecConnectionTunnelSharedSecretRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the tunnel. + TunnelId *string `mandatory:"true" contributesTo:"path" name:"tunnelId"` + + // Details object for updating a IPSec connection tunnel's sharedSecret. + UpdateIpSecConnectionTunnelSharedSecretDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateIPSecConnectionTunnelSharedSecretRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateIPSecConnectionTunnelSharedSecretRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateIPSecConnectionTunnelSharedSecretRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateIPSecConnectionTunnelSharedSecretRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateIPSecConnectionTunnelSharedSecretResponse wrapper for the UpdateIPSecConnectionTunnelSharedSecret operation +type UpdateIPSecConnectionTunnelSharedSecretResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IpSecConnectionTunnelSharedSecret instance + IpSecConnectionTunnelSharedSecret `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateIPSecConnectionTunnelSharedSecretResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateIPSecConnectionTunnelSharedSecretResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_image_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_image_details.go new file mode 100644 index 000000000..317bd3cf3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_image_details.go @@ -0,0 +1,48 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateImageDetails The representation of UpdateImageDetails +type UpdateImageDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Operating system + // Example: `Oracle Linux` + OperatingSystem *string `mandatory:"false" json:"operatingSystem"` + + // Operating system version + // Example: `7.4` + OperatingSystemVersion *string `mandatory:"false" json:"operatingSystemVersion"` +} + +func (m UpdateImageDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_image_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_image_request_response.go new file mode 100644 index 000000000..32a2b1214 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_image_request_response.go @@ -0,0 +1,92 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateImageRequest wrapper for the UpdateImage operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateImage.go.html to see an example of how to use UpdateImageRequest. +type UpdateImageRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the image. + ImageId *string `mandatory:"true" contributesTo:"path" name:"imageId"` + + // Updates the image display name field. Avoid entering confidential information. + UpdateImageDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateImageRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateImageRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateImageRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateImageRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateImageResponse wrapper for the UpdateImage operation +type UpdateImageResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Image instance + Image `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateImageResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateImageResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_agent_config_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_agent_config_details.go new file mode 100644 index 000000000..c0ce02e3f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_agent_config_details.go @@ -0,0 +1,62 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateInstanceAgentConfigDetails Configuration options for the Oracle Cloud Agent software running on the instance. +type UpdateInstanceAgentConfigDetails struct { + + // Whether Oracle Cloud Agent can gather performance metrics and monitor the instance using the + // monitoring plugins. + // These are the monitoring plugins: Compute Instance Monitoring + // and Custom Logs Monitoring. + // The monitoring plugins are controlled by this parameter and by the per-plugin + // configuration in the `pluginsConfig` object. + // - If `isMonitoringDisabled` is true, all of the monitoring plugins are disabled, regardless of + // the per-plugin configuration. + // - If `isMonitoringDisabled` is false, all of the monitoring plugins are enabled. You + // can optionally disable individual monitoring plugins by providing a value in the `pluginsConfig` + // object. + IsMonitoringDisabled *bool `mandatory:"false" json:"isMonitoringDisabled"` + + // Whether Oracle Cloud Agent can run all the available management plugins. + // These are the management plugins: OS Management Service Agent and Compute Instance + // Run Command. + // The management plugins are controlled by this parameter and by the per-plugin + // configuration in the `pluginsConfig` object. + // - If `isManagementDisabled` is true, all of the management plugins are disabled, regardless of + // the per-plugin configuration. + // - If `isManagementDisabled` is false, all of the management plugins are enabled. You + // can optionally disable individual management plugins by providing a value in the `pluginsConfig` + // object. + IsManagementDisabled *bool `mandatory:"false" json:"isManagementDisabled"` + + // Whether Oracle Cloud Agent can run all the available plugins. + // This includes the management and monitoring plugins. + // To get a list of available plugins, use the + // ListInstanceagentAvailablePlugins + // operation in the Oracle Cloud Agent API. For more information about the available plugins, see + // Managing Plugins with Oracle Cloud Agent (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/manage-plugins.htm). + AreAllPluginsDisabled *bool `mandatory:"false" json:"areAllPluginsDisabled"` + + // The configuration of plugins associated with this instance. + PluginsConfig []InstanceAgentPluginConfigDetails `mandatory:"false" json:"pluginsConfig"` +} + +func (m UpdateInstanceAgentConfigDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_availability_config_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_availability_config_details.go new file mode 100644 index 000000000..153bc834c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_availability_config_details.go @@ -0,0 +1,61 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateInstanceAvailabilityConfigDetails Options for defining the availability of a VM instance after a maintenance event that impacts the underlying +// hardware, including whether to live migrate supported VM instances when possible without sending a prior customer notification. +type UpdateInstanceAvailabilityConfigDetails struct { + + // Whether to live migrate supported VM instances to a healthy physical VM host without + // disrupting running instances during infrastructure maintenance events. If null, Oracle + // chooses the best option for migrating the VM during infrastructure maintenance events. + IsLiveMigrationPreferred *bool `mandatory:"false" json:"isLiveMigrationPreferred"` + + // The lifecycle state for an instance when it is recovered after infrastructure maintenance. + // * `RESTORE_INSTANCE` - The instance is restored to the lifecycle state it was in before the maintenance event. + // If the instance was running, it is automatically rebooted. This is the default action when a value is not set. + // * `STOP_INSTANCE` - The instance is recovered in the stopped state. + RecoveryAction UpdateInstanceAvailabilityConfigDetailsRecoveryActionEnum `mandatory:"false" json:"recoveryAction,omitempty"` +} + +func (m UpdateInstanceAvailabilityConfigDetails) String() string { + return common.PointerString(m) +} + +// UpdateInstanceAvailabilityConfigDetailsRecoveryActionEnum Enum with underlying type: string +type UpdateInstanceAvailabilityConfigDetailsRecoveryActionEnum string + +// Set of constants representing the allowable values for UpdateInstanceAvailabilityConfigDetailsRecoveryActionEnum +const ( + UpdateInstanceAvailabilityConfigDetailsRecoveryActionRestoreInstance UpdateInstanceAvailabilityConfigDetailsRecoveryActionEnum = "RESTORE_INSTANCE" + UpdateInstanceAvailabilityConfigDetailsRecoveryActionStopInstance UpdateInstanceAvailabilityConfigDetailsRecoveryActionEnum = "STOP_INSTANCE" +) + +var mappingUpdateInstanceAvailabilityConfigDetailsRecoveryAction = map[string]UpdateInstanceAvailabilityConfigDetailsRecoveryActionEnum{ + "RESTORE_INSTANCE": UpdateInstanceAvailabilityConfigDetailsRecoveryActionRestoreInstance, + "STOP_INSTANCE": UpdateInstanceAvailabilityConfigDetailsRecoveryActionStopInstance, +} + +// GetUpdateInstanceAvailabilityConfigDetailsRecoveryActionEnumValues Enumerates the set of values for UpdateInstanceAvailabilityConfigDetailsRecoveryActionEnum +func GetUpdateInstanceAvailabilityConfigDetailsRecoveryActionEnumValues() []UpdateInstanceAvailabilityConfigDetailsRecoveryActionEnum { + values := make([]UpdateInstanceAvailabilityConfigDetailsRecoveryActionEnum, 0) + for _, v := range mappingUpdateInstanceAvailabilityConfigDetailsRecoveryAction { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_configuration_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_configuration_details.go new file mode 100644 index 000000000..07e9050dc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_configuration_details.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateInstanceConfigurationDetails The representation of UpdateInstanceConfigurationDetails +type UpdateInstanceConfigurationDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m UpdateInstanceConfigurationDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_configuration_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_configuration_request_response.go new file mode 100644 index 000000000..2d3e80831 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_configuration_request_response.go @@ -0,0 +1,92 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateInstanceConfigurationRequest wrapper for the UpdateInstanceConfiguration operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateInstanceConfiguration.go.html to see an example of how to use UpdateInstanceConfigurationRequest. +type UpdateInstanceConfigurationRequest struct { + + // The OCID of the instance configuration. + InstanceConfigurationId *string `mandatory:"true" contributesTo:"path" name:"instanceConfigurationId"` + + // Updates the freeFormTags, definedTags, and display name of an instance configuration. + UpdateInstanceConfigurationDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateInstanceConfigurationRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateInstanceConfigurationRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateInstanceConfigurationRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateInstanceConfigurationRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateInstanceConfigurationResponse wrapper for the UpdateInstanceConfiguration operation +type UpdateInstanceConfigurationResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstanceConfiguration instance + InstanceConfiguration `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateInstanceConfigurationResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateInstanceConfigurationResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_console_connection_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_console_connection_details.go new file mode 100644 index 000000000..1496101e5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_console_connection_details.go @@ -0,0 +1,36 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateInstanceConsoleConnectionDetails Specifies the properties for updating tags for an instance console connection. +type UpdateInstanceConsoleConnectionDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m UpdateInstanceConsoleConnectionDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_console_connection_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_console_connection_request_response.go new file mode 100644 index 000000000..b359d22c9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_console_connection_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateInstanceConsoleConnectionRequest wrapper for the UpdateInstanceConsoleConnection operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateInstanceConsoleConnection.go.html to see an example of how to use UpdateInstanceConsoleConnectionRequest. +type UpdateInstanceConsoleConnectionRequest struct { + + // The OCID of the instance console connection. + InstanceConsoleConnectionId *string `mandatory:"true" contributesTo:"path" name:"instanceConsoleConnectionId"` + + // Update instanceConsoleConnection tags + UpdateInstanceConsoleConnectionDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateInstanceConsoleConnectionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateInstanceConsoleConnectionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateInstanceConsoleConnectionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateInstanceConsoleConnectionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateInstanceConsoleConnectionResponse wrapper for the UpdateInstanceConsoleConnection operation +type UpdateInstanceConsoleConnectionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstanceConsoleConnection instance + InstanceConsoleConnection `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateInstanceConsoleConnectionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateInstanceConsoleConnectionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_details.go new file mode 100644 index 000000000..38f7c6733 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_details.go @@ -0,0 +1,102 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateInstanceDetails The representation of UpdateInstanceDetails +type UpdateInstanceDetails struct { + + // The OCID of the compute capacity reservation this instance is launched under. + // You can remove the instance from a reservation by specifying an empty string as input for this field. + // For more information, see Capacity Reservations (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/reserve-capacity.htm#default). + CapacityReservationId *string `mandatory:"false" json:"capacityReservationId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + AgentConfig *UpdateInstanceAgentConfigDetails `mandatory:"false" json:"agentConfig"` + + // Custom metadata key/value string pairs that you provide. Any set of key/value pairs + // provided here will completely replace the current set of key/value pairs in the `metadata` + // field on the instance. + // The "user_data" field and the "ssh_authorized_keys" field cannot be changed after an instance + // has launched. Any request that updates, removes, or adds either of these fields will be + // rejected. You must provide the same values for "user_data" and "ssh_authorized_keys" that + // already exist on the instance. + // The combined size of the `metadata` and `extendedMetadata` objects can be a maximum of + // 32,000 bytes. + Metadata map[string]string `mandatory:"false" json:"metadata"` + + // Additional metadata key/value pairs that you provide. They serve the same purpose and + // functionality as fields in the `metadata` object. + // They are distinguished from `metadata` fields in that these can be nested JSON objects + // (whereas `metadata` fields are string/string maps only). + // The "user_data" field and the "ssh_authorized_keys" field cannot be changed after an instance + // has launched. Any request that updates, removes, or adds either of these fields will be + // rejected. You must provide the same values for "user_data" and "ssh_authorized_keys" that + // already exist on the instance. + // The combined size of the `metadata` and `extendedMetadata` objects can be a maximum of + // 32,000 bytes. + ExtendedMetadata map[string]interface{} `mandatory:"false" json:"extendedMetadata"` + + // The shape of the instance. The shape determines the number of CPUs and the amount of memory + // allocated to the instance. For more information about how to change shapes, and a list of + // shapes that are supported, see + // Editing an Instance (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/resizinginstances.htm). + // For details about the CPUs, memory, and other properties of each shape, see + // Compute Shapes (https://docs.cloud.oracle.com/iaas/Content/Compute/References/computeshapes.htm). + // The new shape must be compatible with the image that was used to launch the instance. You + // can enumerate all available shapes and determine image compatibility by calling + // ListShapes. + // If the instance is running when you change the shape, the instance is rebooted. + // Example: `VM.Standard2.1` + Shape *string `mandatory:"false" json:"shape"` + + ShapeConfig *UpdateInstanceShapeConfigDetails `mandatory:"false" json:"shapeConfig"` + + InstanceOptions *InstanceOptions `mandatory:"false" json:"instanceOptions"` + + // A fault domain is a grouping of hardware and infrastructure within an availability domain. + // Each availability domain contains three fault domains. Fault domains let you distribute your + // instances so that they are not on the same physical hardware within a single availability domain. + // A hardware failure or Compute hardware maintenance that affects one fault domain does not affect + // instances in other fault domains. + // To get a list of fault domains, use the + // ListFaultDomains operation in the + // Identity and Access Management Service API. + // Example: `FAULT-DOMAIN-1` + FaultDomain *string `mandatory:"false" json:"faultDomain"` + + LaunchOptions *UpdateLaunchOptions `mandatory:"false" json:"launchOptions"` + + AvailabilityConfig *UpdateInstanceAvailabilityConfigDetails `mandatory:"false" json:"availabilityConfig"` +} + +func (m UpdateInstanceDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_pool_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_pool_details.go new file mode 100644 index 000000000..24e8c213c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_pool_details.go @@ -0,0 +1,54 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateInstancePoolDetails The data to update an instance pool. +type UpdateInstancePoolDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance configuration associated with the + // instance pool. + InstanceConfigurationId *string `mandatory:"false" json:"instanceConfigurationId"` + + // The placement configurations for the instance pool. Provide one placement configuration for + // each availability domain. + // To use the instance pool with a regional subnet, provide a placement configuration for + // each availability domain, and include the regional subnet in each placement + // configuration. + PlacementConfigurations []UpdateInstancePoolPlacementConfigurationDetails `mandatory:"false" json:"placementConfigurations"` + + // The number of instances that should be in the instance pool. + Size *int `mandatory:"false" json:"size"` +} + +func (m UpdateInstancePoolDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_pool_placement_configuration_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_pool_placement_configuration_details.go new file mode 100644 index 000000000..35b9c2b4f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_pool_placement_configuration_details.go @@ -0,0 +1,48 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateInstancePoolPlacementConfigurationDetails The location for where an instance pool will place instances. +type UpdateInstancePoolPlacementConfigurationDetails struct { + + // The availability domain to place instances. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the primary subnet to place instances. + PrimarySubnetId *string `mandatory:"true" json:"primarySubnetId"` + + // The fault domains to place instances. + // If you don't provide any values, the system makes a best effort to distribute + // instances across all fault domains based on capacity. + // To distribute the instances evenly across selected fault domains, provide a + // set of fault domains. For example, you might want instances to be evenly + // distributed if your applications require high availability. + // To get a list of fault domains, use the + // ListFaultDomains operation + // in the Identity and Access Management Service API. + // Example: `[FAULT-DOMAIN-1, FAULT-DOMAIN-2, FAULT-DOMAIN-3]` + FaultDomains []string `mandatory:"false" json:"faultDomains"` + + // The set of subnet OCIDs for secondary VNICs for instances in the pool. + SecondaryVnicSubnets []InstancePoolPlacementSecondaryVnicSubnet `mandatory:"false" json:"secondaryVnicSubnets"` +} + +func (m UpdateInstancePoolPlacementConfigurationDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_pool_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_pool_request_response.go new file mode 100644 index 000000000..12cdc4994 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_pool_request_response.go @@ -0,0 +1,92 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateInstancePoolRequest wrapper for the UpdateInstancePool operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateInstancePool.go.html to see an example of how to use UpdateInstancePoolRequest. +type UpdateInstancePoolRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance pool. + InstancePoolId *string `mandatory:"true" contributesTo:"path" name:"instancePoolId"` + + // Update instance pool configuration + UpdateInstancePoolDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateInstancePoolRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateInstancePoolRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateInstancePoolRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateInstancePoolRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateInstancePoolResponse wrapper for the UpdateInstancePool operation +type UpdateInstancePoolResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InstancePool instance + InstancePool `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateInstancePoolResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateInstancePoolResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_request_response.go new file mode 100644 index 000000000..760565675 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_request_response.go @@ -0,0 +1,96 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateInstanceRequest wrapper for the UpdateInstance operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateInstance.go.html to see an example of how to use UpdateInstanceRequest. +type UpdateInstanceRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the instance. + InstanceId *string `mandatory:"true" contributesTo:"path" name:"instanceId"` + + // Update instance fields + UpdateInstanceDetails `contributesTo:"body"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateInstanceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateInstanceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateInstanceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateInstanceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateInstanceResponse wrapper for the UpdateInstance operation +type UpdateInstanceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Instance instance + Instance `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response UpdateInstanceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateInstanceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_shape_config_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_shape_config_details.go new file mode 100644 index 000000000..4c8327130 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_instance_shape_config_details.go @@ -0,0 +1,71 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateInstanceShapeConfigDetails The shape configuration requested for the instance. If provided, the instance will be updated +// with the resources specified. In the case where some properties are missing, +// the missing values will be set to the default for the provided `shape`. +// Each shape only supports certain configurable values. If the `shape` is provided +// and the configuration values are invalid for that new `shape`, an error will be returned. +// If no `shape` is provided and the configuration values are invalid for the instance's +// existing shape, an error will be returned. +type UpdateInstanceShapeConfigDetails struct { + + // The total number of OCPUs available to the instance. + Ocpus *float32 `mandatory:"false" json:"ocpus"` + + // The total amount of memory available to the instance, in gigabytes. + MemoryInGBs *float32 `mandatory:"false" json:"memoryInGBs"` + + // The baseline OCPU utilization for a subcore burstable VM instance. Leave this attribute blank for a + // non-burstable instance, or explicitly specify non-burstable with `BASELINE_1_1`. + // The following values are supported: + // - `BASELINE_1_8` - baseline usage is 1/8 of an OCPU. + // - `BASELINE_1_2` - baseline usage is 1/2 of an OCPU. + // - `BASELINE_1_1` - baseline usage is an entire OCPU. This represents a non-burstable instance. + BaselineOcpuUtilization UpdateInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum `mandatory:"false" json:"baselineOcpuUtilization,omitempty"` +} + +func (m UpdateInstanceShapeConfigDetails) String() string { + return common.PointerString(m) +} + +// UpdateInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum Enum with underlying type: string +type UpdateInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum string + +// Set of constants representing the allowable values for UpdateInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum +const ( + UpdateInstanceShapeConfigDetailsBaselineOcpuUtilization8 UpdateInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum = "BASELINE_1_8" + UpdateInstanceShapeConfigDetailsBaselineOcpuUtilization2 UpdateInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum = "BASELINE_1_2" + UpdateInstanceShapeConfigDetailsBaselineOcpuUtilization1 UpdateInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum = "BASELINE_1_1" +) + +var mappingUpdateInstanceShapeConfigDetailsBaselineOcpuUtilization = map[string]UpdateInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum{ + "BASELINE_1_8": UpdateInstanceShapeConfigDetailsBaselineOcpuUtilization8, + "BASELINE_1_2": UpdateInstanceShapeConfigDetailsBaselineOcpuUtilization2, + "BASELINE_1_1": UpdateInstanceShapeConfigDetailsBaselineOcpuUtilization1, +} + +// GetUpdateInstanceShapeConfigDetailsBaselineOcpuUtilizationEnumValues Enumerates the set of values for UpdateInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum +func GetUpdateInstanceShapeConfigDetailsBaselineOcpuUtilizationEnumValues() []UpdateInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum { + values := make([]UpdateInstanceShapeConfigDetailsBaselineOcpuUtilizationEnum, 0) + for _, v := range mappingUpdateInstanceShapeConfigDetailsBaselineOcpuUtilization { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_internet_gateway_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_internet_gateway_details.go new file mode 100644 index 000000000..1b7efb44f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_internet_gateway_details.go @@ -0,0 +1,43 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateInternetGatewayDetails The representation of UpdateInternetGatewayDetails +type UpdateInternetGatewayDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Whether the gateway is enabled. + IsEnabled *bool `mandatory:"false" json:"isEnabled"` +} + +func (m UpdateInternetGatewayDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_internet_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_internet_gateway_request_response.go new file mode 100644 index 000000000..1a1e59399 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_internet_gateway_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateInternetGatewayRequest wrapper for the UpdateInternetGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateInternetGateway.go.html to see an example of how to use UpdateInternetGatewayRequest. +type UpdateInternetGatewayRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the internet gateway. + IgId *string `mandatory:"true" contributesTo:"path" name:"igId"` + + // Details for updating the internet gateway. + UpdateInternetGatewayDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateInternetGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateInternetGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateInternetGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateInternetGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateInternetGatewayResponse wrapper for the UpdateInternetGateway operation +type UpdateInternetGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The InternetGateway instance + InternetGateway `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateInternetGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateInternetGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_connection_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_connection_details.go new file mode 100644 index 000000000..195f2021b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_connection_details.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateIpSecConnectionDetails The representation of UpdateIpSecConnectionDetails +type UpdateIpSecConnectionDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Your identifier for your CPE device. Can be either an IP address or a hostname (specifically, the + // fully qualified domain name (FQDN)). The type of identifier you provide here must correspond + // to the value for `cpeLocalIdentifierType`. + // For information about why you'd provide this value, see + // If Your CPE Is Behind a NAT Device (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/overviewIPsec.htm#nat). + // Example IP address: `10.0.3.3` + // Example hostname: `cpe.example.com` + CpeLocalIdentifier *string `mandatory:"false" json:"cpeLocalIdentifier"` + + // The type of identifier for your CPE device. The value you provide here must correspond to the value + // for `cpeLocalIdentifier`. + CpeLocalIdentifierType UpdateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum `mandatory:"false" json:"cpeLocalIdentifierType,omitempty"` + + // Static routes to the CPE. If you provide this attribute, it replaces the entire current set of + // static routes. A static route's CIDR must not be a multicast address or class E address. + // The CIDR can be either IPv4 or IPv6. + // IPv6 addressing is supported for all commercial and government regions. + // See IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // Example: `10.0.1.0/24` + // Example: `2001:db8::/32` + StaticRoutes []string `mandatory:"false" json:"staticRoutes"` +} + +func (m UpdateIpSecConnectionDetails) String() string { + return common.PointerString(m) +} + +// UpdateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum Enum with underlying type: string +type UpdateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum string + +// Set of constants representing the allowable values for UpdateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum +const ( + UpdateIpSecConnectionDetailsCpeLocalIdentifierTypeIpAddress UpdateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum = "IP_ADDRESS" + UpdateIpSecConnectionDetailsCpeLocalIdentifierTypeHostname UpdateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum = "HOSTNAME" +) + +var mappingUpdateIpSecConnectionDetailsCpeLocalIdentifierType = map[string]UpdateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum{ + "IP_ADDRESS": UpdateIpSecConnectionDetailsCpeLocalIdentifierTypeIpAddress, + "HOSTNAME": UpdateIpSecConnectionDetailsCpeLocalIdentifierTypeHostname, +} + +// GetUpdateIpSecConnectionDetailsCpeLocalIdentifierTypeEnumValues Enumerates the set of values for UpdateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum +func GetUpdateIpSecConnectionDetailsCpeLocalIdentifierTypeEnumValues() []UpdateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum { + values := make([]UpdateIpSecConnectionDetailsCpeLocalIdentifierTypeEnum, 0) + for _, v := range mappingUpdateIpSecConnectionDetailsCpeLocalIdentifierType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_connection_tunnel_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_connection_tunnel_details.go new file mode 100644 index 000000000..000ea9d17 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_connection_tunnel_details.go @@ -0,0 +1,148 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateIpSecConnectionTunnelDetails The representation of UpdateIpSecConnectionTunnelDetails +type UpdateIpSecConnectionTunnelDetails struct { + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The type of routing to use for this tunnel (either BGP dynamic routing or static routing). + Routing UpdateIpSecConnectionTunnelDetailsRoutingEnum `mandatory:"false" json:"routing,omitempty"` + + // Internet Key Exchange protocol version. + IkeVersion UpdateIpSecConnectionTunnelDetailsIkeVersionEnum `mandatory:"false" json:"ikeVersion,omitempty"` + + BgpSessionConfig *UpdateIpSecTunnelBgpSessionDetails `mandatory:"false" json:"bgpSessionConfig"` + + // Whether Oracle side is the initiator for negotiation. + OracleInitiation UpdateIpSecConnectionTunnelDetailsOracleInitiationEnum `mandatory:"false" json:"oracleInitiation,omitempty"` + + // Whether NAT-T Enabled on the tunnel + NatTranslationEnabled UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum `mandatory:"false" json:"natTranslationEnabled,omitempty"` + + PhaseOneConfig *PhaseOneConfigDetails `mandatory:"false" json:"phaseOneConfig"` + + PhaseTwoConfig *PhaseTwoConfigDetails `mandatory:"false" json:"phaseTwoConfig"` + + DpdConfig *DpdConfig `mandatory:"false" json:"dpdConfig"` + + EncryptionDomainConfig *UpdateIpSecTunnelEncryptionDomainDetails `mandatory:"false" json:"encryptionDomainConfig"` +} + +func (m UpdateIpSecConnectionTunnelDetails) String() string { + return common.PointerString(m) +} + +// UpdateIpSecConnectionTunnelDetailsRoutingEnum Enum with underlying type: string +type UpdateIpSecConnectionTunnelDetailsRoutingEnum string + +// Set of constants representing the allowable values for UpdateIpSecConnectionTunnelDetailsRoutingEnum +const ( + UpdateIpSecConnectionTunnelDetailsRoutingBgp UpdateIpSecConnectionTunnelDetailsRoutingEnum = "BGP" + UpdateIpSecConnectionTunnelDetailsRoutingStatic UpdateIpSecConnectionTunnelDetailsRoutingEnum = "STATIC" + UpdateIpSecConnectionTunnelDetailsRoutingPolicy UpdateIpSecConnectionTunnelDetailsRoutingEnum = "POLICY" +) + +var mappingUpdateIpSecConnectionTunnelDetailsRouting = map[string]UpdateIpSecConnectionTunnelDetailsRoutingEnum{ + "BGP": UpdateIpSecConnectionTunnelDetailsRoutingBgp, + "STATIC": UpdateIpSecConnectionTunnelDetailsRoutingStatic, + "POLICY": UpdateIpSecConnectionTunnelDetailsRoutingPolicy, +} + +// GetUpdateIpSecConnectionTunnelDetailsRoutingEnumValues Enumerates the set of values for UpdateIpSecConnectionTunnelDetailsRoutingEnum +func GetUpdateIpSecConnectionTunnelDetailsRoutingEnumValues() []UpdateIpSecConnectionTunnelDetailsRoutingEnum { + values := make([]UpdateIpSecConnectionTunnelDetailsRoutingEnum, 0) + for _, v := range mappingUpdateIpSecConnectionTunnelDetailsRouting { + values = append(values, v) + } + return values +} + +// UpdateIpSecConnectionTunnelDetailsIkeVersionEnum Enum with underlying type: string +type UpdateIpSecConnectionTunnelDetailsIkeVersionEnum string + +// Set of constants representing the allowable values for UpdateIpSecConnectionTunnelDetailsIkeVersionEnum +const ( + UpdateIpSecConnectionTunnelDetailsIkeVersionV1 UpdateIpSecConnectionTunnelDetailsIkeVersionEnum = "V1" + UpdateIpSecConnectionTunnelDetailsIkeVersionV2 UpdateIpSecConnectionTunnelDetailsIkeVersionEnum = "V2" +) + +var mappingUpdateIpSecConnectionTunnelDetailsIkeVersion = map[string]UpdateIpSecConnectionTunnelDetailsIkeVersionEnum{ + "V1": UpdateIpSecConnectionTunnelDetailsIkeVersionV1, + "V2": UpdateIpSecConnectionTunnelDetailsIkeVersionV2, +} + +// GetUpdateIpSecConnectionTunnelDetailsIkeVersionEnumValues Enumerates the set of values for UpdateIpSecConnectionTunnelDetailsIkeVersionEnum +func GetUpdateIpSecConnectionTunnelDetailsIkeVersionEnumValues() []UpdateIpSecConnectionTunnelDetailsIkeVersionEnum { + values := make([]UpdateIpSecConnectionTunnelDetailsIkeVersionEnum, 0) + for _, v := range mappingUpdateIpSecConnectionTunnelDetailsIkeVersion { + values = append(values, v) + } + return values +} + +// UpdateIpSecConnectionTunnelDetailsOracleInitiationEnum Enum with underlying type: string +type UpdateIpSecConnectionTunnelDetailsOracleInitiationEnum string + +// Set of constants representing the allowable values for UpdateIpSecConnectionTunnelDetailsOracleInitiationEnum +const ( + UpdateIpSecConnectionTunnelDetailsOracleInitiationInitiatorOrResponder UpdateIpSecConnectionTunnelDetailsOracleInitiationEnum = "INITIATOR_OR_RESPONDER" + UpdateIpSecConnectionTunnelDetailsOracleInitiationResponderOnly UpdateIpSecConnectionTunnelDetailsOracleInitiationEnum = "RESPONDER_ONLY" +) + +var mappingUpdateIpSecConnectionTunnelDetailsOracleInitiation = map[string]UpdateIpSecConnectionTunnelDetailsOracleInitiationEnum{ + "INITIATOR_OR_RESPONDER": UpdateIpSecConnectionTunnelDetailsOracleInitiationInitiatorOrResponder, + "RESPONDER_ONLY": UpdateIpSecConnectionTunnelDetailsOracleInitiationResponderOnly, +} + +// GetUpdateIpSecConnectionTunnelDetailsOracleInitiationEnumValues Enumerates the set of values for UpdateIpSecConnectionTunnelDetailsOracleInitiationEnum +func GetUpdateIpSecConnectionTunnelDetailsOracleInitiationEnumValues() []UpdateIpSecConnectionTunnelDetailsOracleInitiationEnum { + values := make([]UpdateIpSecConnectionTunnelDetailsOracleInitiationEnum, 0) + for _, v := range mappingUpdateIpSecConnectionTunnelDetailsOracleInitiation { + values = append(values, v) + } + return values +} + +// UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum Enum with underlying type: string +type UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum string + +// Set of constants representing the allowable values for UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum +const ( + UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledEnabled UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum = "ENABLED" + UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledDisabled UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum = "DISABLED" + UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledAuto UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum = "AUTO" +) + +var mappingUpdateIpSecConnectionTunnelDetailsNatTranslationEnabled = map[string]UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum{ + "ENABLED": UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledEnabled, + "DISABLED": UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledDisabled, + "AUTO": UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledAuto, +} + +// GetUpdateIpSecConnectionTunnelDetailsNatTranslationEnabledEnumValues Enumerates the set of values for UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum +func GetUpdateIpSecConnectionTunnelDetailsNatTranslationEnabledEnumValues() []UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum { + values := make([]UpdateIpSecConnectionTunnelDetailsNatTranslationEnabledEnum, 0) + for _, v := range mappingUpdateIpSecConnectionTunnelDetailsNatTranslationEnabled { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_connection_tunnel_shared_secret_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_connection_tunnel_shared_secret_details.go new file mode 100644 index 000000000..eca58a628 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_connection_tunnel_shared_secret_details.go @@ -0,0 +1,30 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateIpSecConnectionTunnelSharedSecretDetails The representation of UpdateIpSecConnectionTunnelSharedSecretDetails +type UpdateIpSecConnectionTunnelSharedSecretDetails struct { + + // The shared secret (pre-shared key) to use for the tunnel. Only numbers, letters, and spaces + // are allowed. + SharedSecret *string `mandatory:"false" json:"sharedSecret"` +} + +func (m UpdateIpSecConnectionTunnelSharedSecretDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_tunnel_bgp_session_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_tunnel_bgp_session_details.go new file mode 100644 index 000000000..212727af8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_tunnel_bgp_session_details.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateIpSecTunnelBgpSessionDetails The representation of UpdateIpSecTunnelBgpSessionDetails +type UpdateIpSecTunnelBgpSessionDetails struct { + + // The IP address for the Oracle end of the inside tunnel interface. + // If the tunnel's `routing` attribute is set to `BGP` + // (see UpdateIPSecConnectionTunnelDetails), this IP address + // is used for the tunnel's BGP session. + // If `routing` is instead set to `STATIC`, you can set this IP address to troubleshoot or + // monitor the tunnel. + // The value must be a /30 or /31. + // If you are switching the tunnel from using BGP dynamic routing to static routing and want + // to remove the value for `oracleInterfaceIp`, you can set the value to an empty string. + // Example: `10.0.0.4/31` + OracleInterfaceIp *string `mandatory:"false" json:"oracleInterfaceIp"` + + // The IP address for the CPE end of the inside tunnel interface. + // If the tunnel's `routing` attribute is set to `BGP` + // (see UpdateIPSecConnectionTunnelDetails), this IP address + // is used for the tunnel's BGP session. + // If `routing` is instead set to `STATIC`, you can set this IP address to troubleshoot or + // monitor the tunnel. + // The value must be a /30 or /31. + // If you are switching the tunnel from using BGP dynamic routing to static routing and want + // to remove the value for `customerInterfaceIp`, you can set the value to an empty string. + // Example: `10.0.0.5/31` + CustomerInterfaceIp *string `mandatory:"false" json:"customerInterfaceIp"` + + // The IPv6 address for the Oracle end of the inside tunnel interface. This IP address is optional. + // If the tunnel's `routing` attribute is set to `BGP` + // (see IPSecConnectionTunnel), this IP address + // is used for the tunnel's BGP session. + // If `routing` is instead set to `STATIC`, you can set this IP + // address to troubleshoot or monitor the tunnel. + // Only subnet masks from /64 up to /127 are allowed. + // Example: `2001:db8::1/64` + OracleInterfaceIpv6 *string `mandatory:"false" json:"oracleInterfaceIpv6"` + + // The IPv6 address for the CPE end of the inside tunnel interface. This IP address is optional. + // If the tunnel's `routing` attribute is set to `BGP` + // (see IPSecConnectionTunnel), this IP address + // is used for the tunnel's BGP session. + // If `routing` is instead set to `STATIC`, you can set this IP + // address to troubleshoot or monitor the tunnel. + // Only subnet masks from /64 up to /127 are allowed. + // Example: `2001:db8::1/64` + CustomerInterfaceIpv6 *string `mandatory:"false" json:"customerInterfaceIpv6"` + + // The BGP ASN of the network on the CPE end of the BGP session. Can be a 2-byte or 4-byte ASN. + // Uses "asplain" format. + // If you are switching the tunnel from using BGP dynamic routing to static routing, the + // `customerBgpAsn` must be null. + // Example: `12345` (2-byte) or `1587232876` (4-byte) + CustomerBgpAsn *string `mandatory:"false" json:"customerBgpAsn"` +} + +func (m UpdateIpSecTunnelBgpSessionDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_tunnel_encryption_domain_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_tunnel_encryption_domain_details.go new file mode 100644 index 000000000..03898c3d0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ip_sec_tunnel_encryption_domain_details.go @@ -0,0 +1,34 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateIpSecTunnelEncryptionDomainDetails Request to update a multi-encryption domain policy on the IPSec tunnel. +// There can't be more than 50 security associations in use at one time. See Encryption domain for policy-based +// tunnels (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/ipsecencryptiondomains.htm#spi_policy_based_tunnel) for more. +type UpdateIpSecTunnelEncryptionDomainDetails struct { + + // Lists IPv4 or IPv6-enabled subnets in your Oracle tenancy. + OracleTrafficSelector []string `mandatory:"false" json:"oracleTrafficSelector"` + + // Lists IPv4 or IPv6-enabled subnets in your on-premises network. + CpeTrafficSelector []string `mandatory:"false" json:"cpeTrafficSelector"` +} + +func (m UpdateIpSecTunnelEncryptionDomainDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ipv6_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ipv6_details.go new file mode 100644 index 000000000..070b09a39 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ipv6_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateIpv6Details The representation of UpdateIpv6Details +type UpdateIpv6Details struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VNIC to reassign the IPv6 to. + // The VNIC must be in the same subnet as the current VNIC. + VnicId *string `mandatory:"false" json:"vnicId"` +} + +func (m UpdateIpv6Details) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ipv6_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ipv6_request_response.go new file mode 100644 index 000000000..525440a2e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_ipv6_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateIpv6Request wrapper for the UpdateIpv6 operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateIpv6.go.html to see an example of how to use UpdateIpv6Request. +type UpdateIpv6Request struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the IPv6. + Ipv6Id *string `mandatory:"true" contributesTo:"path" name:"ipv6Id"` + + // IPv6 details to be updated. + UpdateIpv6Details `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateIpv6Request) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateIpv6Request) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateIpv6Request) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateIpv6Request) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateIpv6Response wrapper for the UpdateIpv6 operation +type UpdateIpv6Response struct { + + // The underlying http response + RawResponse *http.Response + + // The Ipv6 instance + Ipv6 `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateIpv6Response) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateIpv6Response) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_launch_options.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_launch_options.go new file mode 100644 index 000000000..8903e02ce --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_launch_options.go @@ -0,0 +1,108 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateLaunchOptions Options for tuning the compatibility and performance of VM shapes. +type UpdateLaunchOptions struct { + + // Emulation type for the boot volume. + // * `ISCSI` - ISCSI attached block storage device. + // * `PARAVIRTUALIZED` - Paravirtualized disk. This is the default for boot volumes and remote block + // storage volumes on platform images. + // Before you change the boot volume attachment type, detach all block volumes and VNICs except for + // the boot volume and the primary VNIC. + // If the instance is running when you change the boot volume attachment type, it will be rebooted. + // **Note:** Some instances might not function properly if you change the boot volume attachment type. After + // the instance reboots and is running, connect to it. If the connection fails or the OS doesn't behave + // as expected, the changes are not supported. Revert the instance to the original boot volume attachment type. + BootVolumeType UpdateLaunchOptionsBootVolumeTypeEnum `mandatory:"false" json:"bootVolumeType,omitempty"` + + // Emulation type for the physical network interface card (NIC). + // * `VFIO` - Direct attached Virtual Function network controller. This is the networking type + // when you launch an instance using hardware-assisted (SR-IOV) networking. + // * `PARAVIRTUALIZED` - VM instances launch with paravirtualized devices using VirtIO drivers. + // Before you change the networking type, detach all VNICs and block volumes except for the primary + // VNIC and the boot volume. + // The image must have paravirtualized drivers installed. For more information, see + // Editing an Instance (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/resizinginstances.htm). + // If the instance is running when you change the network type, it will be rebooted. + // **Note:** Some instances might not function properly if you change the networking type. After + // the instance reboots and is running, connect to it. If the connection fails or the OS doesn't behave + // as expected, the changes are not supported. Revert the instance to the original networking type. + NetworkType UpdateLaunchOptionsNetworkTypeEnum `mandatory:"false" json:"networkType,omitempty"` + + // Whether to enable in-transit encryption for the volume's paravirtualized attachment. + // To enable in-transit encryption for block volumes and boot volumes, this field must be set to `true`. + // Data in transit is transferred over an internal and highly secure network. If you have specific + // compliance requirements related to the encryption of the data while it is moving between the + // instance and the boot volume or the block volume, you can enable in-transit encryption. + // In-transit encryption is not enabled by default. + // All boot volumes and block volumes are encrypted at rest. + // For more information, see Block Volume Encryption (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm#Encrypti). + IsPvEncryptionInTransitEnabled *bool `mandatory:"false" json:"isPvEncryptionInTransitEnabled"` +} + +func (m UpdateLaunchOptions) String() string { + return common.PointerString(m) +} + +// UpdateLaunchOptionsBootVolumeTypeEnum Enum with underlying type: string +type UpdateLaunchOptionsBootVolumeTypeEnum string + +// Set of constants representing the allowable values for UpdateLaunchOptionsBootVolumeTypeEnum +const ( + UpdateLaunchOptionsBootVolumeTypeIscsi UpdateLaunchOptionsBootVolumeTypeEnum = "ISCSI" + UpdateLaunchOptionsBootVolumeTypeParavirtualized UpdateLaunchOptionsBootVolumeTypeEnum = "PARAVIRTUALIZED" +) + +var mappingUpdateLaunchOptionsBootVolumeType = map[string]UpdateLaunchOptionsBootVolumeTypeEnum{ + "ISCSI": UpdateLaunchOptionsBootVolumeTypeIscsi, + "PARAVIRTUALIZED": UpdateLaunchOptionsBootVolumeTypeParavirtualized, +} + +// GetUpdateLaunchOptionsBootVolumeTypeEnumValues Enumerates the set of values for UpdateLaunchOptionsBootVolumeTypeEnum +func GetUpdateLaunchOptionsBootVolumeTypeEnumValues() []UpdateLaunchOptionsBootVolumeTypeEnum { + values := make([]UpdateLaunchOptionsBootVolumeTypeEnum, 0) + for _, v := range mappingUpdateLaunchOptionsBootVolumeType { + values = append(values, v) + } + return values +} + +// UpdateLaunchOptionsNetworkTypeEnum Enum with underlying type: string +type UpdateLaunchOptionsNetworkTypeEnum string + +// Set of constants representing the allowable values for UpdateLaunchOptionsNetworkTypeEnum +const ( + UpdateLaunchOptionsNetworkTypeVfio UpdateLaunchOptionsNetworkTypeEnum = "VFIO" + UpdateLaunchOptionsNetworkTypeParavirtualized UpdateLaunchOptionsNetworkTypeEnum = "PARAVIRTUALIZED" +) + +var mappingUpdateLaunchOptionsNetworkType = map[string]UpdateLaunchOptionsNetworkTypeEnum{ + "VFIO": UpdateLaunchOptionsNetworkTypeVfio, + "PARAVIRTUALIZED": UpdateLaunchOptionsNetworkTypeParavirtualized, +} + +// GetUpdateLaunchOptionsNetworkTypeEnumValues Enumerates the set of values for UpdateLaunchOptionsNetworkTypeEnum +func GetUpdateLaunchOptionsNetworkTypeEnumValues() []UpdateLaunchOptionsNetworkTypeEnum { + values := make([]UpdateLaunchOptionsNetworkTypeEnum, 0) + for _, v := range mappingUpdateLaunchOptionsNetworkType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_local_peering_gateway_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_local_peering_gateway_details.go new file mode 100644 index 000000000..e9c9b13f4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_local_peering_gateway_details.go @@ -0,0 +1,45 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateLocalPeeringGatewayDetails The representation of UpdateLocalPeeringGatewayDetails +type UpdateLocalPeeringGatewayDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route table the LPG will use. + // For information about why you would associate a route table with an LPG, see + // Transit Routing: Access to Multiple VCNs in Same Region (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitrouting.htm). + RouteTableId *string `mandatory:"false" json:"routeTableId"` +} + +func (m UpdateLocalPeeringGatewayDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_local_peering_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_local_peering_gateway_request_response.go new file mode 100644 index 000000000..a41eba093 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_local_peering_gateway_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateLocalPeeringGatewayRequest wrapper for the UpdateLocalPeeringGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateLocalPeeringGateway.go.html to see an example of how to use UpdateLocalPeeringGatewayRequest. +type UpdateLocalPeeringGatewayRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the local peering gateway. + LocalPeeringGatewayId *string `mandatory:"true" contributesTo:"path" name:"localPeeringGatewayId"` + + // Details object for updating a local peering gateway. + UpdateLocalPeeringGatewayDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateLocalPeeringGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateLocalPeeringGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateLocalPeeringGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateLocalPeeringGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateLocalPeeringGatewayResponse wrapper for the UpdateLocalPeeringGateway operation +type UpdateLocalPeeringGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The LocalPeeringGateway instance + LocalPeeringGateway `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateLocalPeeringGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateLocalPeeringGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_macsec_key.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_macsec_key.go new file mode 100644 index 000000000..072611562 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_macsec_key.go @@ -0,0 +1,38 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateMacsecKey An object defining the OCID of the Secret held in Vault that represent the MACsec key. +type UpdateMacsecKey struct { + + // Secret OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) containing the Connectivity Association Key Name (CKN) of this MACsec key. + ConnectivityAssociationNameSecretId *string `mandatory:"true" json:"connectivityAssociationNameSecretId"` + + // The secret version of the connectivity association name secret in Vault. + ConnectivityAssociationNameSecretVersion *int64 `mandatory:"true" json:"connectivityAssociationNameSecretVersion"` + + // Secret OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) containing the Connectivity Association Key (CAK) of this MACsec key. + ConnectivityAssociationKeySecretId *string `mandatory:"true" json:"connectivityAssociationKeySecretId"` + + // The secret version of the connectivityAssociationKey secret in Vault. + ConnectivityAssociationKeySecretVersion *int64 `mandatory:"true" json:"connectivityAssociationKeySecretVersion"` +} + +func (m UpdateMacsecKey) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_macsec_properties.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_macsec_properties.go new file mode 100644 index 000000000..a0238c000 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_macsec_properties.go @@ -0,0 +1,34 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateMacsecProperties Properties used to update MACsec settings. +type UpdateMacsecProperties struct { + + // Indicates whether or not MACsec is enabled. + State MacsecStateEnum `mandatory:"true" json:"state"` + + PrimaryKey *UpdateMacsecKey `mandatory:"false" json:"primaryKey"` + + // Type of encryption cipher suite to use for the MACsec connection. + EncryptionCipher MacsecEncryptionCipherEnum `mandatory:"false" json:"encryptionCipher,omitempty"` +} + +func (m UpdateMacsecProperties) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_nat_gateway_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_nat_gateway_details.go new file mode 100644 index 000000000..403194edc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_nat_gateway_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateNatGatewayDetails The representation of UpdateNatGatewayDetails +type UpdateNatGatewayDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Whether the NAT gateway blocks traffic through it. The default is `false`. + // Example: `true` + BlockTraffic *bool `mandatory:"false" json:"blockTraffic"` +} + +func (m UpdateNatGatewayDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_nat_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_nat_gateway_request_response.go new file mode 100644 index 000000000..8f02a0a69 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_nat_gateway_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateNatGatewayRequest wrapper for the UpdateNatGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateNatGateway.go.html to see an example of how to use UpdateNatGatewayRequest. +type UpdateNatGatewayRequest struct { + + // The NAT gateway's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + NatGatewayId *string `mandatory:"true" contributesTo:"path" name:"natGatewayId"` + + // Details object for updating a NAT gateway. + UpdateNatGatewayDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateNatGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateNatGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateNatGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateNatGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateNatGatewayResponse wrapper for the UpdateNatGateway operation +type UpdateNatGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The NatGateway instance + NatGateway `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateNatGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateNatGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_details.go new file mode 100644 index 000000000..f4c15d44a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_details.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateNetworkSecurityGroupDetails The representation of UpdateNetworkSecurityGroupDetails +type UpdateNetworkSecurityGroupDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m UpdateNetworkSecurityGroupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_request_response.go new file mode 100644 index 000000000..2deaf445b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateNetworkSecurityGroupRequest wrapper for the UpdateNetworkSecurityGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateNetworkSecurityGroup.go.html to see an example of how to use UpdateNetworkSecurityGroupRequest. +type UpdateNetworkSecurityGroupRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network security group. + NetworkSecurityGroupId *string `mandatory:"true" contributesTo:"path" name:"networkSecurityGroupId"` + + // Details object for updating a network security group. + UpdateNetworkSecurityGroupDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateNetworkSecurityGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateNetworkSecurityGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateNetworkSecurityGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateNetworkSecurityGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateNetworkSecurityGroupResponse wrapper for the UpdateNetworkSecurityGroup operation +type UpdateNetworkSecurityGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The NetworkSecurityGroup instance + NetworkSecurityGroup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateNetworkSecurityGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateNetworkSecurityGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_security_rules_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_security_rules_details.go new file mode 100644 index 000000000..ab8b9630e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_security_rules_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateNetworkSecurityGroupSecurityRulesDetails The representation of UpdateNetworkSecurityGroupSecurityRulesDetails +type UpdateNetworkSecurityGroupSecurityRulesDetails struct { + + // The NSG security rules to update. + SecurityRules []UpdateSecurityRuleDetails `mandatory:"false" json:"securityRules"` +} + +func (m UpdateNetworkSecurityGroupSecurityRulesDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_security_rules_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_security_rules_request_response.go new file mode 100644 index 000000000..32c2121db --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_network_security_group_security_rules_request_response.go @@ -0,0 +1,78 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateNetworkSecurityGroupSecurityRulesRequest wrapper for the UpdateNetworkSecurityGroupSecurityRules operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateNetworkSecurityGroupSecurityRules.go.html to see an example of how to use UpdateNetworkSecurityGroupSecurityRulesRequest. +type UpdateNetworkSecurityGroupSecurityRulesRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network security group. + NetworkSecurityGroupId *string `mandatory:"true" contributesTo:"path" name:"networkSecurityGroupId"` + + // Request with one or more security rules associated with the network security group that + // will be updated. + UpdateNetworkSecurityGroupSecurityRulesDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateNetworkSecurityGroupSecurityRulesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateNetworkSecurityGroupSecurityRulesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateNetworkSecurityGroupSecurityRulesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateNetworkSecurityGroupSecurityRulesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateNetworkSecurityGroupSecurityRulesResponse wrapper for the UpdateNetworkSecurityGroupSecurityRules operation +type UpdateNetworkSecurityGroupSecurityRulesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The UpdatedNetworkSecurityGroupSecurityRules instance + UpdatedNetworkSecurityGroupSecurityRules `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateNetworkSecurityGroupSecurityRulesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateNetworkSecurityGroupSecurityRulesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_private_ip_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_private_ip_details.go new file mode 100644 index 000000000..eccc5b4e8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_private_ip_details.go @@ -0,0 +1,55 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdatePrivateIpDetails The representation of UpdatePrivateIpDetails +type UpdatePrivateIpDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The hostname for the private IP. Used for DNS. The value + // is the hostname portion of the private IP's fully qualified domain name (FQDN) + // (for example, `bminstance-1` in FQDN `bminstance-1.subnet123.vcn1.oraclevcn.com`). + // Must be unique across all VNICs in the subnet and comply with + // RFC 952 (https://tools.ietf.org/html/rfc952) and + // RFC 1123 (https://tools.ietf.org/html/rfc1123). + // For more information, see + // DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). + // Example: `bminstance-1` + HostnameLabel *string `mandatory:"false" json:"hostnameLabel"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VNIC to reassign the private IP to. The VNIC must + // be in the same subnet as the current VNIC. + VnicId *string `mandatory:"false" json:"vnicId"` +} + +func (m UpdatePrivateIpDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_private_ip_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_private_ip_request_response.go new file mode 100644 index 000000000..024544b94 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_private_ip_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdatePrivateIpRequest wrapper for the UpdatePrivateIp operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdatePrivateIp.go.html to see an example of how to use UpdatePrivateIpRequest. +type UpdatePrivateIpRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the private IP. + PrivateIpId *string `mandatory:"true" contributesTo:"path" name:"privateIpId"` + + // Private IP details. + UpdatePrivateIpDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdatePrivateIpRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdatePrivateIpRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdatePrivateIpRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdatePrivateIpRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdatePrivateIpResponse wrapper for the UpdatePrivateIp operation +type UpdatePrivateIpResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The PrivateIp instance + PrivateIp `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdatePrivateIpResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdatePrivateIpResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_details.go new file mode 100644 index 000000000..6ad25ec82 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_details.go @@ -0,0 +1,47 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdatePublicIpDetails The representation of UpdatePublicIpDetails +type UpdatePublicIpDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the private IP to assign the public IP to. + // * If the public IP is already assigned to a different private IP, it will be unassigned + // and then reassigned to the specified private IP. + // * If you set this field to an empty string, the public IP will be unassigned from the + // private IP it is currently assigned to. + PrivateIpId *string `mandatory:"false" json:"privateIpId"` +} + +func (m UpdatePublicIpDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_pool_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_pool_details.go new file mode 100644 index 000000000..242a8cc16 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_pool_details.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdatePublicIpPoolDetails The data to update for a public IP pool. +type UpdatePublicIpPoolDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m UpdatePublicIpPoolDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_pool_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_pool_request_response.go new file mode 100644 index 000000000..b290b2870 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_pool_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdatePublicIpPoolRequest wrapper for the UpdatePublicIpPool operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdatePublicIpPool.go.html to see an example of how to use UpdatePublicIpPoolRequest. +type UpdatePublicIpPoolRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the public IP pool. + PublicIpPoolId *string `mandatory:"true" contributesTo:"path" name:"publicIpPoolId"` + + // Public IP pool details. + UpdatePublicIpPoolDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdatePublicIpPoolRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdatePublicIpPoolRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdatePublicIpPoolRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdatePublicIpPoolRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdatePublicIpPoolResponse wrapper for the UpdatePublicIpPool operation +type UpdatePublicIpPoolResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The PublicIpPool instance + PublicIpPool `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdatePublicIpPoolResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdatePublicIpPoolResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_request_response.go new file mode 100644 index 000000000..7a9dceb6d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_public_ip_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdatePublicIpRequest wrapper for the UpdatePublicIp operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdatePublicIp.go.html to see an example of how to use UpdatePublicIpRequest. +type UpdatePublicIpRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the public IP. + PublicIpId *string `mandatory:"true" contributesTo:"path" name:"publicIpId"` + + // Public IP details. + UpdatePublicIpDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdatePublicIpRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdatePublicIpRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdatePublicIpRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdatePublicIpRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdatePublicIpResponse wrapper for the UpdatePublicIp operation +type UpdatePublicIpResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The PublicIp instance + PublicIp `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdatePublicIpResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdatePublicIpResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_remote_peering_connection_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_remote_peering_connection_details.go new file mode 100644 index 000000000..9f46de51c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_remote_peering_connection_details.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateRemotePeeringConnectionDetails The representation of UpdateRemotePeeringConnectionDetails +type UpdateRemotePeeringConnectionDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m UpdateRemotePeeringConnectionDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_remote_peering_connection_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_remote_peering_connection_request_response.go new file mode 100644 index 000000000..256ed8706 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_remote_peering_connection_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateRemotePeeringConnectionRequest wrapper for the UpdateRemotePeeringConnection operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateRemotePeeringConnection.go.html to see an example of how to use UpdateRemotePeeringConnectionRequest. +type UpdateRemotePeeringConnectionRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the remote peering connection (RPC). + RemotePeeringConnectionId *string `mandatory:"true" contributesTo:"path" name:"remotePeeringConnectionId"` + + // Request to the update the peering connection to remote region + UpdateRemotePeeringConnectionDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateRemotePeeringConnectionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateRemotePeeringConnectionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateRemotePeeringConnectionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateRemotePeeringConnectionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateRemotePeeringConnectionResponse wrapper for the UpdateRemotePeeringConnection operation +type UpdateRemotePeeringConnectionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The RemotePeeringConnection instance + RemotePeeringConnection `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateRemotePeeringConnectionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateRemotePeeringConnectionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_route_table_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_route_table_details.go new file mode 100644 index 000000000..6a1c464b3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_route_table_details.go @@ -0,0 +1,43 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateRouteTableDetails The representation of UpdateRouteTableDetails +type UpdateRouteTableDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The collection of rules used for routing destination IPs to network devices. + RouteRules []RouteRule `mandatory:"false" json:"routeRules"` +} + +func (m UpdateRouteTableDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_route_table_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_route_table_request_response.go new file mode 100644 index 000000000..9630fd789 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_route_table_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateRouteTableRequest wrapper for the UpdateRouteTable operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateRouteTable.go.html to see an example of how to use UpdateRouteTableRequest. +type UpdateRouteTableRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the route table. + RtId *string `mandatory:"true" contributesTo:"path" name:"rtId"` + + // Details object for updating a route table. + UpdateRouteTableDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateRouteTableRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateRouteTableRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateRouteTableRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateRouteTableRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateRouteTableResponse wrapper for the UpdateRouteTable operation +type UpdateRouteTableResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The RouteTable instance + RouteTable `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateRouteTableResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateRouteTableResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_security_list_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_security_list_details.go new file mode 100644 index 000000000..20cc81183 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_security_list_details.go @@ -0,0 +1,46 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateSecurityListDetails The representation of UpdateSecurityListDetails +type UpdateSecurityListDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Rules for allowing egress IP packets. + EgressSecurityRules []EgressSecurityRule `mandatory:"false" json:"egressSecurityRules"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Rules for allowing ingress IP packets. + IngressSecurityRules []IngressSecurityRule `mandatory:"false" json:"ingressSecurityRules"` +} + +func (m UpdateSecurityListDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_security_list_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_security_list_request_response.go new file mode 100644 index 000000000..d79991189 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_security_list_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateSecurityListRequest wrapper for the UpdateSecurityList operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateSecurityList.go.html to see an example of how to use UpdateSecurityListRequest. +type UpdateSecurityListRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the security list. + SecurityListId *string `mandatory:"true" contributesTo:"path" name:"securityListId"` + + // Updated details for the security list. + UpdateSecurityListDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateSecurityListRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateSecurityListRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateSecurityListRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateSecurityListRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateSecurityListResponse wrapper for the UpdateSecurityList operation +type UpdateSecurityListResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The SecurityList instance + SecurityList `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateSecurityListResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateSecurityListResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_security_rule_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_security_rule_details.go new file mode 100644 index 000000000..c53a0f3da --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_security_rule_details.go @@ -0,0 +1,176 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateSecurityRuleDetails A rule for allowing inbound (`direction`= INGRESS) or outbound (`direction`= EGRESS) IP packets. +type UpdateSecurityRuleDetails struct { + + // Direction of the security rule. Set to `EGRESS` for rules to allow outbound IP packets, + // or `INGRESS` for rules to allow inbound IP packets. + Direction UpdateSecurityRuleDetailsDirectionEnum `mandatory:"true" json:"direction"` + + // The Oracle-assigned ID of the security rule that you want to update. You can't change this value. + // Example: `04ABEC` + Id *string `mandatory:"true" json:"id"` + + // The transport protocol. Specify either `all` or an IPv4 protocol number as + // defined in + // Protocol Numbers (http://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml). + // Options are supported only for ICMP ("1"), TCP ("6"), UDP ("17"), and ICMPv6 ("58"). + Protocol *string `mandatory:"true" json:"protocol"` + + // An optional description of your choice for the rule. Avoid entering confidential information. + Description *string `mandatory:"false" json:"description"` + + // Conceptually, this is the range of IP addresses that a packet originating from the instance + // can go to. + // Allowed values: + // * An IP address range in CIDR notation. For example: `192.168.1.0/24` or `2001:0db8:0123:45::/56` + // IPv6 addressing is supported for all commercial and government regions. See + // IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // * The `cidrBlock` value for a Service, if you're + // setting up a security rule for traffic destined for a particular `Service` through + // a service gateway. For example: `oci-phx-objectstorage`. + // * The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of a NetworkSecurityGroup in the same + // VCN. The value can be the NSG that the rule belongs to if the rule's intent is to control + // traffic between VNICs in the same NSG. + Destination *string `mandatory:"false" json:"destination"` + + // Type of destination for the rule. Required if `direction` = `EGRESS`. + // Allowed values: + // * `CIDR_BLOCK`: If the rule's `destination` is an IP address range in CIDR notation. + // * `SERVICE_CIDR_BLOCK`: If the rule's `destination` is the `cidrBlock` value for a + // Service (the rule is for traffic destined for a + // particular `Service` through a service gateway). + // * `NETWORK_SECURITY_GROUP`: If the rule's `destination` is the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of a + // NetworkSecurityGroup. + DestinationType UpdateSecurityRuleDetailsDestinationTypeEnum `mandatory:"false" json:"destinationType,omitempty"` + + IcmpOptions *IcmpOptions `mandatory:"false" json:"icmpOptions"` + + // A stateless rule allows traffic in one direction. Remember to add a corresponding + // stateless rule in the other direction if you need to support bidirectional traffic. For + // example, if egress traffic allows TCP destination port 80, there should be an ingress + // rule to allow TCP source port 80. Defaults to false, which means the rule is stateful + // and a corresponding rule is not necessary for bidirectional traffic. + IsStateless *bool `mandatory:"false" json:"isStateless"` + + // Conceptually, this is the range of IP addresses that a packet coming into the instance + // can come from. + // Allowed values: + // * An IP address range in CIDR notation. For example: `192.168.1.0/24` or `2001:0db8:0123:45::/56` + // IPv6 addressing is supported for all commercial and government regions. See + // IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // * The `cidrBlock` value for a Service, if you're + // setting up a security rule for traffic coming from a particular `Service` through + // a service gateway. For example: `oci-phx-objectstorage`. + // * The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of a NetworkSecurityGroup in the same + // VCN. The value can be the NSG that the rule belongs to if the rule's intent is to control + // traffic between VNICs in the same NSG. + Source *string `mandatory:"false" json:"source"` + + // Type of source for the rule. Required if `direction` = `INGRESS`. + // * `CIDR_BLOCK`: If the rule's `source` is an IP address range in CIDR notation. + // * `SERVICE_CIDR_BLOCK`: If the rule's `source` is the `cidrBlock` value for a + // Service (the rule is for traffic coming from a + // particular `Service` through a service gateway). + // * `NETWORK_SECURITY_GROUP`: If the rule's `source` is the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of a + // NetworkSecurityGroup. + SourceType UpdateSecurityRuleDetailsSourceTypeEnum `mandatory:"false" json:"sourceType,omitempty"` + + TcpOptions *TcpOptions `mandatory:"false" json:"tcpOptions"` + + UdpOptions *UdpOptions `mandatory:"false" json:"udpOptions"` +} + +func (m UpdateSecurityRuleDetails) String() string { + return common.PointerString(m) +} + +// UpdateSecurityRuleDetailsDestinationTypeEnum Enum with underlying type: string +type UpdateSecurityRuleDetailsDestinationTypeEnum string + +// Set of constants representing the allowable values for UpdateSecurityRuleDetailsDestinationTypeEnum +const ( + UpdateSecurityRuleDetailsDestinationTypeCidrBlock UpdateSecurityRuleDetailsDestinationTypeEnum = "CIDR_BLOCK" + UpdateSecurityRuleDetailsDestinationTypeServiceCidrBlock UpdateSecurityRuleDetailsDestinationTypeEnum = "SERVICE_CIDR_BLOCK" + UpdateSecurityRuleDetailsDestinationTypeNetworkSecurityGroup UpdateSecurityRuleDetailsDestinationTypeEnum = "NETWORK_SECURITY_GROUP" +) + +var mappingUpdateSecurityRuleDetailsDestinationType = map[string]UpdateSecurityRuleDetailsDestinationTypeEnum{ + "CIDR_BLOCK": UpdateSecurityRuleDetailsDestinationTypeCidrBlock, + "SERVICE_CIDR_BLOCK": UpdateSecurityRuleDetailsDestinationTypeServiceCidrBlock, + "NETWORK_SECURITY_GROUP": UpdateSecurityRuleDetailsDestinationTypeNetworkSecurityGroup, +} + +// GetUpdateSecurityRuleDetailsDestinationTypeEnumValues Enumerates the set of values for UpdateSecurityRuleDetailsDestinationTypeEnum +func GetUpdateSecurityRuleDetailsDestinationTypeEnumValues() []UpdateSecurityRuleDetailsDestinationTypeEnum { + values := make([]UpdateSecurityRuleDetailsDestinationTypeEnum, 0) + for _, v := range mappingUpdateSecurityRuleDetailsDestinationType { + values = append(values, v) + } + return values +} + +// UpdateSecurityRuleDetailsDirectionEnum Enum with underlying type: string +type UpdateSecurityRuleDetailsDirectionEnum string + +// Set of constants representing the allowable values for UpdateSecurityRuleDetailsDirectionEnum +const ( + UpdateSecurityRuleDetailsDirectionEgress UpdateSecurityRuleDetailsDirectionEnum = "EGRESS" + UpdateSecurityRuleDetailsDirectionIngress UpdateSecurityRuleDetailsDirectionEnum = "INGRESS" +) + +var mappingUpdateSecurityRuleDetailsDirection = map[string]UpdateSecurityRuleDetailsDirectionEnum{ + "EGRESS": UpdateSecurityRuleDetailsDirectionEgress, + "INGRESS": UpdateSecurityRuleDetailsDirectionIngress, +} + +// GetUpdateSecurityRuleDetailsDirectionEnumValues Enumerates the set of values for UpdateSecurityRuleDetailsDirectionEnum +func GetUpdateSecurityRuleDetailsDirectionEnumValues() []UpdateSecurityRuleDetailsDirectionEnum { + values := make([]UpdateSecurityRuleDetailsDirectionEnum, 0) + for _, v := range mappingUpdateSecurityRuleDetailsDirection { + values = append(values, v) + } + return values +} + +// UpdateSecurityRuleDetailsSourceTypeEnum Enum with underlying type: string +type UpdateSecurityRuleDetailsSourceTypeEnum string + +// Set of constants representing the allowable values for UpdateSecurityRuleDetailsSourceTypeEnum +const ( + UpdateSecurityRuleDetailsSourceTypeCidrBlock UpdateSecurityRuleDetailsSourceTypeEnum = "CIDR_BLOCK" + UpdateSecurityRuleDetailsSourceTypeServiceCidrBlock UpdateSecurityRuleDetailsSourceTypeEnum = "SERVICE_CIDR_BLOCK" + UpdateSecurityRuleDetailsSourceTypeNetworkSecurityGroup UpdateSecurityRuleDetailsSourceTypeEnum = "NETWORK_SECURITY_GROUP" +) + +var mappingUpdateSecurityRuleDetailsSourceType = map[string]UpdateSecurityRuleDetailsSourceTypeEnum{ + "CIDR_BLOCK": UpdateSecurityRuleDetailsSourceTypeCidrBlock, + "SERVICE_CIDR_BLOCK": UpdateSecurityRuleDetailsSourceTypeServiceCidrBlock, + "NETWORK_SECURITY_GROUP": UpdateSecurityRuleDetailsSourceTypeNetworkSecurityGroup, +} + +// GetUpdateSecurityRuleDetailsSourceTypeEnumValues Enumerates the set of values for UpdateSecurityRuleDetailsSourceTypeEnum +func GetUpdateSecurityRuleDetailsSourceTypeEnumValues() []UpdateSecurityRuleDetailsSourceTypeEnum { + values := make([]UpdateSecurityRuleDetailsSourceTypeEnum, 0) + for _, v := range mappingUpdateSecurityRuleDetailsSourceType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_service_gateway_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_service_gateway_details.go new file mode 100644 index 000000000..bbb80baa4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_service_gateway_details.go @@ -0,0 +1,61 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateServiceGatewayDetails The representation of UpdateServiceGatewayDetails +type UpdateServiceGatewayDetails struct { + + // Whether the service gateway blocks all traffic through it. The default is `false`. When + // this is `true`, traffic is not routed to any services, regardless of route rules. + // Example: `true` + BlockTraffic *bool `mandatory:"false" json:"blockTraffic"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route table the service gateway will use. + // For information about why you would associate a route table with a service gateway, see + // Transit Routing: Private Access to Oracle Services (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitroutingoracleservices.htm). + RouteTableId *string `mandatory:"false" json:"routeTableId"` + + // List of all the `Service` objects you want enabled on this service gateway. Sending an empty list + // means you want to disable all services. Omitting this parameter entirely keeps the + // existing list of services intact. + // You can also enable or disable a particular `Service` by using + // AttachServiceId or + // DetachServiceId. + // For each enabled `Service`, make sure there's a route rule with the `Service` object's `cidrBlock` + // as the rule's destination and the service gateway as the rule's target. See + // RouteTable. + Services []ServiceIdRequestDetails `mandatory:"false" json:"services"` +} + +func (m UpdateServiceGatewayDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_service_gateway_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_service_gateway_request_response.go new file mode 100644 index 000000000..030c9b0c1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_service_gateway_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateServiceGatewayRequest wrapper for the UpdateServiceGateway operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateServiceGateway.go.html to see an example of how to use UpdateServiceGatewayRequest. +type UpdateServiceGatewayRequest struct { + + // The service gateway's OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm). + ServiceGatewayId *string `mandatory:"true" contributesTo:"path" name:"serviceGatewayId"` + + // Details object for updating a service gateway. + UpdateServiceGatewayDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateServiceGatewayRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateServiceGatewayRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateServiceGatewayRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateServiceGatewayRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateServiceGatewayResponse wrapper for the UpdateServiceGateway operation +type UpdateServiceGatewayResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ServiceGateway instance + ServiceGateway `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateServiceGatewayResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateServiceGatewayResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_subnet_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_subnet_details.go new file mode 100644 index 000000000..3e25b4304 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_subnet_details.go @@ -0,0 +1,71 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateSubnetDetails The representation of UpdateSubnetDetails +type UpdateSubnetDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the set of DHCP options the subnet will use. + DhcpOptionsId *string `mandatory:"false" json:"dhcpOptionsId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route table the subnet will use. + RouteTableId *string `mandatory:"false" json:"routeTableId"` + + // The OCIDs of the security list or lists the subnet will use. This + // replaces the entire current set of security lists. Remember that + // security lists are associated *with the subnet*, but the rules are + // applied to the individual VNICs in the subnet. + SecurityListIds []string `mandatory:"false" json:"securityListIds"` + + // The CIDR block of the subnet. The new CIDR block must meet the following criteria: + // - Must be valid. + // - The CIDR block's IP range must be completely within one of the VCN's CIDR block ranges. + // - The old and new CIDR block ranges must use the same network address. Example: `10.0.0.0/25` and `10.0.0.0/24`. + // - Must contain all IP addresses in use in the old CIDR range. + // - The new CIDR range's broadcast address (last IP address of CIDR range) must not be an IP address in use in the old CIDR range. + // **Note:** If you are changing the CIDR block, you cannot create VNICs or private IPs for this resource while the update is in progress. + // Example: `172.16.0.0/16` + CidrBlock *string `mandatory:"false" json:"cidrBlock"` + + // This is the IPv6 CIDR block for the subnet's IP address space. + // The subnet size is always /64. + // See IPv6 Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/ipv6.htm). + // The provided CIDR must maintain the following rules - + // a. The IPv6 CIDR block is valid and correctly formatted. + // b. The IPv6 CIDR is within the parent VCN IPv6 range. + // Example: `2001:0db8:0123:1111::/64` + Ipv6CidrBlock *string `mandatory:"false" json:"ipv6CidrBlock"` +} + +func (m UpdateSubnetDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_subnet_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_subnet_request_response.go new file mode 100644 index 000000000..0ad161d44 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_subnet_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateSubnetRequest wrapper for the UpdateSubnet operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateSubnet.go.html to see an example of how to use UpdateSubnetRequest. +type UpdateSubnetRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the subnet. + SubnetId *string `mandatory:"true" contributesTo:"path" name:"subnetId"` + + // Details object for updating a subnet. + UpdateSubnetDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateSubnetRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateSubnetRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateSubnetRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateSubnetRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateSubnetResponse wrapper for the UpdateSubnet operation +type UpdateSubnetResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Subnet instance + Subnet `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateSubnetResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateSubnetResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_tunnel_cpe_device_config_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_tunnel_cpe_device_config_details.go new file mode 100644 index 000000000..ccf467ec8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_tunnel_cpe_device_config_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateTunnelCpeDeviceConfigDetails The representation of UpdateTunnelCpeDeviceConfigDetails +type UpdateTunnelCpeDeviceConfigDetails struct { + + // The set of configuration answers for a CPE device. + TunnelCpeDeviceConfig []CpeDeviceConfigAnswer `mandatory:"false" json:"tunnelCpeDeviceConfig"` +} + +func (m UpdateTunnelCpeDeviceConfigDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_tunnel_cpe_device_config_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_tunnel_cpe_device_config_request_response.go new file mode 100644 index 000000000..991998c44 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_tunnel_cpe_device_config_request_response.go @@ -0,0 +1,95 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateTunnelCpeDeviceConfigRequest wrapper for the UpdateTunnelCpeDeviceConfig operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateTunnelCpeDeviceConfig.go.html to see an example of how to use UpdateTunnelCpeDeviceConfigRequest. +type UpdateTunnelCpeDeviceConfigRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the IPSec connection. + IpscId *string `mandatory:"true" contributesTo:"path" name:"ipscId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the tunnel. + TunnelId *string `mandatory:"true" contributesTo:"path" name:"tunnelId"` + + // Request to input the tunnel's cpe configuration parameters + UpdateTunnelCpeDeviceConfigDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateTunnelCpeDeviceConfigRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateTunnelCpeDeviceConfigRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateTunnelCpeDeviceConfigRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateTunnelCpeDeviceConfigRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateTunnelCpeDeviceConfigResponse wrapper for the UpdateTunnelCpeDeviceConfig operation +type UpdateTunnelCpeDeviceConfigResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The TunnelCpeDeviceConfig instance + TunnelCpeDeviceConfig `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateTunnelCpeDeviceConfigResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateTunnelCpeDeviceConfigResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vcn_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vcn_details.go new file mode 100644 index 000000000..749164804 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vcn_details.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateVcnDetails The representation of UpdateVcnDetails +type UpdateVcnDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m UpdateVcnDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vcn_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vcn_request_response.go new file mode 100644 index 000000000..d6e48649c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vcn_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateVcnRequest wrapper for the UpdateVcn operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVcn.go.html to see an example of how to use UpdateVcnRequest. +type UpdateVcnRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN. + VcnId *string `mandatory:"true" contributesTo:"path" name:"vcnId"` + + // Details object for updating a VCN. + UpdateVcnDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateVcnRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateVcnRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateVcnRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateVcnRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateVcnResponse wrapper for the UpdateVcn operation +type UpdateVcnResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Vcn instance + Vcn `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateVcnResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateVcnResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_virtual_circuit_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_virtual_circuit_details.go new file mode 100644 index 000000000..2a5ddbecd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_virtual_circuit_details.go @@ -0,0 +1,148 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateVirtualCircuitDetails The representation of UpdateVirtualCircuitDetails +type UpdateVirtualCircuitDetails struct { + + // The provisioned data rate of the connection. To get a list of the + // available bandwidth levels (that is, shapes), see + // ListFastConnectProviderVirtualCircuitBandwidthShapes. + // To be updated only by the customer who owns the virtual circuit. + BandwidthShapeName *string `mandatory:"false" json:"bandwidthShapeName"` + + // An array of mappings, each containing properties for a cross-connect or + // cross-connect group associated with this virtual circuit. + // The customer and provider can update different properties in the mapping + // depending on the situation. See the description of the + // CrossConnectMapping. + CrossConnectMappings []CrossConnectMapping `mandatory:"false" json:"crossConnectMappings"` + + // The routing policy sets how routing information about the Oracle cloud is shared over a public virtual circuit. + // Policies available are: `ORACLE_SERVICE_NETWORK`, `REGIONAL`, `MARKET_LEVEL`, and `GLOBAL`. + // See Route Filtering (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/routingonprem.htm#route_filtering) for details. + // By default, routing information is shared for all routes in the same market. + RoutingPolicy []UpdateVirtualCircuitDetailsRoutingPolicyEnum `mandatory:"false" json:"routingPolicy,omitempty"` + + // Deprecated. Instead use `customerAsn`. + // If you specify values for both, the request will be rejected. + CustomerBgpAsn *int `mandatory:"false" json:"customerBgpAsn"` + + // The BGP ASN of the network at the other end of the BGP + // session from Oracle. + // If the BGP session is from the customer's edge router to Oracle, the + // required value is the customer's ASN, and it can be updated only + // by the customer. + // If the BGP session is from the provider's edge router to Oracle, the + // required value is the provider's ASN, and it can be updated only + // by the provider. + // Can be a 2-byte or 4-byte ASN. Uses "asplain" format. + CustomerAsn *int64 `mandatory:"false" json:"customerAsn"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the Drg + // that this private virtual circuit uses. + // To be updated only by the customer who owns the virtual circuit. + GatewayId *string `mandatory:"false" json:"gatewayId"` + + // The provider's state in relation to this virtual circuit. Relevant only + // if the customer is using FastConnect via a provider. ACTIVE + // means the provider has provisioned the virtual circuit from their + // end. INACTIVE means the provider has not yet provisioned the virtual + // circuit, or has de-provisioned it. + // To be updated only by the provider. + ProviderState UpdateVirtualCircuitDetailsProviderStateEnum `mandatory:"false" json:"providerState,omitempty"` + + // The service key name offered by the provider (if the customer is connecting via a provider). + ProviderServiceKeyName *string `mandatory:"false" json:"providerServiceKeyName"` + + // Provider-supplied reference information about this virtual circuit. + // Relevant only if the customer is using FastConnect via a provider. + // To be updated only by the provider. + ReferenceComment *string `mandatory:"false" json:"referenceComment"` + + // The layer 3 IP MTU to use on this virtual circuit. + IpMtu VirtualCircuitIpMtuEnum `mandatory:"false" json:"ipMtu,omitempty"` +} + +func (m UpdateVirtualCircuitDetails) String() string { + return common.PointerString(m) +} + +// UpdateVirtualCircuitDetailsRoutingPolicyEnum Enum with underlying type: string +type UpdateVirtualCircuitDetailsRoutingPolicyEnum string + +// Set of constants representing the allowable values for UpdateVirtualCircuitDetailsRoutingPolicyEnum +const ( + UpdateVirtualCircuitDetailsRoutingPolicyOracleServiceNetwork UpdateVirtualCircuitDetailsRoutingPolicyEnum = "ORACLE_SERVICE_NETWORK" + UpdateVirtualCircuitDetailsRoutingPolicyRegional UpdateVirtualCircuitDetailsRoutingPolicyEnum = "REGIONAL" + UpdateVirtualCircuitDetailsRoutingPolicyMarketLevel UpdateVirtualCircuitDetailsRoutingPolicyEnum = "MARKET_LEVEL" + UpdateVirtualCircuitDetailsRoutingPolicyGlobal UpdateVirtualCircuitDetailsRoutingPolicyEnum = "GLOBAL" +) + +var mappingUpdateVirtualCircuitDetailsRoutingPolicy = map[string]UpdateVirtualCircuitDetailsRoutingPolicyEnum{ + "ORACLE_SERVICE_NETWORK": UpdateVirtualCircuitDetailsRoutingPolicyOracleServiceNetwork, + "REGIONAL": UpdateVirtualCircuitDetailsRoutingPolicyRegional, + "MARKET_LEVEL": UpdateVirtualCircuitDetailsRoutingPolicyMarketLevel, + "GLOBAL": UpdateVirtualCircuitDetailsRoutingPolicyGlobal, +} + +// GetUpdateVirtualCircuitDetailsRoutingPolicyEnumValues Enumerates the set of values for UpdateVirtualCircuitDetailsRoutingPolicyEnum +func GetUpdateVirtualCircuitDetailsRoutingPolicyEnumValues() []UpdateVirtualCircuitDetailsRoutingPolicyEnum { + values := make([]UpdateVirtualCircuitDetailsRoutingPolicyEnum, 0) + for _, v := range mappingUpdateVirtualCircuitDetailsRoutingPolicy { + values = append(values, v) + } + return values +} + +// UpdateVirtualCircuitDetailsProviderStateEnum Enum with underlying type: string +type UpdateVirtualCircuitDetailsProviderStateEnum string + +// Set of constants representing the allowable values for UpdateVirtualCircuitDetailsProviderStateEnum +const ( + UpdateVirtualCircuitDetailsProviderStateActive UpdateVirtualCircuitDetailsProviderStateEnum = "ACTIVE" + UpdateVirtualCircuitDetailsProviderStateInactive UpdateVirtualCircuitDetailsProviderStateEnum = "INACTIVE" +) + +var mappingUpdateVirtualCircuitDetailsProviderState = map[string]UpdateVirtualCircuitDetailsProviderStateEnum{ + "ACTIVE": UpdateVirtualCircuitDetailsProviderStateActive, + "INACTIVE": UpdateVirtualCircuitDetailsProviderStateInactive, +} + +// GetUpdateVirtualCircuitDetailsProviderStateEnumValues Enumerates the set of values for UpdateVirtualCircuitDetailsProviderStateEnum +func GetUpdateVirtualCircuitDetailsProviderStateEnumValues() []UpdateVirtualCircuitDetailsProviderStateEnum { + values := make([]UpdateVirtualCircuitDetailsProviderStateEnum, 0) + for _, v := range mappingUpdateVirtualCircuitDetailsProviderState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_virtual_circuit_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_virtual_circuit_request_response.go new file mode 100644 index 000000000..9a8b596ca --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_virtual_circuit_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateVirtualCircuitRequest wrapper for the UpdateVirtualCircuit operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVirtualCircuit.go.html to see an example of how to use UpdateVirtualCircuitRequest. +type UpdateVirtualCircuitRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the virtual circuit. + VirtualCircuitId *string `mandatory:"true" contributesTo:"path" name:"virtualCircuitId"` + + // Update VirtualCircuit fields. + UpdateVirtualCircuitDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateVirtualCircuitRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateVirtualCircuitRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateVirtualCircuitRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateVirtualCircuitRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateVirtualCircuitResponse wrapper for the UpdateVirtualCircuit operation +type UpdateVirtualCircuitResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VirtualCircuit instance + VirtualCircuit `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateVirtualCircuitResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateVirtualCircuitResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vlan_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vlan_details.go new file mode 100644 index 000000000..94aa3af50 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vlan_details.go @@ -0,0 +1,58 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateVlanDetails The representation of UpdateVlanDetails +type UpdateVlanDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // A list of the OCIDs of the network security groups (NSGs) to use with + // this VLAN. All VNICs in the VLAN will belong to these NSGs. For more + // information about NSGs, see + // NetworkSecurityGroup. + NsgIds []string `mandatory:"false" json:"nsgIds"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route table the VLAN will use. + RouteTableId *string `mandatory:"false" json:"routeTableId"` + + // The CIDR block of the VLAN. The new CIDR block must meet the following criteria: + // - Must be valid. + // - The CIDR block's IP range must be completely within one of the VCN's CIDR block ranges. + // - The old and new CIDR block ranges must use the same network address. Example: `10.0.0.0/25` and `10.0.0.0/24`. + // - Must contain all IP addresses in use in the old CIDR range. + // - The new CIDR range's broadcast address (last IP address of CIDR range) must not be an IP address in use in the old CIDR range. + // **Note:** If you are changing the CIDR block, you cannot create VNICs or private IPs for this resource while the update is in progress. + CidrBlock *string `mandatory:"false" json:"cidrBlock"` +} + +func (m UpdateVlanDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vlan_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vlan_request_response.go new file mode 100644 index 000000000..98c717818 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vlan_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateVlanRequest wrapper for the UpdateVlan operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVlan.go.html to see an example of how to use UpdateVlanRequest. +type UpdateVlanRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VLAN. + VlanId *string `mandatory:"true" contributesTo:"path" name:"vlanId"` + + // Details object for updating a subnet. + UpdateVlanDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateVlanRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateVlanRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateVlanRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateVlanRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateVlanResponse wrapper for the UpdateVlan operation +type UpdateVlanResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Vlan instance + Vlan `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateVlanResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateVlanResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vnic_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vnic_details.go new file mode 100644 index 000000000..1bd4a1c94 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vnic_details.go @@ -0,0 +1,73 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateVnicDetails The representation of UpdateVnicDetails +type UpdateVnicDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The hostname for the VNIC's primary private IP. Used for DNS. The value is the hostname + // portion of the primary private IP's fully qualified domain name (FQDN) + // (for example, `bminstance-1` in FQDN `bminstance-1.subnet123.vcn1.oraclevcn.com`). + // Must be unique across all VNICs in the subnet and comply with + // RFC 952 (https://tools.ietf.org/html/rfc952) and + // RFC 1123 (https://tools.ietf.org/html/rfc1123). + // The value appears in the Vnic object and also the + // PrivateIp object returned by + // ListPrivateIps and + // GetPrivateIp. + // For more information, see + // DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). + HostnameLabel *string `mandatory:"false" json:"hostnameLabel"` + + // A list of the OCIDs of the network security groups (NSGs) to add the VNIC to. Setting this as + // an empty array removes the VNIC from all network security groups. + // If the VNIC belongs to a VLAN as part of the Oracle Cloud VMware Solution (instead of + // belonging to a subnet), the value of the `nsgIds` attribute is ignored. Instead, the + // VNIC belongs to the NSGs that are associated with the VLAN itself. See Vlan. + // For more information about NSGs, see + // NetworkSecurityGroup. + NsgIds []string `mandatory:"false" json:"nsgIds"` + + // Whether the source/destination check is disabled on the VNIC. + // Defaults to `false`, which means the check is performed. For information about why you would + // skip the source/destination check, see + // Using a Private IP as a Route Target (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingroutetables.htm#privateip). + // If the VNIC belongs to a VLAN as part of the Oracle Cloud VMware Solution (instead of + // belonging to a subnet), the value of the `skipSourceDestCheck` attribute is ignored. + // This is because the source/destination check is always disabled for VNICs in a VLAN. + // Example: `true` + SkipSourceDestCheck *bool `mandatory:"false" json:"skipSourceDestCheck"` +} + +func (m UpdateVnicDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vnic_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vnic_request_response.go new file mode 100644 index 000000000..c391ccbe8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_vnic_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateVnicRequest wrapper for the UpdateVnic operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVnic.go.html to see an example of how to use UpdateVnicRequest. +type UpdateVnicRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the VNIC. + VnicId *string `mandatory:"true" contributesTo:"path" name:"vnicId"` + + // Details object for updating a VNIC. + UpdateVnicDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateVnicRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateVnicRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateVnicRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateVnicRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateVnicResponse wrapper for the UpdateVnic operation +type UpdateVnicResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Vnic instance + Vnic `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateVnicResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateVnicResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_attachment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_attachment_details.go new file mode 100644 index 000000000..c6161bff7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_attachment_details.go @@ -0,0 +1,63 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateVolumeAttachmentDetails details for updating a volume attachment. +type UpdateVolumeAttachmentDetails struct { + + // The iscsi login state of the volume attachment. For a multipath volume attachment, + // all iscsi sessions need to be all logged-in or logged-out to be in logged-in or logged-out state. + IscsiLoginState UpdateVolumeAttachmentDetailsIscsiLoginStateEnum `mandatory:"false" json:"iscsiLoginState,omitempty"` +} + +func (m UpdateVolumeAttachmentDetails) String() string { + return common.PointerString(m) +} + +// UpdateVolumeAttachmentDetailsIscsiLoginStateEnum Enum with underlying type: string +type UpdateVolumeAttachmentDetailsIscsiLoginStateEnum string + +// Set of constants representing the allowable values for UpdateVolumeAttachmentDetailsIscsiLoginStateEnum +const ( + UpdateVolumeAttachmentDetailsIscsiLoginStateUnknown UpdateVolumeAttachmentDetailsIscsiLoginStateEnum = "UNKNOWN" + UpdateVolumeAttachmentDetailsIscsiLoginStateLoggingIn UpdateVolumeAttachmentDetailsIscsiLoginStateEnum = "LOGGING_IN" + UpdateVolumeAttachmentDetailsIscsiLoginStateLoginSucceeded UpdateVolumeAttachmentDetailsIscsiLoginStateEnum = "LOGIN_SUCCEEDED" + UpdateVolumeAttachmentDetailsIscsiLoginStateLoginFailed UpdateVolumeAttachmentDetailsIscsiLoginStateEnum = "LOGIN_FAILED" + UpdateVolumeAttachmentDetailsIscsiLoginStateLoggingOut UpdateVolumeAttachmentDetailsIscsiLoginStateEnum = "LOGGING_OUT" + UpdateVolumeAttachmentDetailsIscsiLoginStateLogoutSucceeded UpdateVolumeAttachmentDetailsIscsiLoginStateEnum = "LOGOUT_SUCCEEDED" + UpdateVolumeAttachmentDetailsIscsiLoginStateLogoutFailed UpdateVolumeAttachmentDetailsIscsiLoginStateEnum = "LOGOUT_FAILED" +) + +var mappingUpdateVolumeAttachmentDetailsIscsiLoginState = map[string]UpdateVolumeAttachmentDetailsIscsiLoginStateEnum{ + "UNKNOWN": UpdateVolumeAttachmentDetailsIscsiLoginStateUnknown, + "LOGGING_IN": UpdateVolumeAttachmentDetailsIscsiLoginStateLoggingIn, + "LOGIN_SUCCEEDED": UpdateVolumeAttachmentDetailsIscsiLoginStateLoginSucceeded, + "LOGIN_FAILED": UpdateVolumeAttachmentDetailsIscsiLoginStateLoginFailed, + "LOGGING_OUT": UpdateVolumeAttachmentDetailsIscsiLoginStateLoggingOut, + "LOGOUT_SUCCEEDED": UpdateVolumeAttachmentDetailsIscsiLoginStateLogoutSucceeded, + "LOGOUT_FAILED": UpdateVolumeAttachmentDetailsIscsiLoginStateLogoutFailed, +} + +// GetUpdateVolumeAttachmentDetailsIscsiLoginStateEnumValues Enumerates the set of values for UpdateVolumeAttachmentDetailsIscsiLoginStateEnum +func GetUpdateVolumeAttachmentDetailsIscsiLoginStateEnumValues() []UpdateVolumeAttachmentDetailsIscsiLoginStateEnum { + values := make([]UpdateVolumeAttachmentDetailsIscsiLoginStateEnum, 0) + for _, v := range mappingUpdateVolumeAttachmentDetailsIscsiLoginState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_attachment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_attachment_request_response.go new file mode 100644 index 000000000..c2584e36a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_attachment_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateVolumeAttachmentRequest wrapper for the UpdateVolumeAttachment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVolumeAttachment.go.html to see an example of how to use UpdateVolumeAttachmentRequest. +type UpdateVolumeAttachmentRequest struct { + + // The OCID of the volume attachment. + VolumeAttachmentId *string `mandatory:"true" contributesTo:"path" name:"volumeAttachmentId"` + + // Update information about the specified volume attachment. + UpdateVolumeAttachmentDetails `contributesTo:"body"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateVolumeAttachmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateVolumeAttachmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateVolumeAttachmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateVolumeAttachmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateVolumeAttachmentResponse wrapper for the UpdateVolumeAttachment operation +type UpdateVolumeAttachmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeAttachment instance + VolumeAttachment `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateVolumeAttachmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateVolumeAttachmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_details.go new file mode 100644 index 000000000..48a5e76b6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_details.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateVolumeBackupDetails The representation of UpdateVolumeBackupDetails +type UpdateVolumeBackupDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m UpdateVolumeBackupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_policy_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_policy_details.go new file mode 100644 index 000000000..53d4ab9cb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_policy_details.go @@ -0,0 +1,53 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateVolumeBackupPolicyDetails Specifies the properties for updating a user defined backup policy. +// For more information about user defined backup policies, +// see User Defined Policies (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm#UserDefinedBackupPolicies) in +// Policy-Based Backups (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm). +type UpdateVolumeBackupPolicyDetails struct { + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // The paired destination region for copying scheduled backups to. Example: `us-ashburn-1`. + // Specify `none` to reset the `destinationRegion` parameter. + // See Region Pairs (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm#RegionPairs) for details about paired regions. + DestinationRegion *string `mandatory:"false" json:"destinationRegion"` + + // The collection of schedules for the volume backup policy. See + // see Schedules (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm#schedules) in + // Policy-Based Backups (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm) for more information. + Schedules []VolumeBackupSchedule `mandatory:"false" json:"schedules"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m UpdateVolumeBackupPolicyDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_policy_request_response.go new file mode 100644 index 000000000..1d1adad62 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_policy_request_response.go @@ -0,0 +1,92 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateVolumeBackupPolicyRequest wrapper for the UpdateVolumeBackupPolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVolumeBackupPolicy.go.html to see an example of how to use UpdateVolumeBackupPolicyRequest. +type UpdateVolumeBackupPolicyRequest struct { + + // The OCID of the volume backup policy. + PolicyId *string `mandatory:"true" contributesTo:"path" name:"policyId"` + + // Update volume backup policy fields + UpdateVolumeBackupPolicyDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateVolumeBackupPolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateVolumeBackupPolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateVolumeBackupPolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateVolumeBackupPolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateVolumeBackupPolicyResponse wrapper for the UpdateVolumeBackupPolicy operation +type UpdateVolumeBackupPolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeBackupPolicy instance + VolumeBackupPolicy `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateVolumeBackupPolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateVolumeBackupPolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_request_response.go new file mode 100644 index 000000000..80c8cfd77 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_backup_request_response.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateVolumeBackupRequest wrapper for the UpdateVolumeBackup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVolumeBackup.go.html to see an example of how to use UpdateVolumeBackupRequest. +type UpdateVolumeBackupRequest struct { + + // The OCID of the volume backup. + VolumeBackupId *string `mandatory:"true" contributesTo:"path" name:"volumeBackupId"` + + // Update volume backup fields + UpdateVolumeBackupDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateVolumeBackupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateVolumeBackupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateVolumeBackupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateVolumeBackupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateVolumeBackupResponse wrapper for the UpdateVolumeBackup operation +type UpdateVolumeBackupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeBackup instance + VolumeBackup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateVolumeBackupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateVolumeBackupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_details.go new file mode 100644 index 000000000..1e6c81cc4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_details.go @@ -0,0 +1,59 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateVolumeDetails The representation of UpdateVolumeDetails +type UpdateVolumeDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The number of volume performance units (VPUs) that will be applied to this volume per GB, + // representing the Block Volume service's elastic performance options. + // See Block Volume Elastic Performance (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/blockvolumeelasticperformance.htm) for more information. + // Allowed values: + // * `0`: Represents Lower Cost option. + // * `10`: Represents Balanced option. + // * `20`: Represents Higher Performance option. + VpusPerGB *int64 `mandatory:"false" json:"vpusPerGB"` + + // The size to resize the volume to in GBs. Has to be larger than the current size. + SizeInGBs *int64 `mandatory:"false" json:"sizeInGBs"` + + // Specifies whether the auto-tune performance is enabled for this volume. + IsAutoTuneEnabled *bool `mandatory:"false" json:"isAutoTuneEnabled"` + + // The list of block volume replicas that this volume will be updated to have + // in the specified destination availability domains. + BlockVolumeReplicas []BlockVolumeReplicaDetails `mandatory:"false" json:"blockVolumeReplicas"` +} + +func (m UpdateVolumeDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_backup_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_backup_details.go new file mode 100644 index 000000000..ed77a05d5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_backup_details.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateVolumeGroupBackupDetails The representation of UpdateVolumeGroupBackupDetails +type UpdateVolumeGroupBackupDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m UpdateVolumeGroupBackupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_backup_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_backup_request_response.go new file mode 100644 index 000000000..ead484154 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_backup_request_response.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateVolumeGroupBackupRequest wrapper for the UpdateVolumeGroupBackup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVolumeGroupBackup.go.html to see an example of how to use UpdateVolumeGroupBackupRequest. +type UpdateVolumeGroupBackupRequest struct { + + // The Oracle Cloud ID (OCID) that uniquely identifies the volume group backup. + VolumeGroupBackupId *string `mandatory:"true" contributesTo:"path" name:"volumeGroupBackupId"` + + // Update volume group backup fields + UpdateVolumeGroupBackupDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateVolumeGroupBackupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateVolumeGroupBackupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateVolumeGroupBackupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateVolumeGroupBackupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateVolumeGroupBackupResponse wrapper for the UpdateVolumeGroupBackup operation +type UpdateVolumeGroupBackupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeGroupBackup instance + VolumeGroupBackup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateVolumeGroupBackupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateVolumeGroupBackupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_details.go new file mode 100644 index 000000000..629c9838b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_details.go @@ -0,0 +1,43 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateVolumeGroupDetails The representation of UpdateVolumeGroupDetails +type UpdateVolumeGroupDetails struct { + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // OCIDs for the volumes in this volume group. + VolumeIds []string `mandatory:"false" json:"volumeIds"` +} + +func (m UpdateVolumeGroupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_request_response.go new file mode 100644 index 000000000..82183bb10 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_group_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateVolumeGroupRequest wrapper for the UpdateVolumeGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVolumeGroup.go.html to see an example of how to use UpdateVolumeGroupRequest. +type UpdateVolumeGroupRequest struct { + + // The Oracle Cloud ID (OCID) that uniquely identifies the volume group. + VolumeGroupId *string `mandatory:"true" contributesTo:"path" name:"volumeGroupId"` + + // Update volume group's set of volumes and/or display name + UpdateVolumeGroupDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateVolumeGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateVolumeGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateVolumeGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateVolumeGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateVolumeGroupResponse wrapper for the UpdateVolumeGroup operation +type UpdateVolumeGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeGroup instance + VolumeGroup `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateVolumeGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateVolumeGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_kms_key_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_kms_key_details.go new file mode 100644 index 000000000..4999cf459 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_kms_key_details.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateVolumeKmsKeyDetails The representation of UpdateVolumeKmsKeyDetails +type UpdateVolumeKmsKeyDetails struct { + + // The OCID of the new Key Management key to assign to protect the specified volume. + // This key has to be a valid Key Management key, and policies must exist to allow the user and the Block Volume service to access this key. + // If you specify the same OCID as the previous key's OCID, the Block Volume service will use it to regenerate a volume encryption key. + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` +} + +func (m UpdateVolumeKmsKeyDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_kms_key_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_kms_key_request_response.go new file mode 100644 index 000000000..1a5ed3083 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_kms_key_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateVolumeKmsKeyRequest wrapper for the UpdateVolumeKmsKey operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVolumeKmsKey.go.html to see an example of how to use UpdateVolumeKmsKeyRequest. +type UpdateVolumeKmsKeyRequest struct { + + // The OCID of the volume. + VolumeId *string `mandatory:"true" contributesTo:"path" name:"volumeId"` + + // Updates the Key Management master encryption key assigned to the specified volume. + UpdateVolumeKmsKeyDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateVolumeKmsKeyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateVolumeKmsKeyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateVolumeKmsKeyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateVolumeKmsKeyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateVolumeKmsKeyResponse wrapper for the UpdateVolumeKmsKey operation +type UpdateVolumeKmsKeyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The VolumeKmsKey instance + VolumeKmsKey `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateVolumeKmsKeyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateVolumeKmsKeyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_request_response.go new file mode 100644 index 000000000..5e23d3ddf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/update_volume_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateVolumeRequest wrapper for the UpdateVolume operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpdateVolume.go.html to see an example of how to use UpdateVolumeRequest. +type UpdateVolumeRequest struct { + + // The OCID of the volume. + VolumeId *string `mandatory:"true" contributesTo:"path" name:"volumeId"` + + // Update volume's display name. Avoid entering confidential information. + UpdateVolumeDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateVolumeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateVolumeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateVolumeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateVolumeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateVolumeResponse wrapper for the UpdateVolume operation +type UpdateVolumeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Volume instance + Volume `presentIn:"body"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateVolumeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateVolumeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/updated_network_security_group_security_rules.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/updated_network_security_group_security_rules.go new file mode 100644 index 000000000..afced982f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/updated_network_security_group_security_rules.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdatedNetworkSecurityGroupSecurityRules The representation of UpdatedNetworkSecurityGroupSecurityRules +type UpdatedNetworkSecurityGroupSecurityRules struct { + + // The NSG security rules that were updated. + SecurityRules []SecurityRule `mandatory:"false" json:"securityRules"` +} + +func (m UpdatedNetworkSecurityGroupSecurityRules) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/upgrade_drg_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/upgrade_drg_request_response.go new file mode 100644 index 000000000..bd42ad9ff --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/upgrade_drg_request_response.go @@ -0,0 +1,82 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpgradeDrgRequest wrapper for the UpgradeDrg operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/UpgradeDrg.go.html to see an example of how to use UpgradeDrgRequest. +type UpgradeDrgRequest struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the DRG. + DrgId *string `mandatory:"true" contributesTo:"path" name:"drgId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A token that uniquely identifies a request so it can be retried in case of a timeout or + // server error without risk of executing that same action again. Retry tokens expire after 24 + // hours, but can be invalidated before then due to conflicting operations (for example, if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpgradeDrgRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpgradeDrgRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpgradeDrgRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpgradeDrgRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpgradeDrgResponse wrapper for the UpgradeDrg operation +type UpgradeDrgResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response UpgradeDrgResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpgradeDrgResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/upgrade_status.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/upgrade_status.go new file mode 100644 index 000000000..80944febe --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/upgrade_status.go @@ -0,0 +1,60 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpgradeStatus The upgrade status of a DRG. +type UpgradeStatus struct { + + // The `drgId` of the upgraded DRG. + DrgId *string `mandatory:"true" json:"drgId"` + + // The current upgrade status of the DRG attachment. + Status UpgradeStatusStatusEnum `mandatory:"true" json:"status"` + + // The number of upgraded connections. + UpgradedConnections *string `mandatory:"true" json:"upgradedConnections"` +} + +func (m UpgradeStatus) String() string { + return common.PointerString(m) +} + +// UpgradeStatusStatusEnum Enum with underlying type: string +type UpgradeStatusStatusEnum string + +// Set of constants representing the allowable values for UpgradeStatusStatusEnum +const ( + UpgradeStatusStatusNotUpgraded UpgradeStatusStatusEnum = "NOT_UPGRADED" + UpgradeStatusStatusInProgress UpgradeStatusStatusEnum = "IN_PROGRESS" + UpgradeStatusStatusUpgraded UpgradeStatusStatusEnum = "UPGRADED" +) + +var mappingUpgradeStatusStatus = map[string]UpgradeStatusStatusEnum{ + "NOT_UPGRADED": UpgradeStatusStatusNotUpgraded, + "IN_PROGRESS": UpgradeStatusStatusInProgress, + "UPGRADED": UpgradeStatusStatusUpgraded, +} + +// GetUpgradeStatusStatusEnumValues Enumerates the set of values for UpgradeStatusStatusEnum +func GetUpgradeStatusStatusEnumValues() []UpgradeStatusStatusEnum { + values := make([]UpgradeStatusStatusEnum, 0) + for _, v := range mappingUpgradeStatusStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/validate_byoip_range_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/validate_byoip_range_request_response.go new file mode 100644 index 000000000..4b4f24fc1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/validate_byoip_range_request_response.go @@ -0,0 +1,75 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ValidateByoipRangeRequest wrapper for the ValidateByoipRange operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/ValidateByoipRange.go.html to see an example of how to use ValidateByoipRangeRequest. +type ValidateByoipRangeRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the `ByoipRange` resource containing the BYOIP CIDR block. + ByoipRangeId *string `mandatory:"true" contributesTo:"path" name:"byoipRangeId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ValidateByoipRangeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ValidateByoipRangeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ValidateByoipRangeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ValidateByoipRangeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ValidateByoipRangeResponse wrapper for the ValidateByoipRange operation +type ValidateByoipRangeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. Use GetWorkRequest (https://docs.cloud.oracle.com/api/#/en/workrequests/20160918/WorkRequest/GetWorkRequest) + // with this ID to track the status of the request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response ValidateByoipRangeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ValidateByoipRangeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn.go new file mode 100644 index 000000000..c69006a09 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn.go @@ -0,0 +1,125 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Vcn A virtual cloud network (VCN). For more information, see +// Overview of the Networking Service (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type Vcn struct { + + // Deprecated. The first CIDR IP address from cidrBlocks. + // Example: `172.16.0.0/16` + CidrBlock *string `mandatory:"true" json:"cidrBlock"` + + // The list of IPv4 CIDR blocks the VCN will use. + CidrBlocks []string `mandatory:"true" json:"cidrBlocks"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the VCN. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The VCN's Oracle ID (OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"true" json:"id"` + + // The VCN's current state. + LifecycleState VcnLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) for the VCN's default set of DHCP options. + DefaultDhcpOptionsId *string `mandatory:"false" json:"defaultDhcpOptionsId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) for the VCN's default route table. + DefaultRouteTableId *string `mandatory:"false" json:"defaultRouteTableId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) for the VCN's default security list. + DefaultSecurityListId *string `mandatory:"false" json:"defaultSecurityListId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // A DNS label for the VCN, used in conjunction with the VNIC's hostname and + // subnet's DNS label to form a fully qualified domain name (FQDN) for each VNIC + // within this subnet (for example, `bminstance-1.subnet123.vcn1.oraclevcn.com`). + // Must be an alphanumeric string that begins with a letter. + // The value cannot be changed. + // The absence of this parameter means the Internet and VCN Resolver will + // not work for this VCN. + // For more information, see + // DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). + // Example: `vcn1` + DnsLabel *string `mandatory:"false" json:"dnsLabel"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // For an IPv6-enabled VCN, this is the list of IPv6 CIDR blocks for the VCN's IP address space. + // The CIDRs are provided by Oracle and the sizes are always /56. + Ipv6CidrBlocks []string `mandatory:"false" json:"ipv6CidrBlocks"` + + // The date and time the VCN was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // The VCN's domain name, which consists of the VCN's DNS label, and the + // `oraclevcn.com` domain. + // For more information, see + // DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). + // Example: `vcn1.oraclevcn.com` + VcnDomainName *string `mandatory:"false" json:"vcnDomainName"` +} + +func (m Vcn) String() string { + return common.PointerString(m) +} + +// VcnLifecycleStateEnum Enum with underlying type: string +type VcnLifecycleStateEnum string + +// Set of constants representing the allowable values for VcnLifecycleStateEnum +const ( + VcnLifecycleStateProvisioning VcnLifecycleStateEnum = "PROVISIONING" + VcnLifecycleStateAvailable VcnLifecycleStateEnum = "AVAILABLE" + VcnLifecycleStateTerminating VcnLifecycleStateEnum = "TERMINATING" + VcnLifecycleStateTerminated VcnLifecycleStateEnum = "TERMINATED" + VcnLifecycleStateUpdating VcnLifecycleStateEnum = "UPDATING" +) + +var mappingVcnLifecycleState = map[string]VcnLifecycleStateEnum{ + "PROVISIONING": VcnLifecycleStateProvisioning, + "AVAILABLE": VcnLifecycleStateAvailable, + "TERMINATING": VcnLifecycleStateTerminating, + "TERMINATED": VcnLifecycleStateTerminated, + "UPDATING": VcnLifecycleStateUpdating, +} + +// GetVcnLifecycleStateEnumValues Enumerates the set of values for VcnLifecycleStateEnum +func GetVcnLifecycleStateEnumValues() []VcnLifecycleStateEnum { + values := make([]VcnLifecycleStateEnum, 0) + for _, v := range mappingVcnLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_dns_resolver_association.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_dns_resolver_association.go new file mode 100644 index 000000000..c6ac648e9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_dns_resolver_association.go @@ -0,0 +1,62 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VcnDnsResolverAssociation The information about the VCN and the DNS resolver in the association. +type VcnDnsResolverAssociation struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN in the association. + VcnId *string `mandatory:"true" json:"vcnId"` + + // The current state of the association. + LifecycleState VcnDnsResolverAssociationLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the DNS resolver in the association. + DnsResolverId *string `mandatory:"false" json:"dnsResolverId"` +} + +func (m VcnDnsResolverAssociation) String() string { + return common.PointerString(m) +} + +// VcnDnsResolverAssociationLifecycleStateEnum Enum with underlying type: string +type VcnDnsResolverAssociationLifecycleStateEnum string + +// Set of constants representing the allowable values for VcnDnsResolverAssociationLifecycleStateEnum +const ( + VcnDnsResolverAssociationLifecycleStateProvisioning VcnDnsResolverAssociationLifecycleStateEnum = "PROVISIONING" + VcnDnsResolverAssociationLifecycleStateAvailable VcnDnsResolverAssociationLifecycleStateEnum = "AVAILABLE" + VcnDnsResolverAssociationLifecycleStateTerminating VcnDnsResolverAssociationLifecycleStateEnum = "TERMINATING" + VcnDnsResolverAssociationLifecycleStateTerminated VcnDnsResolverAssociationLifecycleStateEnum = "TERMINATED" +) + +var mappingVcnDnsResolverAssociationLifecycleState = map[string]VcnDnsResolverAssociationLifecycleStateEnum{ + "PROVISIONING": VcnDnsResolverAssociationLifecycleStateProvisioning, + "AVAILABLE": VcnDnsResolverAssociationLifecycleStateAvailable, + "TERMINATING": VcnDnsResolverAssociationLifecycleStateTerminating, + "TERMINATED": VcnDnsResolverAssociationLifecycleStateTerminated, +} + +// GetVcnDnsResolverAssociationLifecycleStateEnumValues Enumerates the set of values for VcnDnsResolverAssociationLifecycleStateEnum +func GetVcnDnsResolverAssociationLifecycleStateEnumValues() []VcnDnsResolverAssociationLifecycleStateEnum { + values := make([]VcnDnsResolverAssociationLifecycleStateEnum, 0) + for _, v := range mappingVcnDnsResolverAssociationLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_drg_attachment_network_create_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_drg_attachment_network_create_details.go new file mode 100644 index 000000000..5f1fd4578 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_drg_attachment_network_create_details.go @@ -0,0 +1,57 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VcnDrgAttachmentNetworkCreateDetails Specifies the VCN Attachment +type VcnDrgAttachmentNetworkCreateDetails struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the network attached to the DRG. + Id *string `mandatory:"true" json:"id"` + + // This is the OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the route table that is used to route the traffic as it enters a VCN through this attachment. + // For information about why you would associate a route table with a DRG attachment, see + // Advanced Scenario: Transit Routing (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitrouting.htm). + // For information about why you would associate a route table with a DRG attachment, see: + // * Transit Routing: Access to Multiple VCNs in Same Region (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitrouting.htm) + // * Transit Routing: Private Access to Oracle Services (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitroutingoracleservices.htm) + RouteTableId *string `mandatory:"false" json:"routeTableId"` +} + +//GetId returns Id +func (m VcnDrgAttachmentNetworkCreateDetails) GetId() *string { + return m.Id +} + +func (m VcnDrgAttachmentNetworkCreateDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m VcnDrgAttachmentNetworkCreateDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeVcnDrgAttachmentNetworkCreateDetails VcnDrgAttachmentNetworkCreateDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeVcnDrgAttachmentNetworkCreateDetails + }{ + "VCN", + (MarshalTypeVcnDrgAttachmentNetworkCreateDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_drg_attachment_network_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_drg_attachment_network_details.go new file mode 100644 index 000000000..af6cc5e53 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_drg_attachment_network_details.go @@ -0,0 +1,55 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VcnDrgAttachmentNetworkDetails Specifies details within the VCN. +type VcnDrgAttachmentNetworkDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network attached to the DRG. + Id *string `mandatory:"true" json:"id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the route table the DRG attachment is using. + // For information about why you would associate a route table with a DRG attachment, see: + // * Transit Routing: Access to Multiple VCNs in Same Region (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitrouting.htm) + // * Transit Routing: Private Access to Oracle Services (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitroutingoracleservices.htm) + RouteTableId *string `mandatory:"false" json:"routeTableId"` +} + +//GetId returns Id +func (m VcnDrgAttachmentNetworkDetails) GetId() *string { + return m.Id +} + +func (m VcnDrgAttachmentNetworkDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m VcnDrgAttachmentNetworkDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeVcnDrgAttachmentNetworkDetails VcnDrgAttachmentNetworkDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeVcnDrgAttachmentNetworkDetails + }{ + "VCN", + (MarshalTypeVcnDrgAttachmentNetworkDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_drg_attachment_network_update_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_drg_attachment_network_update_details.go new file mode 100644 index 000000000..5c6520246 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_drg_attachment_network_update_details.go @@ -0,0 +1,47 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VcnDrgAttachmentNetworkUpdateDetails Specifies the update details for the VCN attachment. +type VcnDrgAttachmentNetworkUpdateDetails struct { + + // This is the OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the route table that is used to route the traffic as it enters a VCN through this attachment. + // For information about why you would associate a route table with a DRG attachment, see: + // * Transit Routing: Access to Multiple VCNs in Same Region (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitrouting.htm) + // * Transit Routing: Private Access to Oracle Services (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/transitroutingoracleservices.htm) + RouteTableId *string `mandatory:"false" json:"routeTableId"` +} + +func (m VcnDrgAttachmentNetworkUpdateDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m VcnDrgAttachmentNetworkUpdateDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeVcnDrgAttachmentNetworkUpdateDetails VcnDrgAttachmentNetworkUpdateDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeVcnDrgAttachmentNetworkUpdateDetails + }{ + "VCN", + (MarshalTypeVcnDrgAttachmentNetworkUpdateDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_topology.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_topology.go new file mode 100644 index 000000000..f034bea47 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/vcn_topology.go @@ -0,0 +1,107 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VcnTopology Defines the representation of a virtual network topology for a VCN. +type VcnTopology struct { + + // Lists entities comprising the virtual network topology. + Entities []interface{} `mandatory:"true" json:"entities"` + + // Lists relationships between entities in the virtual network topology. + Relationships []TopologyEntityRelationship `mandatory:"true" json:"relationships"` + + // Records when the virtual network topology was created, in RFC3339 (https://tools.ietf.org/html/rfc3339) format for date and time. + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN for which the topology is generated. + VcnId *string `mandatory:"false" json:"vcnId"` +} + +//GetEntities returns Entities +func (m VcnTopology) GetEntities() []interface{} { + return m.Entities +} + +//GetRelationships returns Relationships +func (m VcnTopology) GetRelationships() []TopologyEntityRelationship { + return m.Relationships +} + +//GetTimeCreated returns TimeCreated +func (m VcnTopology) GetTimeCreated() *common.SDKTime { + return m.TimeCreated +} + +func (m VcnTopology) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m VcnTopology) MarshalJSON() (buff []byte, e error) { + type MarshalTypeVcnTopology VcnTopology + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeVcnTopology + }{ + "VCN", + (MarshalTypeVcnTopology)(m), + } + + return json.Marshal(&s) +} + +// UnmarshalJSON unmarshals from json +func (m *VcnTopology) UnmarshalJSON(data []byte) (e error) { + model := struct { + VcnId *string `json:"vcnId"` + Entities []interface{} `json:"entities"` + Relationships []topologyentityrelationship `json:"relationships"` + TimeCreated *common.SDKTime `json:"timeCreated"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.VcnId = model.VcnId + + m.Entities = make([]interface{}, len(model.Entities)) + for i, n := range model.Entities { + m.Entities[i] = n + } + + m.Relationships = make([]TopologyEntityRelationship, len(model.Relationships)) + for i, n := range model.Relationships { + nn, e = n.UnmarshalPolymorphicJSON(n.JsonData) + if e != nil { + return e + } + if nn != nil { + m.Relationships[i] = nn.(TopologyEntityRelationship) + } else { + m.Relationships[i] = nil + } + } + + m.TimeCreated = model.TimeCreated + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit.go new file mode 100644 index 000000000..920924fa4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit.go @@ -0,0 +1,362 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VirtualCircuit For use with Oracle Cloud Infrastructure FastConnect. +// A virtual circuit is an isolated network path that runs over one or more physical +// network connections to provide a single, logical connection between the edge router +// on the customer's existing network and Oracle Cloud Infrastructure. *Private* +// virtual circuits support private peering, and *public* virtual circuits support +// public peering. For more information, see FastConnect Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/fastconnect.htm). +// Each virtual circuit is made up of information shared between a customer, Oracle, +// and a provider (if the customer is using FastConnect via a provider). Who fills in +// a given property of a virtual circuit depends on whether the BGP session related to +// that virtual circuit goes from the customer's edge router to Oracle, or from the provider's +// edge router to Oracle. Also, in the case where the customer is using a provider, values +// for some of the properties may not be present immediately, but may get filled in as the +// provider and Oracle each do their part to provision the virtual circuit. +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type VirtualCircuit struct { + + // The provisioned data rate of the connection. To get a list of the + // available bandwidth levels (that is, shapes), see + // ListFastConnectProviderVirtualCircuitBandwidthShapes. + // Example: `10 Gbps` + BandwidthShapeName *string `mandatory:"false" json:"bandwidthShapeName"` + + // Deprecated. Instead use the information in + // FastConnectProviderService. + BgpManagement VirtualCircuitBgpManagementEnum `mandatory:"false" json:"bgpManagement,omitempty"` + + // The state of the Ipv4 BGP session associated with the virtual circuit. + BgpSessionState VirtualCircuitBgpSessionStateEnum `mandatory:"false" json:"bgpSessionState,omitempty"` + + // The state of the Ipv6 BGP session associated with the virtual circuit. + BgpIpv6SessionState VirtualCircuitBgpIpv6SessionStateEnum `mandatory:"false" json:"bgpIpv6SessionState,omitempty"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the virtual circuit. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // An array of mappings, each containing properties for a + // cross-connect or cross-connect group that is associated with this + // virtual circuit. + CrossConnectMappings []CrossConnectMapping `mandatory:"false" json:"crossConnectMappings"` + + // The routing policy sets how routing information about the Oracle cloud is shared over a public virtual circuit. + // Policies available are: `ORACLE_SERVICE_NETWORK`, `REGIONAL`, `MARKET_LEVEL`, and `GLOBAL`. + // See Route Filtering (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/routingonprem.htm#route_filtering) for details. + // By default, routing information is shared for all routes in the same market. + RoutingPolicy []VirtualCircuitRoutingPolicyEnum `mandatory:"false" json:"routingPolicy,omitempty"` + + // Deprecated. Instead use `customerAsn`. + // If you specify values for both, the request will be rejected. + CustomerBgpAsn *int `mandatory:"false" json:"customerBgpAsn"` + + // The BGP ASN of the network at the other end of the BGP + // session from Oracle. If the session is between the customer's + // edge router and Oracle, the value is the customer's ASN. If the BGP + // session is between the provider's edge router and Oracle, the value + // is the provider's ASN. + // Can be a 2-byte or 4-byte ASN. Uses "asplain" format. + CustomerAsn *int64 `mandatory:"false" json:"customerAsn"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the customer's Drg + // that this virtual circuit uses. Applicable only to private virtual circuits. + GatewayId *string `mandatory:"false" json:"gatewayId"` + + // The virtual circuit's Oracle ID (OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"false" json:"id"` + + // The virtual circuit's current state. For information about + // the different states, see + // FastConnect Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/fastconnect.htm). + LifecycleState VirtualCircuitLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The Oracle BGP ASN. + OracleBgpAsn *int `mandatory:"false" json:"oracleBgpAsn"` + + // Deprecated. Instead use `providerServiceId`. + ProviderName *string `mandatory:"false" json:"providerName"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the service offered by the provider (if the customer is connecting via a provider). + ProviderServiceId *string `mandatory:"false" json:"providerServiceId"` + + // The service key name offered by the provider (if the customer is connecting via a provider). + ProviderServiceKeyName *string `mandatory:"false" json:"providerServiceKeyName"` + + // Deprecated. Instead use `providerServiceId`. + ProviderServiceName *string `mandatory:"false" json:"providerServiceName"` + + // The provider's state in relation to this virtual circuit (if the + // customer is connecting via a provider). ACTIVE means + // the provider has provisioned the virtual circuit from their end. + // INACTIVE means the provider has not yet provisioned the virtual + // circuit, or has de-provisioned it. + ProviderState VirtualCircuitProviderStateEnum `mandatory:"false" json:"providerState,omitempty"` + + // For a public virtual circuit. The public IP prefixes (CIDRs) the customer wants to + // advertise across the connection. All prefix sizes are allowed. + PublicPrefixes []string `mandatory:"false" json:"publicPrefixes"` + + // Provider-supplied reference information about this virtual circuit + // (if the customer is connecting via a provider). + ReferenceComment *string `mandatory:"false" json:"referenceComment"` + + // The Oracle Cloud Infrastructure region where this virtual + // circuit is located. + Region *string `mandatory:"false" json:"region"` + + // Provider service type. + ServiceType VirtualCircuitServiceTypeEnum `mandatory:"false" json:"serviceType,omitempty"` + + // The date and time the virtual circuit was created, + // in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // Whether the virtual circuit supports private or public peering. For more information, + // see FastConnect Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/fastconnect.htm). + Type VirtualCircuitTypeEnum `mandatory:"false" json:"type,omitempty"` + + // The layer 3 IP MTU to use on this virtual circuit. + IpMtu VirtualCircuitIpMtuEnum `mandatory:"false" json:"ipMtu,omitempty"` +} + +func (m VirtualCircuit) String() string { + return common.PointerString(m) +} + +// VirtualCircuitBgpManagementEnum Enum with underlying type: string +type VirtualCircuitBgpManagementEnum string + +// Set of constants representing the allowable values for VirtualCircuitBgpManagementEnum +const ( + VirtualCircuitBgpManagementCustomerManaged VirtualCircuitBgpManagementEnum = "CUSTOMER_MANAGED" + VirtualCircuitBgpManagementProviderManaged VirtualCircuitBgpManagementEnum = "PROVIDER_MANAGED" + VirtualCircuitBgpManagementOracleManaged VirtualCircuitBgpManagementEnum = "ORACLE_MANAGED" +) + +var mappingVirtualCircuitBgpManagement = map[string]VirtualCircuitBgpManagementEnum{ + "CUSTOMER_MANAGED": VirtualCircuitBgpManagementCustomerManaged, + "PROVIDER_MANAGED": VirtualCircuitBgpManagementProviderManaged, + "ORACLE_MANAGED": VirtualCircuitBgpManagementOracleManaged, +} + +// GetVirtualCircuitBgpManagementEnumValues Enumerates the set of values for VirtualCircuitBgpManagementEnum +func GetVirtualCircuitBgpManagementEnumValues() []VirtualCircuitBgpManagementEnum { + values := make([]VirtualCircuitBgpManagementEnum, 0) + for _, v := range mappingVirtualCircuitBgpManagement { + values = append(values, v) + } + return values +} + +// VirtualCircuitBgpSessionStateEnum Enum with underlying type: string +type VirtualCircuitBgpSessionStateEnum string + +// Set of constants representing the allowable values for VirtualCircuitBgpSessionStateEnum +const ( + VirtualCircuitBgpSessionStateUp VirtualCircuitBgpSessionStateEnum = "UP" + VirtualCircuitBgpSessionStateDown VirtualCircuitBgpSessionStateEnum = "DOWN" +) + +var mappingVirtualCircuitBgpSessionState = map[string]VirtualCircuitBgpSessionStateEnum{ + "UP": VirtualCircuitBgpSessionStateUp, + "DOWN": VirtualCircuitBgpSessionStateDown, +} + +// GetVirtualCircuitBgpSessionStateEnumValues Enumerates the set of values for VirtualCircuitBgpSessionStateEnum +func GetVirtualCircuitBgpSessionStateEnumValues() []VirtualCircuitBgpSessionStateEnum { + values := make([]VirtualCircuitBgpSessionStateEnum, 0) + for _, v := range mappingVirtualCircuitBgpSessionState { + values = append(values, v) + } + return values +} + +// VirtualCircuitBgpIpv6SessionStateEnum Enum with underlying type: string +type VirtualCircuitBgpIpv6SessionStateEnum string + +// Set of constants representing the allowable values for VirtualCircuitBgpIpv6SessionStateEnum +const ( + VirtualCircuitBgpIpv6SessionStateUp VirtualCircuitBgpIpv6SessionStateEnum = "UP" + VirtualCircuitBgpIpv6SessionStateDown VirtualCircuitBgpIpv6SessionStateEnum = "DOWN" +) + +var mappingVirtualCircuitBgpIpv6SessionState = map[string]VirtualCircuitBgpIpv6SessionStateEnum{ + "UP": VirtualCircuitBgpIpv6SessionStateUp, + "DOWN": VirtualCircuitBgpIpv6SessionStateDown, +} + +// GetVirtualCircuitBgpIpv6SessionStateEnumValues Enumerates the set of values for VirtualCircuitBgpIpv6SessionStateEnum +func GetVirtualCircuitBgpIpv6SessionStateEnumValues() []VirtualCircuitBgpIpv6SessionStateEnum { + values := make([]VirtualCircuitBgpIpv6SessionStateEnum, 0) + for _, v := range mappingVirtualCircuitBgpIpv6SessionState { + values = append(values, v) + } + return values +} + +// VirtualCircuitRoutingPolicyEnum Enum with underlying type: string +type VirtualCircuitRoutingPolicyEnum string + +// Set of constants representing the allowable values for VirtualCircuitRoutingPolicyEnum +const ( + VirtualCircuitRoutingPolicyOracleServiceNetwork VirtualCircuitRoutingPolicyEnum = "ORACLE_SERVICE_NETWORK" + VirtualCircuitRoutingPolicyRegional VirtualCircuitRoutingPolicyEnum = "REGIONAL" + VirtualCircuitRoutingPolicyMarketLevel VirtualCircuitRoutingPolicyEnum = "MARKET_LEVEL" + VirtualCircuitRoutingPolicyGlobal VirtualCircuitRoutingPolicyEnum = "GLOBAL" +) + +var mappingVirtualCircuitRoutingPolicy = map[string]VirtualCircuitRoutingPolicyEnum{ + "ORACLE_SERVICE_NETWORK": VirtualCircuitRoutingPolicyOracleServiceNetwork, + "REGIONAL": VirtualCircuitRoutingPolicyRegional, + "MARKET_LEVEL": VirtualCircuitRoutingPolicyMarketLevel, + "GLOBAL": VirtualCircuitRoutingPolicyGlobal, +} + +// GetVirtualCircuitRoutingPolicyEnumValues Enumerates the set of values for VirtualCircuitRoutingPolicyEnum +func GetVirtualCircuitRoutingPolicyEnumValues() []VirtualCircuitRoutingPolicyEnum { + values := make([]VirtualCircuitRoutingPolicyEnum, 0) + for _, v := range mappingVirtualCircuitRoutingPolicy { + values = append(values, v) + } + return values +} + +// VirtualCircuitLifecycleStateEnum Enum with underlying type: string +type VirtualCircuitLifecycleStateEnum string + +// Set of constants representing the allowable values for VirtualCircuitLifecycleStateEnum +const ( + VirtualCircuitLifecycleStatePendingProvider VirtualCircuitLifecycleStateEnum = "PENDING_PROVIDER" + VirtualCircuitLifecycleStateVerifying VirtualCircuitLifecycleStateEnum = "VERIFYING" + VirtualCircuitLifecycleStateProvisioning VirtualCircuitLifecycleStateEnum = "PROVISIONING" + VirtualCircuitLifecycleStateProvisioned VirtualCircuitLifecycleStateEnum = "PROVISIONED" + VirtualCircuitLifecycleStateFailed VirtualCircuitLifecycleStateEnum = "FAILED" + VirtualCircuitLifecycleStateInactive VirtualCircuitLifecycleStateEnum = "INACTIVE" + VirtualCircuitLifecycleStateTerminating VirtualCircuitLifecycleStateEnum = "TERMINATING" + VirtualCircuitLifecycleStateTerminated VirtualCircuitLifecycleStateEnum = "TERMINATED" +) + +var mappingVirtualCircuitLifecycleState = map[string]VirtualCircuitLifecycleStateEnum{ + "PENDING_PROVIDER": VirtualCircuitLifecycleStatePendingProvider, + "VERIFYING": VirtualCircuitLifecycleStateVerifying, + "PROVISIONING": VirtualCircuitLifecycleStateProvisioning, + "PROVISIONED": VirtualCircuitLifecycleStateProvisioned, + "FAILED": VirtualCircuitLifecycleStateFailed, + "INACTIVE": VirtualCircuitLifecycleStateInactive, + "TERMINATING": VirtualCircuitLifecycleStateTerminating, + "TERMINATED": VirtualCircuitLifecycleStateTerminated, +} + +// GetVirtualCircuitLifecycleStateEnumValues Enumerates the set of values for VirtualCircuitLifecycleStateEnum +func GetVirtualCircuitLifecycleStateEnumValues() []VirtualCircuitLifecycleStateEnum { + values := make([]VirtualCircuitLifecycleStateEnum, 0) + for _, v := range mappingVirtualCircuitLifecycleState { + values = append(values, v) + } + return values +} + +// VirtualCircuitProviderStateEnum Enum with underlying type: string +type VirtualCircuitProviderStateEnum string + +// Set of constants representing the allowable values for VirtualCircuitProviderStateEnum +const ( + VirtualCircuitProviderStateActive VirtualCircuitProviderStateEnum = "ACTIVE" + VirtualCircuitProviderStateInactive VirtualCircuitProviderStateEnum = "INACTIVE" +) + +var mappingVirtualCircuitProviderState = map[string]VirtualCircuitProviderStateEnum{ + "ACTIVE": VirtualCircuitProviderStateActive, + "INACTIVE": VirtualCircuitProviderStateInactive, +} + +// GetVirtualCircuitProviderStateEnumValues Enumerates the set of values for VirtualCircuitProviderStateEnum +func GetVirtualCircuitProviderStateEnumValues() []VirtualCircuitProviderStateEnum { + values := make([]VirtualCircuitProviderStateEnum, 0) + for _, v := range mappingVirtualCircuitProviderState { + values = append(values, v) + } + return values +} + +// VirtualCircuitServiceTypeEnum Enum with underlying type: string +type VirtualCircuitServiceTypeEnum string + +// Set of constants representing the allowable values for VirtualCircuitServiceTypeEnum +const ( + VirtualCircuitServiceTypeColocated VirtualCircuitServiceTypeEnum = "COLOCATED" + VirtualCircuitServiceTypeLayer2 VirtualCircuitServiceTypeEnum = "LAYER2" + VirtualCircuitServiceTypeLayer3 VirtualCircuitServiceTypeEnum = "LAYER3" +) + +var mappingVirtualCircuitServiceType = map[string]VirtualCircuitServiceTypeEnum{ + "COLOCATED": VirtualCircuitServiceTypeColocated, + "LAYER2": VirtualCircuitServiceTypeLayer2, + "LAYER3": VirtualCircuitServiceTypeLayer3, +} + +// GetVirtualCircuitServiceTypeEnumValues Enumerates the set of values for VirtualCircuitServiceTypeEnum +func GetVirtualCircuitServiceTypeEnumValues() []VirtualCircuitServiceTypeEnum { + values := make([]VirtualCircuitServiceTypeEnum, 0) + for _, v := range mappingVirtualCircuitServiceType { + values = append(values, v) + } + return values +} + +// VirtualCircuitTypeEnum Enum with underlying type: string +type VirtualCircuitTypeEnum string + +// Set of constants representing the allowable values for VirtualCircuitTypeEnum +const ( + VirtualCircuitTypePublic VirtualCircuitTypeEnum = "PUBLIC" + VirtualCircuitTypePrivate VirtualCircuitTypeEnum = "PRIVATE" +) + +var mappingVirtualCircuitType = map[string]VirtualCircuitTypeEnum{ + "PUBLIC": VirtualCircuitTypePublic, + "PRIVATE": VirtualCircuitTypePrivate, +} + +// GetVirtualCircuitTypeEnumValues Enumerates the set of values for VirtualCircuitTypeEnum +func GetVirtualCircuitTypeEnumValues() []VirtualCircuitTypeEnum { + values := make([]VirtualCircuitTypeEnum, 0) + for _, v := range mappingVirtualCircuitType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_bandwidth_shape.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_bandwidth_shape.go new file mode 100644 index 000000000..eb4368b69 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_bandwidth_shape.go @@ -0,0 +1,34 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VirtualCircuitBandwidthShape An individual bandwidth level for virtual circuits. +type VirtualCircuitBandwidthShape struct { + + // The name of the bandwidth shape. + // Example: `10 Gbps` + Name *string `mandatory:"true" json:"name"` + + // The bandwidth in Mbps. + // Example: `10000` + BandwidthInMbps *int `mandatory:"false" json:"bandwidthInMbps"` +} + +func (m VirtualCircuitBandwidthShape) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_drg_attachment_network_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_drg_attachment_network_details.go new file mode 100644 index 000000000..bdf78b89f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_drg_attachment_network_details.go @@ -0,0 +1,49 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VirtualCircuitDrgAttachmentNetworkDetails Specifies the virtual circuit attached to the DRG. +type VirtualCircuitDrgAttachmentNetworkDetails struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the network attached to the DRG. + Id *string `mandatory:"true" json:"id"` +} + +//GetId returns Id +func (m VirtualCircuitDrgAttachmentNetworkDetails) GetId() *string { + return m.Id +} + +func (m VirtualCircuitDrgAttachmentNetworkDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m VirtualCircuitDrgAttachmentNetworkDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeVirtualCircuitDrgAttachmentNetworkDetails VirtualCircuitDrgAttachmentNetworkDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeVirtualCircuitDrgAttachmentNetworkDetails + }{ + "VIRTUAL_CIRCUIT", + (MarshalTypeVirtualCircuitDrgAttachmentNetworkDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_ip_mtu.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_ip_mtu.go new file mode 100644 index 000000000..58ad1ce1d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_ip_mtu.go @@ -0,0 +1,37 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +// VirtualCircuitIpMtuEnum Enum with underlying type: string +type VirtualCircuitIpMtuEnum string + +// Set of constants representing the allowable values for VirtualCircuitIpMtuEnum +const ( + VirtualCircuitIpMtuMtu1500 VirtualCircuitIpMtuEnum = "MTU_1500" + VirtualCircuitIpMtuMtu9000 VirtualCircuitIpMtuEnum = "MTU_9000" +) + +var mappingVirtualCircuitIpMtu = map[string]VirtualCircuitIpMtuEnum{ + "MTU_1500": VirtualCircuitIpMtuMtu1500, + "MTU_9000": VirtualCircuitIpMtuMtu9000, +} + +// GetVirtualCircuitIpMtuEnumValues Enumerates the set of values for VirtualCircuitIpMtuEnum +func GetVirtualCircuitIpMtuEnumValues() []VirtualCircuitIpMtuEnum { + values := make([]VirtualCircuitIpMtuEnum, 0) + for _, v := range mappingVirtualCircuitIpMtu { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_public_prefix.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_public_prefix.go new file mode 100644 index 000000000..47c03f6e9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/virtual_circuit_public_prefix.go @@ -0,0 +1,63 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VirtualCircuitPublicPrefix A public IP prefix and its details. With a public virtual circuit, the customer +// specifies the customer-owned public IP prefixes to advertise across the connection. +// For more information, see FastConnect Overview (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/fastconnect.htm). +type VirtualCircuitPublicPrefix struct { + + // Publix IP prefix (CIDR) that the customer specified. + CidrBlock *string `mandatory:"true" json:"cidrBlock"` + + // Oracle must verify that the customer owns the public IP prefix before traffic + // for that prefix can flow across the virtual circuit. Verification can take a + // few business days. `IN_PROGRESS` means Oracle is verifying the prefix. `COMPLETED` + // means verification succeeded. `FAILED` means verification failed and traffic for + // this prefix will not flow across the connection. + VerificationState VirtualCircuitPublicPrefixVerificationStateEnum `mandatory:"true" json:"verificationState"` +} + +func (m VirtualCircuitPublicPrefix) String() string { + return common.PointerString(m) +} + +// VirtualCircuitPublicPrefixVerificationStateEnum Enum with underlying type: string +type VirtualCircuitPublicPrefixVerificationStateEnum string + +// Set of constants representing the allowable values for VirtualCircuitPublicPrefixVerificationStateEnum +const ( + VirtualCircuitPublicPrefixVerificationStateInProgress VirtualCircuitPublicPrefixVerificationStateEnum = "IN_PROGRESS" + VirtualCircuitPublicPrefixVerificationStateCompleted VirtualCircuitPublicPrefixVerificationStateEnum = "COMPLETED" + VirtualCircuitPublicPrefixVerificationStateFailed VirtualCircuitPublicPrefixVerificationStateEnum = "FAILED" +) + +var mappingVirtualCircuitPublicPrefixVerificationState = map[string]VirtualCircuitPublicPrefixVerificationStateEnum{ + "IN_PROGRESS": VirtualCircuitPublicPrefixVerificationStateInProgress, + "COMPLETED": VirtualCircuitPublicPrefixVerificationStateCompleted, + "FAILED": VirtualCircuitPublicPrefixVerificationStateFailed, +} + +// GetVirtualCircuitPublicPrefixVerificationStateEnumValues Enumerates the set of values for VirtualCircuitPublicPrefixVerificationStateEnum +func GetVirtualCircuitPublicPrefixVerificationStateEnumValues() []VirtualCircuitPublicPrefixVerificationStateEnum { + values := make([]VirtualCircuitPublicPrefixVerificationStateEnum, 0) + for _, v := range mappingVirtualCircuitPublicPrefixVerificationState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/vlan.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/vlan.go new file mode 100644 index 000000000..e07fb352b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/vlan.go @@ -0,0 +1,115 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Vlan A resource to be used only with the Oracle Cloud VMware Solution. +// Conceptually, a virtual LAN (VLAN) is a broadcast domain that is created +// by partitioning and isolating a network at the data link layer (a *layer 2 network*). +// VLANs work by using IEEE 802.1Q VLAN tags. Layer 2 traffic is forwarded within the +// VLAN based on MAC learning. +// In the Networking service, a VLAN is an object within a VCN. You use VLANs to +// partition the VCN at the data link layer (layer 2). A VLAN is analagous to a subnet, +// which is an object for partitioning the VCN at the IP layer (layer 3). +type Vlan struct { + + // The range of IPv4 addresses that will be used for layer 3 communication with + // hosts outside the VLAN. + // Example: `192.168.1.0/24` + CidrBlock *string `mandatory:"true" json:"cidrBlock"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the VLAN. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The VLAN's Oracle ID (OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)). + Id *string `mandatory:"true" json:"id"` + + // The VLAN's current state. + LifecycleState VlanLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN the VLAN is in. + VcnId *string `mandatory:"true" json:"vcnId"` + + // The VLAN's availability domain. This attribute will be null if this is a regional VLAN + // rather than an AD-specific VLAN. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"false" json:"availabilityDomain"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // A list of the OCIDs of the network security groups (NSGs) to use with this VLAN. + // All VNICs in the VLAN belong to these NSGs. For more + // information about NSGs, see + // NetworkSecurityGroup. + NsgIds []string `mandatory:"false" json:"nsgIds"` + + // The IEEE 802.1Q VLAN tag of this VLAN. + // Example: `100` + VlanTag *int `mandatory:"false" json:"vlanTag"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the route table that the VLAN uses. + RouteTableId *string `mandatory:"false" json:"routeTableId"` + + // The date and time the VLAN was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` +} + +func (m Vlan) String() string { + return common.PointerString(m) +} + +// VlanLifecycleStateEnum Enum with underlying type: string +type VlanLifecycleStateEnum string + +// Set of constants representing the allowable values for VlanLifecycleStateEnum +const ( + VlanLifecycleStateProvisioning VlanLifecycleStateEnum = "PROVISIONING" + VlanLifecycleStateAvailable VlanLifecycleStateEnum = "AVAILABLE" + VlanLifecycleStateTerminating VlanLifecycleStateEnum = "TERMINATING" + VlanLifecycleStateTerminated VlanLifecycleStateEnum = "TERMINATED" + VlanLifecycleStateUpdating VlanLifecycleStateEnum = "UPDATING" +) + +var mappingVlanLifecycleState = map[string]VlanLifecycleStateEnum{ + "PROVISIONING": VlanLifecycleStateProvisioning, + "AVAILABLE": VlanLifecycleStateAvailable, + "TERMINATING": VlanLifecycleStateTerminating, + "TERMINATED": VlanLifecycleStateTerminated, + "UPDATING": VlanLifecycleStateUpdating, +} + +// GetVlanLifecycleStateEnumValues Enumerates the set of values for VlanLifecycleStateEnum +func GetVlanLifecycleStateEnumValues() []VlanLifecycleStateEnum { + values := make([]VlanLifecycleStateEnum, 0) + for _, v := range mappingVlanLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/vnic.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/vnic.go new file mode 100644 index 000000000..0937049ea --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/vnic.go @@ -0,0 +1,158 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Vnic A virtual network interface card. Each VNIC resides in a subnet in a VCN. +// An instance attaches to a VNIC to obtain a network connection into the VCN +// through that subnet. Each instance has a *primary VNIC* that is automatically +// created and attached during launch. You can add *secondary VNICs* to an +// instance after it's launched. For more information, see +// Virtual Network Interface Cards (VNICs) (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingVNICs.htm). +// Each VNIC has a *primary private IP* that is automatically assigned during launch. +// You can add *secondary private IPs* to a VNIC after it's created. For more +// information, see CreatePrivateIp and +// IP Addresses (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingIPaddresses.htm). +// +// If you are an Oracle Cloud VMware Solution customer, you will have secondary VNICs +// that reside in a VLAN instead of a subnet. These VNICs have other differences, which +// are called out in the descriptions of the relevant attributes in the `Vnic` object. +// Also see Vlan. +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +type Vnic struct { + + // The VNIC's availability domain. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the VNIC. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VNIC. + Id *string `mandatory:"true" json:"id"` + + // The current state of the VNIC. + LifecycleState VnicLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the VNIC was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The hostname for the VNIC's primary private IP. Used for DNS. The value is the hostname + // portion of the primary private IP's fully qualified domain name (FQDN) + // (for example, `bminstance-1` in FQDN `bminstance-1.subnet123.vcn1.oraclevcn.com`). + // Must be unique across all VNICs in the subnet and comply with + // RFC 952 (https://tools.ietf.org/html/rfc952) and + // RFC 1123 (https://tools.ietf.org/html/rfc1123). + // For more information, see + // DNS in Your Virtual Cloud Network (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/dns.htm). + // Example: `bminstance-1` + HostnameLabel *string `mandatory:"false" json:"hostnameLabel"` + + // Whether the VNIC is the primary VNIC (the VNIC that is automatically created + // and attached during instance launch). + IsPrimary *bool `mandatory:"false" json:"isPrimary"` + + // The MAC address of the VNIC. + // If the VNIC belongs to a VLAN as part of the Oracle Cloud VMware Solution, + // the MAC address is learned. If the VNIC belongs to a subnet, the + // MAC address is a static, Oracle-provided value. + // Example: `00:00:00:00:00:01` + MacAddress *string `mandatory:"false" json:"macAddress"` + + // A list of the OCIDs of the network security groups that the VNIC belongs to. + // If the VNIC belongs to a VLAN as part of the Oracle Cloud VMware Solution (instead of + // belonging to a subnet), the value of the `nsgIds` attribute is ignored. Instead, the + // VNIC belongs to the NSGs that are associated with the VLAN itself. See Vlan. + // For more information about NSGs, see + // NetworkSecurityGroup. + NsgIds []string `mandatory:"false" json:"nsgIds"` + + // If the VNIC belongs to a VLAN as part of the Oracle Cloud VMware Solution (instead of + // belonging to a subnet), the `vlanId` is the OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VLAN the VNIC is in. See + // Vlan. If the VNIC is instead in a subnet, `subnetId` has a value. + VlanId *string `mandatory:"false" json:"vlanId"` + + // The private IP address of the primary `privateIp` object on the VNIC. + // The address is within the CIDR of the VNIC's subnet. + // Example: `10.0.3.3` + PrivateIp *string `mandatory:"false" json:"privateIp"` + + // The public IP address of the VNIC, if one is assigned. + PublicIp *string `mandatory:"false" json:"publicIp"` + + // Whether the source/destination check is disabled on the VNIC. + // Defaults to `false`, which means the check is performed. For information + // about why you would skip the source/destination check, see + // Using a Private IP as a Route Target (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingroutetables.htm#privateip). + // + // If the VNIC belongs to a VLAN as part of the Oracle Cloud VMware Solution (instead of + // belonging to a subnet), the `skipSourceDestCheck` attribute is `true`. + // This is because the source/destination check is always disabled for VNICs in a VLAN. + // Example: `true` + SkipSourceDestCheck *bool `mandatory:"false" json:"skipSourceDestCheck"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the subnet the VNIC is in. + SubnetId *string `mandatory:"false" json:"subnetId"` +} + +func (m Vnic) String() string { + return common.PointerString(m) +} + +// VnicLifecycleStateEnum Enum with underlying type: string +type VnicLifecycleStateEnum string + +// Set of constants representing the allowable values for VnicLifecycleStateEnum +const ( + VnicLifecycleStateProvisioning VnicLifecycleStateEnum = "PROVISIONING" + VnicLifecycleStateAvailable VnicLifecycleStateEnum = "AVAILABLE" + VnicLifecycleStateTerminating VnicLifecycleStateEnum = "TERMINATING" + VnicLifecycleStateTerminated VnicLifecycleStateEnum = "TERMINATED" +) + +var mappingVnicLifecycleState = map[string]VnicLifecycleStateEnum{ + "PROVISIONING": VnicLifecycleStateProvisioning, + "AVAILABLE": VnicLifecycleStateAvailable, + "TERMINATING": VnicLifecycleStateTerminating, + "TERMINATED": VnicLifecycleStateTerminated, +} + +// GetVnicLifecycleStateEnumValues Enumerates the set of values for VnicLifecycleStateEnum +func GetVnicLifecycleStateEnumValues() []VnicLifecycleStateEnum { + values := make([]VnicLifecycleStateEnum, 0) + for _, v := range mappingVnicLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/vnic_attachment.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/vnic_attachment.go new file mode 100644 index 000000000..2765e0e55 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/vnic_attachment.go @@ -0,0 +1,108 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VnicAttachment Represents an attachment between a VNIC and an instance. For more information, see +// Virtual Network Interface Cards (VNICs) (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingVNICs.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you +// supply string values using the API. +type VnicAttachment struct { + + // The availability domain of the instance. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment the VNIC attachment is in, which is the same + // compartment the instance is in. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the VNIC attachment. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the instance. + InstanceId *string `mandatory:"true" json:"instanceId"` + + // The current state of the VNIC attachment. + LifecycleState VnicAttachmentLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the VNIC attachment was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Which physical network interface card (NIC) the VNIC uses. + // Certain bare metal instance shapes have two active physical NICs (0 and 1). If + // you add a secondary VNIC to one of these instances, you can specify which NIC + // the VNIC will use. For more information, see + // Virtual Network Interface Cards (VNICs) (https://docs.cloud.oracle.com/iaas/Content/Network/Tasks/managingVNICs.htm). + NicIndex *int `mandatory:"false" json:"nicIndex"` + + // The OCID of the subnet to create the VNIC in. + SubnetId *string `mandatory:"false" json:"subnetId"` + + // The OCID of the VLAN to create the VNIC in. Creating the VNIC in a VLAN (instead + // of a subnet) is possible only if you are an Oracle Cloud VMware Solution customer. + // See Vlan. + // An error is returned if the instance already has a VNIC attached to it from this VLAN. + VlanId *string `mandatory:"false" json:"vlanId"` + + // The Oracle-assigned VLAN tag of the attached VNIC. Available after the + // attachment process is complete. + // However, if the VNIC belongs to a VLAN as part of the Oracle Cloud VMware Solution, + // the `vlanTag` value is instead the value of the `vlanTag` attribute for the VLAN. + // See Vlan. + // Example: `0` + VlanTag *int `mandatory:"false" json:"vlanTag"` + + // The OCID of the VNIC. Available after the attachment process is complete. + VnicId *string `mandatory:"false" json:"vnicId"` +} + +func (m VnicAttachment) String() string { + return common.PointerString(m) +} + +// VnicAttachmentLifecycleStateEnum Enum with underlying type: string +type VnicAttachmentLifecycleStateEnum string + +// Set of constants representing the allowable values for VnicAttachmentLifecycleStateEnum +const ( + VnicAttachmentLifecycleStateAttaching VnicAttachmentLifecycleStateEnum = "ATTACHING" + VnicAttachmentLifecycleStateAttached VnicAttachmentLifecycleStateEnum = "ATTACHED" + VnicAttachmentLifecycleStateDetaching VnicAttachmentLifecycleStateEnum = "DETACHING" + VnicAttachmentLifecycleStateDetached VnicAttachmentLifecycleStateEnum = "DETACHED" +) + +var mappingVnicAttachmentLifecycleState = map[string]VnicAttachmentLifecycleStateEnum{ + "ATTACHING": VnicAttachmentLifecycleStateAttaching, + "ATTACHED": VnicAttachmentLifecycleStateAttached, + "DETACHING": VnicAttachmentLifecycleStateDetaching, + "DETACHED": VnicAttachmentLifecycleStateDetached, +} + +// GetVnicAttachmentLifecycleStateEnumValues Enumerates the set of values for VnicAttachmentLifecycleStateEnum +func GetVnicAttachmentLifecycleStateEnumValues() []VnicAttachmentLifecycleStateEnum { + values := make([]VnicAttachmentLifecycleStateEnum, 0) + for _, v := range mappingVnicAttachmentLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume.go new file mode 100644 index 000000000..307239ca8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume.go @@ -0,0 +1,216 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Volume A detachable block volume device that allows you to dynamically expand +// the storage capacity of an instance. For more information, see +// Overview of Cloud Volume Storage (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you +// supply string values using the API. +type Volume struct { + + // The availability domain of the volume. + // Example: `Uocm:PHX-AD-1` + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment that contains the volume. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The OCID of the volume. + Id *string `mandatory:"true" json:"id"` + + // The current state of a volume. + LifecycleState VolumeLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The size of the volume in MBs. This field is deprecated. Use + // sizeInGBs instead. + SizeInMBs *int64 `mandatory:"true" json:"sizeInMBs"` + + // The date and time the volume was created. Format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // System tags for this resource. Each key is predefined and scoped to a namespace. + // Example: `{"foo-namespace": {"bar-key": "value"}}` + SystemTags map[string]map[string]interface{} `mandatory:"false" json:"systemTags"` + + // Specifies whether the cloned volume's data has finished copying from the source volume or backup. + IsHydrated *bool `mandatory:"false" json:"isHydrated"` + + // The OCID of the Key Management key which is the master encryption key for the volume. + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` + + // The number of volume performance units (VPUs) that will be applied to this volume per GB, + // representing the Block Volume service's elastic performance options. + // See Block Volume Elastic Performance (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/blockvolumeelasticperformance.htm) for more information. + // Allowed values: + // * `0`: Represents Lower Cost option. + // * `10`: Represents Balanced option. + // * `20`: Represents Higher Performance option. + VpusPerGB *int64 `mandatory:"false" json:"vpusPerGB"` + + // The size of the volume in GBs. + SizeInGBs *int64 `mandatory:"false" json:"sizeInGBs"` + + SourceDetails VolumeSourceDetails `mandatory:"false" json:"sourceDetails"` + + // The OCID of the source volume group. + VolumeGroupId *string `mandatory:"false" json:"volumeGroupId"` + + // Specifies whether the auto-tune performance is enabled for this volume. + IsAutoTuneEnabled *bool `mandatory:"false" json:"isAutoTuneEnabled"` + + // The number of Volume Performance Units per GB that this volume is effectively tuned to when it's idle. + AutoTunedVpusPerGB *int64 `mandatory:"false" json:"autoTunedVpusPerGB"` + + // The list of block volume replicas of this volume. + BlockVolumeReplicas []BlockVolumeReplicaInfo `mandatory:"false" json:"blockVolumeReplicas"` +} + +func (m Volume) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *Volume) UnmarshalJSON(data []byte) (e error) { + model := struct { + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + FreeformTags map[string]string `json:"freeformTags"` + SystemTags map[string]map[string]interface{} `json:"systemTags"` + IsHydrated *bool `json:"isHydrated"` + KmsKeyId *string `json:"kmsKeyId"` + VpusPerGB *int64 `json:"vpusPerGB"` + SizeInGBs *int64 `json:"sizeInGBs"` + SourceDetails volumesourcedetails `json:"sourceDetails"` + VolumeGroupId *string `json:"volumeGroupId"` + IsAutoTuneEnabled *bool `json:"isAutoTuneEnabled"` + AutoTunedVpusPerGB *int64 `json:"autoTunedVpusPerGB"` + BlockVolumeReplicas []BlockVolumeReplicaInfo `json:"blockVolumeReplicas"` + AvailabilityDomain *string `json:"availabilityDomain"` + CompartmentId *string `json:"compartmentId"` + DisplayName *string `json:"displayName"` + Id *string `json:"id"` + LifecycleState VolumeLifecycleStateEnum `json:"lifecycleState"` + SizeInMBs *int64 `json:"sizeInMBs"` + TimeCreated *common.SDKTime `json:"timeCreated"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.DefinedTags = model.DefinedTags + + m.FreeformTags = model.FreeformTags + + m.SystemTags = model.SystemTags + + m.IsHydrated = model.IsHydrated + + m.KmsKeyId = model.KmsKeyId + + m.VpusPerGB = model.VpusPerGB + + m.SizeInGBs = model.SizeInGBs + + nn, e = model.SourceDetails.UnmarshalPolymorphicJSON(model.SourceDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.SourceDetails = nn.(VolumeSourceDetails) + } else { + m.SourceDetails = nil + } + + m.VolumeGroupId = model.VolumeGroupId + + m.IsAutoTuneEnabled = model.IsAutoTuneEnabled + + m.AutoTunedVpusPerGB = model.AutoTunedVpusPerGB + + m.BlockVolumeReplicas = make([]BlockVolumeReplicaInfo, len(model.BlockVolumeReplicas)) + for i, n := range model.BlockVolumeReplicas { + m.BlockVolumeReplicas[i] = n + } + + m.AvailabilityDomain = model.AvailabilityDomain + + m.CompartmentId = model.CompartmentId + + m.DisplayName = model.DisplayName + + m.Id = model.Id + + m.LifecycleState = model.LifecycleState + + m.SizeInMBs = model.SizeInMBs + + m.TimeCreated = model.TimeCreated + + return +} + +// VolumeLifecycleStateEnum Enum with underlying type: string +type VolumeLifecycleStateEnum string + +// Set of constants representing the allowable values for VolumeLifecycleStateEnum +const ( + VolumeLifecycleStateProvisioning VolumeLifecycleStateEnum = "PROVISIONING" + VolumeLifecycleStateRestoring VolumeLifecycleStateEnum = "RESTORING" + VolumeLifecycleStateAvailable VolumeLifecycleStateEnum = "AVAILABLE" + VolumeLifecycleStateTerminating VolumeLifecycleStateEnum = "TERMINATING" + VolumeLifecycleStateTerminated VolumeLifecycleStateEnum = "TERMINATED" + VolumeLifecycleStateFaulty VolumeLifecycleStateEnum = "FAULTY" +) + +var mappingVolumeLifecycleState = map[string]VolumeLifecycleStateEnum{ + "PROVISIONING": VolumeLifecycleStateProvisioning, + "RESTORING": VolumeLifecycleStateRestoring, + "AVAILABLE": VolumeLifecycleStateAvailable, + "TERMINATING": VolumeLifecycleStateTerminating, + "TERMINATED": VolumeLifecycleStateTerminated, + "FAULTY": VolumeLifecycleStateFaulty, +} + +// GetVolumeLifecycleStateEnumValues Enumerates the set of values for VolumeLifecycleStateEnum +func GetVolumeLifecycleStateEnumValues() []VolumeLifecycleStateEnum { + values := make([]VolumeLifecycleStateEnum, 0) + for _, v := range mappingVolumeLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_attachment.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_attachment.go new file mode 100644 index 000000000..b29764408 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_attachment.go @@ -0,0 +1,287 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeAttachment A base object for all types of attachments between a storage volume and an instance. +// For specific details about iSCSI attachments, see +// IScsiVolumeAttachment. +// For general information about volume attachments, see +// Overview of Block Volume Storage (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you +// supply string values using the API. +type VolumeAttachment interface { + + // The availability domain of an instance. + // Example: `Uocm:PHX-AD-1` + GetAvailabilityDomain() *string + + // The OCID of the compartment. + GetCompartmentId() *string + + // The OCID of the volume attachment. + GetId() *string + + // The OCID of the instance the volume is attached to. + GetInstanceId() *string + + // The current state of the volume attachment. + GetLifecycleState() VolumeAttachmentLifecycleStateEnum + + // The date and time the volume was created, in the format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + // Example: `2016-08-25T21:10:29.600Z` + GetTimeCreated() *common.SDKTime + + // The OCID of the volume. + GetVolumeId() *string + + // The device name. + GetDevice() *string + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + GetDisplayName() *string + + // Whether the attachment was created in read-only mode. + GetIsReadOnly() *bool + + // Whether the attachment should be created in shareable mode. If an attachment + // is created in shareable mode, then other instances can attach the same volume, provided + // that they also create their attachments in shareable mode. Only certain volume types can + // be attached in shareable mode. Defaults to false if not specified. + GetIsShareable() *bool + + // Whether in-transit encryption for the data volume's paravirtualized attachment is enabled or not. + GetIsPvEncryptionInTransitEnabled() *bool + + // Whether the attachment is multipath or not. + GetIsMultipath() *bool + + // The iscsi login state of the volume attachment. For a multipath volume attachment, + // all iscsi sessions need to be all logged-in or logged-out to be in logged-in or logged-out state. + GetIscsiLoginState() VolumeAttachmentIscsiLoginStateEnum +} + +type volumeattachment struct { + JsonData []byte + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + CompartmentId *string `mandatory:"true" json:"compartmentId"` + Id *string `mandatory:"true" json:"id"` + InstanceId *string `mandatory:"true" json:"instanceId"` + LifecycleState VolumeAttachmentLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + VolumeId *string `mandatory:"true" json:"volumeId"` + Device *string `mandatory:"false" json:"device"` + DisplayName *string `mandatory:"false" json:"displayName"` + IsReadOnly *bool `mandatory:"false" json:"isReadOnly"` + IsShareable *bool `mandatory:"false" json:"isShareable"` + IsPvEncryptionInTransitEnabled *bool `mandatory:"false" json:"isPvEncryptionInTransitEnabled"` + IsMultipath *bool `mandatory:"false" json:"isMultipath"` + IscsiLoginState VolumeAttachmentIscsiLoginStateEnum `mandatory:"false" json:"iscsiLoginState,omitempty"` + AttachmentType string `json:"attachmentType"` +} + +// UnmarshalJSON unmarshals json +func (m *volumeattachment) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalervolumeattachment volumeattachment + s := struct { + Model Unmarshalervolumeattachment + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.AvailabilityDomain = s.Model.AvailabilityDomain + m.CompartmentId = s.Model.CompartmentId + m.Id = s.Model.Id + m.InstanceId = s.Model.InstanceId + m.LifecycleState = s.Model.LifecycleState + m.TimeCreated = s.Model.TimeCreated + m.VolumeId = s.Model.VolumeId + m.Device = s.Model.Device + m.DisplayName = s.Model.DisplayName + m.IsReadOnly = s.Model.IsReadOnly + m.IsShareable = s.Model.IsShareable + m.IsPvEncryptionInTransitEnabled = s.Model.IsPvEncryptionInTransitEnabled + m.IsMultipath = s.Model.IsMultipath + m.IscsiLoginState = s.Model.IscsiLoginState + m.AttachmentType = s.Model.AttachmentType + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *volumeattachment) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.AttachmentType { + case "iscsi": + mm := IScsiVolumeAttachment{} + err = json.Unmarshal(data, &mm) + return mm, err + case "emulated": + mm := EmulatedVolumeAttachment{} + err = json.Unmarshal(data, &mm) + return mm, err + case "paravirtualized": + mm := ParavirtualizedVolumeAttachment{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetAvailabilityDomain returns AvailabilityDomain +func (m volumeattachment) GetAvailabilityDomain() *string { + return m.AvailabilityDomain +} + +//GetCompartmentId returns CompartmentId +func (m volumeattachment) GetCompartmentId() *string { + return m.CompartmentId +} + +//GetId returns Id +func (m volumeattachment) GetId() *string { + return m.Id +} + +//GetInstanceId returns InstanceId +func (m volumeattachment) GetInstanceId() *string { + return m.InstanceId +} + +//GetLifecycleState returns LifecycleState +func (m volumeattachment) GetLifecycleState() VolumeAttachmentLifecycleStateEnum { + return m.LifecycleState +} + +//GetTimeCreated returns TimeCreated +func (m volumeattachment) GetTimeCreated() *common.SDKTime { + return m.TimeCreated +} + +//GetVolumeId returns VolumeId +func (m volumeattachment) GetVolumeId() *string { + return m.VolumeId +} + +//GetDevice returns Device +func (m volumeattachment) GetDevice() *string { + return m.Device +} + +//GetDisplayName returns DisplayName +func (m volumeattachment) GetDisplayName() *string { + return m.DisplayName +} + +//GetIsReadOnly returns IsReadOnly +func (m volumeattachment) GetIsReadOnly() *bool { + return m.IsReadOnly +} + +//GetIsShareable returns IsShareable +func (m volumeattachment) GetIsShareable() *bool { + return m.IsShareable +} + +//GetIsPvEncryptionInTransitEnabled returns IsPvEncryptionInTransitEnabled +func (m volumeattachment) GetIsPvEncryptionInTransitEnabled() *bool { + return m.IsPvEncryptionInTransitEnabled +} + +//GetIsMultipath returns IsMultipath +func (m volumeattachment) GetIsMultipath() *bool { + return m.IsMultipath +} + +//GetIscsiLoginState returns IscsiLoginState +func (m volumeattachment) GetIscsiLoginState() VolumeAttachmentIscsiLoginStateEnum { + return m.IscsiLoginState +} + +func (m volumeattachment) String() string { + return common.PointerString(m) +} + +// VolumeAttachmentLifecycleStateEnum Enum with underlying type: string +type VolumeAttachmentLifecycleStateEnum string + +// Set of constants representing the allowable values for VolumeAttachmentLifecycleStateEnum +const ( + VolumeAttachmentLifecycleStateAttaching VolumeAttachmentLifecycleStateEnum = "ATTACHING" + VolumeAttachmentLifecycleStateAttached VolumeAttachmentLifecycleStateEnum = "ATTACHED" + VolumeAttachmentLifecycleStateDetaching VolumeAttachmentLifecycleStateEnum = "DETACHING" + VolumeAttachmentLifecycleStateDetached VolumeAttachmentLifecycleStateEnum = "DETACHED" +) + +var mappingVolumeAttachmentLifecycleState = map[string]VolumeAttachmentLifecycleStateEnum{ + "ATTACHING": VolumeAttachmentLifecycleStateAttaching, + "ATTACHED": VolumeAttachmentLifecycleStateAttached, + "DETACHING": VolumeAttachmentLifecycleStateDetaching, + "DETACHED": VolumeAttachmentLifecycleStateDetached, +} + +// GetVolumeAttachmentLifecycleStateEnumValues Enumerates the set of values for VolumeAttachmentLifecycleStateEnum +func GetVolumeAttachmentLifecycleStateEnumValues() []VolumeAttachmentLifecycleStateEnum { + values := make([]VolumeAttachmentLifecycleStateEnum, 0) + for _, v := range mappingVolumeAttachmentLifecycleState { + values = append(values, v) + } + return values +} + +// VolumeAttachmentIscsiLoginStateEnum Enum with underlying type: string +type VolumeAttachmentIscsiLoginStateEnum string + +// Set of constants representing the allowable values for VolumeAttachmentIscsiLoginStateEnum +const ( + VolumeAttachmentIscsiLoginStateUnknown VolumeAttachmentIscsiLoginStateEnum = "UNKNOWN" + VolumeAttachmentIscsiLoginStateLoggingIn VolumeAttachmentIscsiLoginStateEnum = "LOGGING_IN" + VolumeAttachmentIscsiLoginStateLoginSucceeded VolumeAttachmentIscsiLoginStateEnum = "LOGIN_SUCCEEDED" + VolumeAttachmentIscsiLoginStateLoginFailed VolumeAttachmentIscsiLoginStateEnum = "LOGIN_FAILED" + VolumeAttachmentIscsiLoginStateLoggingOut VolumeAttachmentIscsiLoginStateEnum = "LOGGING_OUT" + VolumeAttachmentIscsiLoginStateLogoutSucceeded VolumeAttachmentIscsiLoginStateEnum = "LOGOUT_SUCCEEDED" + VolumeAttachmentIscsiLoginStateLogoutFailed VolumeAttachmentIscsiLoginStateEnum = "LOGOUT_FAILED" +) + +var mappingVolumeAttachmentIscsiLoginState = map[string]VolumeAttachmentIscsiLoginStateEnum{ + "UNKNOWN": VolumeAttachmentIscsiLoginStateUnknown, + "LOGGING_IN": VolumeAttachmentIscsiLoginStateLoggingIn, + "LOGIN_SUCCEEDED": VolumeAttachmentIscsiLoginStateLoginSucceeded, + "LOGIN_FAILED": VolumeAttachmentIscsiLoginStateLoginFailed, + "LOGGING_OUT": VolumeAttachmentIscsiLoginStateLoggingOut, + "LOGOUT_SUCCEEDED": VolumeAttachmentIscsiLoginStateLogoutSucceeded, + "LOGOUT_FAILED": VolumeAttachmentIscsiLoginStateLogoutFailed, +} + +// GetVolumeAttachmentIscsiLoginStateEnumValues Enumerates the set of values for VolumeAttachmentIscsiLoginStateEnum +func GetVolumeAttachmentIscsiLoginStateEnumValues() []VolumeAttachmentIscsiLoginStateEnum { + values := make([]VolumeAttachmentIscsiLoginStateEnum, 0) + for _, v := range mappingVolumeAttachmentIscsiLoginState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup.go new file mode 100644 index 000000000..944a3a5d6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup.go @@ -0,0 +1,185 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeBackup A point-in-time copy of a volume that can then be used to create a new block volume +// or recover a block volume. For more information, see +// Overview of Cloud Volume Storage (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you +// supply string values using the API. +type VolumeBackup struct { + + // The OCID of the compartment that contains the volume backup. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The OCID of the volume backup. + Id *string `mandatory:"true" json:"id"` + + // The current state of a volume backup. + LifecycleState VolumeBackupLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the volume backup was created. This is the time the actual point-in-time image + // of the volume data was taken. Format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The type of a volume backup. + Type VolumeBackupTypeEnum `mandatory:"true" json:"type"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // System tags for this resource. Each key is predefined and scoped to a namespace. + // Example: `{"foo-namespace": {"bar-key": "value"}}` + SystemTags map[string]map[string]interface{} `mandatory:"false" json:"systemTags"` + + // The date and time the volume backup will expire and be automatically deleted. + // Format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). This parameter will always be present for backups that + // were created automatically by a scheduled-backup policy. For manually created backups, + // it will be absent, signifying that there is no expiration time and the backup will + // last forever until manually deleted. + ExpirationTime *common.SDKTime `mandatory:"false" json:"expirationTime"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The OCID of the Key Management key which is the master encryption key for the volume backup. + // For more information about the Key Management service and encryption keys, see + // Overview of Key Management (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Concepts/keyoverview.htm) and + // Using Keys (https://docs.cloud.oracle.com/iaas/Content/KeyManagement/Tasks/usingkeys.htm). + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` + + // The size of the volume, in GBs. + SizeInGBs *int64 `mandatory:"false" json:"sizeInGBs"` + + // The size of the volume in MBs. The value must be a multiple of 1024. + // This field is deprecated. Please use sizeInGBs. + SizeInMBs *int64 `mandatory:"false" json:"sizeInMBs"` + + // Specifies whether the backup was created manually, or via scheduled backup policy. + SourceType VolumeBackupSourceTypeEnum `mandatory:"false" json:"sourceType,omitempty"` + + // The OCID of the source volume backup. + SourceVolumeBackupId *string `mandatory:"false" json:"sourceVolumeBackupId"` + + // The date and time the request to create the volume backup was received. Format defined by [RFC3339]https://tools.ietf.org/html/rfc3339. + TimeRequestReceived *common.SDKTime `mandatory:"false" json:"timeRequestReceived"` + + // The size used by the backup, in GBs. It is typically smaller than sizeInGBs, depending on the space + // consumed on the volume and whether the backup is full or incremental. + UniqueSizeInGBs *int64 `mandatory:"false" json:"uniqueSizeInGBs"` + + // The size used by the backup, in MBs. It is typically smaller than sizeInMBs, depending on the space + // consumed on the volume and whether the backup is full or incremental. + // This field is deprecated. Please use uniqueSizeInGBs. + UniqueSizeInMbs *int64 `mandatory:"false" json:"uniqueSizeInMbs"` + + // The OCID of the volume. + VolumeId *string `mandatory:"false" json:"volumeId"` +} + +func (m VolumeBackup) String() string { + return common.PointerString(m) +} + +// VolumeBackupLifecycleStateEnum Enum with underlying type: string +type VolumeBackupLifecycleStateEnum string + +// Set of constants representing the allowable values for VolumeBackupLifecycleStateEnum +const ( + VolumeBackupLifecycleStateCreating VolumeBackupLifecycleStateEnum = "CREATING" + VolumeBackupLifecycleStateAvailable VolumeBackupLifecycleStateEnum = "AVAILABLE" + VolumeBackupLifecycleStateTerminating VolumeBackupLifecycleStateEnum = "TERMINATING" + VolumeBackupLifecycleStateTerminated VolumeBackupLifecycleStateEnum = "TERMINATED" + VolumeBackupLifecycleStateFaulty VolumeBackupLifecycleStateEnum = "FAULTY" + VolumeBackupLifecycleStateRequestReceived VolumeBackupLifecycleStateEnum = "REQUEST_RECEIVED" +) + +var mappingVolumeBackupLifecycleState = map[string]VolumeBackupLifecycleStateEnum{ + "CREATING": VolumeBackupLifecycleStateCreating, + "AVAILABLE": VolumeBackupLifecycleStateAvailable, + "TERMINATING": VolumeBackupLifecycleStateTerminating, + "TERMINATED": VolumeBackupLifecycleStateTerminated, + "FAULTY": VolumeBackupLifecycleStateFaulty, + "REQUEST_RECEIVED": VolumeBackupLifecycleStateRequestReceived, +} + +// GetVolumeBackupLifecycleStateEnumValues Enumerates the set of values for VolumeBackupLifecycleStateEnum +func GetVolumeBackupLifecycleStateEnumValues() []VolumeBackupLifecycleStateEnum { + values := make([]VolumeBackupLifecycleStateEnum, 0) + for _, v := range mappingVolumeBackupLifecycleState { + values = append(values, v) + } + return values +} + +// VolumeBackupSourceTypeEnum Enum with underlying type: string +type VolumeBackupSourceTypeEnum string + +// Set of constants representing the allowable values for VolumeBackupSourceTypeEnum +const ( + VolumeBackupSourceTypeManual VolumeBackupSourceTypeEnum = "MANUAL" + VolumeBackupSourceTypeScheduled VolumeBackupSourceTypeEnum = "SCHEDULED" +) + +var mappingVolumeBackupSourceType = map[string]VolumeBackupSourceTypeEnum{ + "MANUAL": VolumeBackupSourceTypeManual, + "SCHEDULED": VolumeBackupSourceTypeScheduled, +} + +// GetVolumeBackupSourceTypeEnumValues Enumerates the set of values for VolumeBackupSourceTypeEnum +func GetVolumeBackupSourceTypeEnumValues() []VolumeBackupSourceTypeEnum { + values := make([]VolumeBackupSourceTypeEnum, 0) + for _, v := range mappingVolumeBackupSourceType { + values = append(values, v) + } + return values +} + +// VolumeBackupTypeEnum Enum with underlying type: string +type VolumeBackupTypeEnum string + +// Set of constants representing the allowable values for VolumeBackupTypeEnum +const ( + VolumeBackupTypeFull VolumeBackupTypeEnum = "FULL" + VolumeBackupTypeIncremental VolumeBackupTypeEnum = "INCREMENTAL" +) + +var mappingVolumeBackupType = map[string]VolumeBackupTypeEnum{ + "FULL": VolumeBackupTypeFull, + "INCREMENTAL": VolumeBackupTypeIncremental, +} + +// GetVolumeBackupTypeEnumValues Enumerates the set of values for VolumeBackupTypeEnum +func GetVolumeBackupTypeEnumValues() []VolumeBackupTypeEnum { + values := make([]VolumeBackupTypeEnum, 0) + for _, v := range mappingVolumeBackupType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup_policy.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup_policy.go new file mode 100644 index 000000000..273df2788 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup_policy.go @@ -0,0 +1,60 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeBackupPolicy A policy for automatically creating volume backups according to a +// recurring schedule. Has a set of one or more schedules that control when and +// how backups are created. +// **Warning:** Oracle recommends that you avoid using any confidential information when you +// supply string values using the API. +type VolumeBackupPolicy struct { + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The OCID of the volume backup policy. + Id *string `mandatory:"true" json:"id"` + + // The collection of schedules that this policy will apply. + Schedules []VolumeBackupSchedule `mandatory:"true" json:"schedules"` + + // The date and time the volume backup policy was created. Format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The paired destination region for copying scheduled backups to. Example `us-ashburn-1`. + // See Region Pairs (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm#RegionPairs) for details about paired regions. + DestinationRegion *string `mandatory:"false" json:"destinationRegion"` + + // The OCID of the compartment that contains the volume backup. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` +} + +func (m VolumeBackupPolicy) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup_policy_assignment.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup_policy_assignment.go new file mode 100644 index 000000000..db9fd9804 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup_policy_assignment.go @@ -0,0 +1,41 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeBackupPolicyAssignment Specifies the volume that the volume backup policy is assigned to. +// For more information about Oracle defined backup policies and custom backup policies, +// see Policy-Based Backups (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm). +type VolumeBackupPolicyAssignment struct { + + // The OCID of the volume the policy has been assigned to. + AssetId *string `mandatory:"true" json:"assetId"` + + // The OCID of the volume backup policy assignment. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the volume backup policy that has been assigned to the volume. + PolicyId *string `mandatory:"true" json:"policyId"` + + // The date and time the volume backup policy was assigned to the volume. The format is + // defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` +} + +func (m VolumeBackupPolicyAssignment) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup_schedule.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup_schedule.go new file mode 100644 index 000000000..ff75b2f66 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_backup_schedule.go @@ -0,0 +1,248 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeBackupSchedule Defines the backup frequency and retention period for a volume backup policy. For more information, +// see Policy-Based Backups (https://docs.cloud.oracle.com/iaas/Content/Block/Tasks/schedulingvolumebackups.htm). +type VolumeBackupSchedule struct { + + // The type of volume backup to create. + BackupType VolumeBackupScheduleBackupTypeEnum `mandatory:"true" json:"backupType"` + + // The volume backup frequency. + Period VolumeBackupSchedulePeriodEnum `mandatory:"true" json:"period"` + + // How long, in seconds, to keep the volume backups created by this schedule. + RetentionSeconds *int `mandatory:"true" json:"retentionSeconds"` + + // The number of seconds that the volume backup start + // time should be shifted from the default interval boundaries specified by + // the period. The volume backup start time is the frequency start time plus the offset. + OffsetSeconds *int `mandatory:"false" json:"offsetSeconds"` + + // Indicates how the offset is defined. If value is `STRUCTURED`, + // then `hourOfDay`, `dayOfWeek`, `dayOfMonth`, and `month` fields are used + // and `offsetSeconds` will be ignored in requests and users should ignore its + // value from the responses. + // `hourOfDay` is applicable for periods `ONE_DAY`, + // `ONE_WEEK`, `ONE_MONTH` and `ONE_YEAR`. + // `dayOfWeek` is applicable for period + // `ONE_WEEK`. + // `dayOfMonth` is applicable for periods `ONE_MONTH` and `ONE_YEAR`. + // 'month' is applicable for period 'ONE_YEAR'. + // They will be ignored in the requests for inapplicable periods. + // If value is `NUMERIC_SECONDS`, then `offsetSeconds` + // will be used for both requests and responses and the structured fields will be + // ignored in the requests and users should ignore their values from the responses. + // For clients using older versions of Apis and not sending `offsetType` in their + // requests, the behaviour is just like `NUMERIC_SECONDS`. + OffsetType VolumeBackupScheduleOffsetTypeEnum `mandatory:"false" json:"offsetType,omitempty"` + + // The hour of the day to schedule the volume backup. + HourOfDay *int `mandatory:"false" json:"hourOfDay"` + + // The day of the week to schedule the volume backup. + DayOfWeek VolumeBackupScheduleDayOfWeekEnum `mandatory:"false" json:"dayOfWeek,omitempty"` + + // The day of the month to schedule the volume backup. + DayOfMonth *int `mandatory:"false" json:"dayOfMonth"` + + // The month of the year to schedule the volume backup. + Month VolumeBackupScheduleMonthEnum `mandatory:"false" json:"month,omitempty"` + + // Specifies what time zone is the schedule in + TimeZone VolumeBackupScheduleTimeZoneEnum `mandatory:"false" json:"timeZone,omitempty"` +} + +func (m VolumeBackupSchedule) String() string { + return common.PointerString(m) +} + +// VolumeBackupScheduleBackupTypeEnum Enum with underlying type: string +type VolumeBackupScheduleBackupTypeEnum string + +// Set of constants representing the allowable values for VolumeBackupScheduleBackupTypeEnum +const ( + VolumeBackupScheduleBackupTypeFull VolumeBackupScheduleBackupTypeEnum = "FULL" + VolumeBackupScheduleBackupTypeIncremental VolumeBackupScheduleBackupTypeEnum = "INCREMENTAL" +) + +var mappingVolumeBackupScheduleBackupType = map[string]VolumeBackupScheduleBackupTypeEnum{ + "FULL": VolumeBackupScheduleBackupTypeFull, + "INCREMENTAL": VolumeBackupScheduleBackupTypeIncremental, +} + +// GetVolumeBackupScheduleBackupTypeEnumValues Enumerates the set of values for VolumeBackupScheduleBackupTypeEnum +func GetVolumeBackupScheduleBackupTypeEnumValues() []VolumeBackupScheduleBackupTypeEnum { + values := make([]VolumeBackupScheduleBackupTypeEnum, 0) + for _, v := range mappingVolumeBackupScheduleBackupType { + values = append(values, v) + } + return values +} + +// VolumeBackupSchedulePeriodEnum Enum with underlying type: string +type VolumeBackupSchedulePeriodEnum string + +// Set of constants representing the allowable values for VolumeBackupSchedulePeriodEnum +const ( + VolumeBackupSchedulePeriodHour VolumeBackupSchedulePeriodEnum = "ONE_HOUR" + VolumeBackupSchedulePeriodDay VolumeBackupSchedulePeriodEnum = "ONE_DAY" + VolumeBackupSchedulePeriodWeek VolumeBackupSchedulePeriodEnum = "ONE_WEEK" + VolumeBackupSchedulePeriodMonth VolumeBackupSchedulePeriodEnum = "ONE_MONTH" + VolumeBackupSchedulePeriodYear VolumeBackupSchedulePeriodEnum = "ONE_YEAR" +) + +var mappingVolumeBackupSchedulePeriod = map[string]VolumeBackupSchedulePeriodEnum{ + "ONE_HOUR": VolumeBackupSchedulePeriodHour, + "ONE_DAY": VolumeBackupSchedulePeriodDay, + "ONE_WEEK": VolumeBackupSchedulePeriodWeek, + "ONE_MONTH": VolumeBackupSchedulePeriodMonth, + "ONE_YEAR": VolumeBackupSchedulePeriodYear, +} + +// GetVolumeBackupSchedulePeriodEnumValues Enumerates the set of values for VolumeBackupSchedulePeriodEnum +func GetVolumeBackupSchedulePeriodEnumValues() []VolumeBackupSchedulePeriodEnum { + values := make([]VolumeBackupSchedulePeriodEnum, 0) + for _, v := range mappingVolumeBackupSchedulePeriod { + values = append(values, v) + } + return values +} + +// VolumeBackupScheduleOffsetTypeEnum Enum with underlying type: string +type VolumeBackupScheduleOffsetTypeEnum string + +// Set of constants representing the allowable values for VolumeBackupScheduleOffsetTypeEnum +const ( + VolumeBackupScheduleOffsetTypeStructured VolumeBackupScheduleOffsetTypeEnum = "STRUCTURED" + VolumeBackupScheduleOffsetTypeNumericSeconds VolumeBackupScheduleOffsetTypeEnum = "NUMERIC_SECONDS" +) + +var mappingVolumeBackupScheduleOffsetType = map[string]VolumeBackupScheduleOffsetTypeEnum{ + "STRUCTURED": VolumeBackupScheduleOffsetTypeStructured, + "NUMERIC_SECONDS": VolumeBackupScheduleOffsetTypeNumericSeconds, +} + +// GetVolumeBackupScheduleOffsetTypeEnumValues Enumerates the set of values for VolumeBackupScheduleOffsetTypeEnum +func GetVolumeBackupScheduleOffsetTypeEnumValues() []VolumeBackupScheduleOffsetTypeEnum { + values := make([]VolumeBackupScheduleOffsetTypeEnum, 0) + for _, v := range mappingVolumeBackupScheduleOffsetType { + values = append(values, v) + } + return values +} + +// VolumeBackupScheduleDayOfWeekEnum Enum with underlying type: string +type VolumeBackupScheduleDayOfWeekEnum string + +// Set of constants representing the allowable values for VolumeBackupScheduleDayOfWeekEnum +const ( + VolumeBackupScheduleDayOfWeekMonday VolumeBackupScheduleDayOfWeekEnum = "MONDAY" + VolumeBackupScheduleDayOfWeekTuesday VolumeBackupScheduleDayOfWeekEnum = "TUESDAY" + VolumeBackupScheduleDayOfWeekWednesday VolumeBackupScheduleDayOfWeekEnum = "WEDNESDAY" + VolumeBackupScheduleDayOfWeekThursday VolumeBackupScheduleDayOfWeekEnum = "THURSDAY" + VolumeBackupScheduleDayOfWeekFriday VolumeBackupScheduleDayOfWeekEnum = "FRIDAY" + VolumeBackupScheduleDayOfWeekSaturday VolumeBackupScheduleDayOfWeekEnum = "SATURDAY" + VolumeBackupScheduleDayOfWeekSunday VolumeBackupScheduleDayOfWeekEnum = "SUNDAY" +) + +var mappingVolumeBackupScheduleDayOfWeek = map[string]VolumeBackupScheduleDayOfWeekEnum{ + "MONDAY": VolumeBackupScheduleDayOfWeekMonday, + "TUESDAY": VolumeBackupScheduleDayOfWeekTuesday, + "WEDNESDAY": VolumeBackupScheduleDayOfWeekWednesday, + "THURSDAY": VolumeBackupScheduleDayOfWeekThursday, + "FRIDAY": VolumeBackupScheduleDayOfWeekFriday, + "SATURDAY": VolumeBackupScheduleDayOfWeekSaturday, + "SUNDAY": VolumeBackupScheduleDayOfWeekSunday, +} + +// GetVolumeBackupScheduleDayOfWeekEnumValues Enumerates the set of values for VolumeBackupScheduleDayOfWeekEnum +func GetVolumeBackupScheduleDayOfWeekEnumValues() []VolumeBackupScheduleDayOfWeekEnum { + values := make([]VolumeBackupScheduleDayOfWeekEnum, 0) + for _, v := range mappingVolumeBackupScheduleDayOfWeek { + values = append(values, v) + } + return values +} + +// VolumeBackupScheduleMonthEnum Enum with underlying type: string +type VolumeBackupScheduleMonthEnum string + +// Set of constants representing the allowable values for VolumeBackupScheduleMonthEnum +const ( + VolumeBackupScheduleMonthJanuary VolumeBackupScheduleMonthEnum = "JANUARY" + VolumeBackupScheduleMonthFebruary VolumeBackupScheduleMonthEnum = "FEBRUARY" + VolumeBackupScheduleMonthMarch VolumeBackupScheduleMonthEnum = "MARCH" + VolumeBackupScheduleMonthApril VolumeBackupScheduleMonthEnum = "APRIL" + VolumeBackupScheduleMonthMay VolumeBackupScheduleMonthEnum = "MAY" + VolumeBackupScheduleMonthJune VolumeBackupScheduleMonthEnum = "JUNE" + VolumeBackupScheduleMonthJuly VolumeBackupScheduleMonthEnum = "JULY" + VolumeBackupScheduleMonthAugust VolumeBackupScheduleMonthEnum = "AUGUST" + VolumeBackupScheduleMonthSeptember VolumeBackupScheduleMonthEnum = "SEPTEMBER" + VolumeBackupScheduleMonthOctober VolumeBackupScheduleMonthEnum = "OCTOBER" + VolumeBackupScheduleMonthNovember VolumeBackupScheduleMonthEnum = "NOVEMBER" + VolumeBackupScheduleMonthDecember VolumeBackupScheduleMonthEnum = "DECEMBER" +) + +var mappingVolumeBackupScheduleMonth = map[string]VolumeBackupScheduleMonthEnum{ + "JANUARY": VolumeBackupScheduleMonthJanuary, + "FEBRUARY": VolumeBackupScheduleMonthFebruary, + "MARCH": VolumeBackupScheduleMonthMarch, + "APRIL": VolumeBackupScheduleMonthApril, + "MAY": VolumeBackupScheduleMonthMay, + "JUNE": VolumeBackupScheduleMonthJune, + "JULY": VolumeBackupScheduleMonthJuly, + "AUGUST": VolumeBackupScheduleMonthAugust, + "SEPTEMBER": VolumeBackupScheduleMonthSeptember, + "OCTOBER": VolumeBackupScheduleMonthOctober, + "NOVEMBER": VolumeBackupScheduleMonthNovember, + "DECEMBER": VolumeBackupScheduleMonthDecember, +} + +// GetVolumeBackupScheduleMonthEnumValues Enumerates the set of values for VolumeBackupScheduleMonthEnum +func GetVolumeBackupScheduleMonthEnumValues() []VolumeBackupScheduleMonthEnum { + values := make([]VolumeBackupScheduleMonthEnum, 0) + for _, v := range mappingVolumeBackupScheduleMonth { + values = append(values, v) + } + return values +} + +// VolumeBackupScheduleTimeZoneEnum Enum with underlying type: string +type VolumeBackupScheduleTimeZoneEnum string + +// Set of constants representing the allowable values for VolumeBackupScheduleTimeZoneEnum +const ( + VolumeBackupScheduleTimeZoneUtc VolumeBackupScheduleTimeZoneEnum = "UTC" + VolumeBackupScheduleTimeZoneRegionalDataCenterTime VolumeBackupScheduleTimeZoneEnum = "REGIONAL_DATA_CENTER_TIME" +) + +var mappingVolumeBackupScheduleTimeZone = map[string]VolumeBackupScheduleTimeZoneEnum{ + "UTC": VolumeBackupScheduleTimeZoneUtc, + "REGIONAL_DATA_CENTER_TIME": VolumeBackupScheduleTimeZoneRegionalDataCenterTime, +} + +// GetVolumeBackupScheduleTimeZoneEnumValues Enumerates the set of values for VolumeBackupScheduleTimeZoneEnum +func GetVolumeBackupScheduleTimeZoneEnumValues() []VolumeBackupScheduleTimeZoneEnum { + values := make([]VolumeBackupScheduleTimeZoneEnum, 0) + for _, v := range mappingVolumeBackupScheduleTimeZone { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group.go new file mode 100644 index 000000000..b9e6abbb2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group.go @@ -0,0 +1,166 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeGroup Specifies a volume group which is a collection of +// volumes. For more information, see Volume Groups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/volumegroups.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you +// supply string values using the API. +type VolumeGroup struct { + + // The availability domain of the volume group. + AvailabilityDomain *string `mandatory:"true" json:"availabilityDomain"` + + // The OCID of the compartment that contains the volume group. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The OCID for the volume group. + Id *string `mandatory:"true" json:"id"` + + // The current state of a volume group. + LifecycleState VolumeGroupLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The aggregate size of the volume group in MBs. + SizeInMBs *int64 `mandatory:"true" json:"sizeInMBs"` + + // The date and time the volume group was created. Format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // OCIDs for the volumes in this volume group. + VolumeIds []string `mandatory:"true" json:"volumeIds"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The aggregate size of the volume group in GBs. + SizeInGBs *int64 `mandatory:"false" json:"sizeInGBs"` + + SourceDetails VolumeGroupSourceDetails `mandatory:"false" json:"sourceDetails"` + + // Specifies whether the newly created cloned volume group's data has finished copying + // from the source volume group or backup. + IsHydrated *bool `mandatory:"false" json:"isHydrated"` +} + +func (m VolumeGroup) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *VolumeGroup) UnmarshalJSON(data []byte) (e error) { + model := struct { + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + FreeformTags map[string]string `json:"freeformTags"` + SizeInGBs *int64 `json:"sizeInGBs"` + SourceDetails volumegroupsourcedetails `json:"sourceDetails"` + IsHydrated *bool `json:"isHydrated"` + AvailabilityDomain *string `json:"availabilityDomain"` + CompartmentId *string `json:"compartmentId"` + DisplayName *string `json:"displayName"` + Id *string `json:"id"` + LifecycleState VolumeGroupLifecycleStateEnum `json:"lifecycleState"` + SizeInMBs *int64 `json:"sizeInMBs"` + TimeCreated *common.SDKTime `json:"timeCreated"` + VolumeIds []string `json:"volumeIds"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.DefinedTags = model.DefinedTags + + m.FreeformTags = model.FreeformTags + + m.SizeInGBs = model.SizeInGBs + + nn, e = model.SourceDetails.UnmarshalPolymorphicJSON(model.SourceDetails.JsonData) + if e != nil { + return + } + if nn != nil { + m.SourceDetails = nn.(VolumeGroupSourceDetails) + } else { + m.SourceDetails = nil + } + + m.IsHydrated = model.IsHydrated + + m.AvailabilityDomain = model.AvailabilityDomain + + m.CompartmentId = model.CompartmentId + + m.DisplayName = model.DisplayName + + m.Id = model.Id + + m.LifecycleState = model.LifecycleState + + m.SizeInMBs = model.SizeInMBs + + m.TimeCreated = model.TimeCreated + + m.VolumeIds = make([]string, len(model.VolumeIds)) + for i, n := range model.VolumeIds { + m.VolumeIds[i] = n + } + + return +} + +// VolumeGroupLifecycleStateEnum Enum with underlying type: string +type VolumeGroupLifecycleStateEnum string + +// Set of constants representing the allowable values for VolumeGroupLifecycleStateEnum +const ( + VolumeGroupLifecycleStateProvisioning VolumeGroupLifecycleStateEnum = "PROVISIONING" + VolumeGroupLifecycleStateAvailable VolumeGroupLifecycleStateEnum = "AVAILABLE" + VolumeGroupLifecycleStateTerminating VolumeGroupLifecycleStateEnum = "TERMINATING" + VolumeGroupLifecycleStateTerminated VolumeGroupLifecycleStateEnum = "TERMINATED" + VolumeGroupLifecycleStateFaulty VolumeGroupLifecycleStateEnum = "FAULTY" +) + +var mappingVolumeGroupLifecycleState = map[string]VolumeGroupLifecycleStateEnum{ + "PROVISIONING": VolumeGroupLifecycleStateProvisioning, + "AVAILABLE": VolumeGroupLifecycleStateAvailable, + "TERMINATING": VolumeGroupLifecycleStateTerminating, + "TERMINATED": VolumeGroupLifecycleStateTerminated, + "FAULTY": VolumeGroupLifecycleStateFaulty, +} + +// GetVolumeGroupLifecycleStateEnumValues Enumerates the set of values for VolumeGroupLifecycleStateEnum +func GetVolumeGroupLifecycleStateEnumValues() []VolumeGroupLifecycleStateEnum { + values := make([]VolumeGroupLifecycleStateEnum, 0) + for _, v := range mappingVolumeGroupLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_backup.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_backup.go new file mode 100644 index 000000000..d898ce044 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_backup.go @@ -0,0 +1,180 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeGroupBackup A point-in-time copy of a volume group that can then be used to create a new volume group +// or restore a volume group. For more information, see Volume Groups (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/volumegroups.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/policygetstarted.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you +// supply string values using the API. +type VolumeGroupBackup struct { + + // The OCID of the compartment that contains the volume group backup. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // A user-friendly name. Does not have to be unique, and it's changeable. + // Avoid entering confidential information. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The OCID of the volume group backup. + Id *string `mandatory:"true" json:"id"` + + // The current state of a volume group backup. + LifecycleState VolumeGroupBackupLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The date and time the volume group backup was created. This is the time the actual point-in-time image + // of the volume group data was taken. Format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The type of backup. + Type VolumeGroupBackupTypeEnum `mandatory:"true" json:"type"` + + // OCIDs for the volume backups in this volume group backup. + VolumeBackupIds []string `mandatory:"true" json:"volumeBackupIds"` + + // Defined tags for this resource. Each key is predefined and scoped to a + // namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // The date and time the volume group backup will expire and be automatically deleted. + // Format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). This parameter will always be present for volume group + // backups that were created automatically by a scheduled-backup policy. For manually + // created volume group backups, it will be absent, signifying that there is no expiration + // time and the backup will last forever until manually deleted. + ExpirationTime *common.SDKTime `mandatory:"false" json:"expirationTime"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no + // predefined name, type, or namespace. For more information, see Resource Tags (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // The aggregate size of the volume group backup, in MBs. + SizeInMBs *int64 `mandatory:"false" json:"sizeInMBs"` + + // The aggregate size of the volume group backup, in GBs. + SizeInGBs *int64 `mandatory:"false" json:"sizeInGBs"` + + // Specifies whether the volume group backup was created manually, or via scheduled + // backup policy. + SourceType VolumeGroupBackupSourceTypeEnum `mandatory:"false" json:"sourceType,omitempty"` + + // The date and time the request to create the volume group backup was received. Format defined by RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeRequestReceived *common.SDKTime `mandatory:"false" json:"timeRequestReceived"` + + // The aggregate size used by the volume group backup, in MBs. + // It is typically smaller than sizeInMBs, depending on the spaceconsumed + // on the volume group and whether the volume backup is full or incremental. + UniqueSizeInMbs *int64 `mandatory:"false" json:"uniqueSizeInMbs"` + + // The aggregate size used by the volume group backup, in GBs. + // It is typically smaller than sizeInGBs, depending on the spaceconsumed + // on the volume group and whether the volume backup is full or incremental. + UniqueSizeInGbs *int64 `mandatory:"false" json:"uniqueSizeInGbs"` + + // The OCID of the source volume group. + VolumeGroupId *string `mandatory:"false" json:"volumeGroupId"` + + // The OCID of the source volume group backup. + SourceVolumeGroupBackupId *string `mandatory:"false" json:"sourceVolumeGroupBackupId"` +} + +func (m VolumeGroupBackup) String() string { + return common.PointerString(m) +} + +// VolumeGroupBackupLifecycleStateEnum Enum with underlying type: string +type VolumeGroupBackupLifecycleStateEnum string + +// Set of constants representing the allowable values for VolumeGroupBackupLifecycleStateEnum +const ( + VolumeGroupBackupLifecycleStateCreating VolumeGroupBackupLifecycleStateEnum = "CREATING" + VolumeGroupBackupLifecycleStateCommitted VolumeGroupBackupLifecycleStateEnum = "COMMITTED" + VolumeGroupBackupLifecycleStateAvailable VolumeGroupBackupLifecycleStateEnum = "AVAILABLE" + VolumeGroupBackupLifecycleStateTerminating VolumeGroupBackupLifecycleStateEnum = "TERMINATING" + VolumeGroupBackupLifecycleStateTerminated VolumeGroupBackupLifecycleStateEnum = "TERMINATED" + VolumeGroupBackupLifecycleStateFaulty VolumeGroupBackupLifecycleStateEnum = "FAULTY" + VolumeGroupBackupLifecycleStateRequestReceived VolumeGroupBackupLifecycleStateEnum = "REQUEST_RECEIVED" +) + +var mappingVolumeGroupBackupLifecycleState = map[string]VolumeGroupBackupLifecycleStateEnum{ + "CREATING": VolumeGroupBackupLifecycleStateCreating, + "COMMITTED": VolumeGroupBackupLifecycleStateCommitted, + "AVAILABLE": VolumeGroupBackupLifecycleStateAvailable, + "TERMINATING": VolumeGroupBackupLifecycleStateTerminating, + "TERMINATED": VolumeGroupBackupLifecycleStateTerminated, + "FAULTY": VolumeGroupBackupLifecycleStateFaulty, + "REQUEST_RECEIVED": VolumeGroupBackupLifecycleStateRequestReceived, +} + +// GetVolumeGroupBackupLifecycleStateEnumValues Enumerates the set of values for VolumeGroupBackupLifecycleStateEnum +func GetVolumeGroupBackupLifecycleStateEnumValues() []VolumeGroupBackupLifecycleStateEnum { + values := make([]VolumeGroupBackupLifecycleStateEnum, 0) + for _, v := range mappingVolumeGroupBackupLifecycleState { + values = append(values, v) + } + return values +} + +// VolumeGroupBackupSourceTypeEnum Enum with underlying type: string +type VolumeGroupBackupSourceTypeEnum string + +// Set of constants representing the allowable values for VolumeGroupBackupSourceTypeEnum +const ( + VolumeGroupBackupSourceTypeManual VolumeGroupBackupSourceTypeEnum = "MANUAL" + VolumeGroupBackupSourceTypeScheduled VolumeGroupBackupSourceTypeEnum = "SCHEDULED" +) + +var mappingVolumeGroupBackupSourceType = map[string]VolumeGroupBackupSourceTypeEnum{ + "MANUAL": VolumeGroupBackupSourceTypeManual, + "SCHEDULED": VolumeGroupBackupSourceTypeScheduled, +} + +// GetVolumeGroupBackupSourceTypeEnumValues Enumerates the set of values for VolumeGroupBackupSourceTypeEnum +func GetVolumeGroupBackupSourceTypeEnumValues() []VolumeGroupBackupSourceTypeEnum { + values := make([]VolumeGroupBackupSourceTypeEnum, 0) + for _, v := range mappingVolumeGroupBackupSourceType { + values = append(values, v) + } + return values +} + +// VolumeGroupBackupTypeEnum Enum with underlying type: string +type VolumeGroupBackupTypeEnum string + +// Set of constants representing the allowable values for VolumeGroupBackupTypeEnum +const ( + VolumeGroupBackupTypeFull VolumeGroupBackupTypeEnum = "FULL" + VolumeGroupBackupTypeIncremental VolumeGroupBackupTypeEnum = "INCREMENTAL" +) + +var mappingVolumeGroupBackupType = map[string]VolumeGroupBackupTypeEnum{ + "FULL": VolumeGroupBackupTypeFull, + "INCREMENTAL": VolumeGroupBackupTypeIncremental, +} + +// GetVolumeGroupBackupTypeEnumValues Enumerates the set of values for VolumeGroupBackupTypeEnum +func GetVolumeGroupBackupTypeEnumValues() []VolumeGroupBackupTypeEnum { + values := make([]VolumeGroupBackupTypeEnum, 0) + for _, v := range mappingVolumeGroupBackupType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_details.go new file mode 100644 index 000000000..f22d0df4b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_details.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeGroupSourceDetails Specifies the source for a volume group. +type VolumeGroupSourceDetails interface { +} + +type volumegroupsourcedetails struct { + JsonData []byte + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *volumegroupsourcedetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalervolumegroupsourcedetails volumegroupsourcedetails + s := struct { + Model Unmarshalervolumegroupsourcedetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *volumegroupsourcedetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "volumeGroupId": + mm := VolumeGroupSourceFromVolumeGroupDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "volumeIds": + mm := VolumeGroupSourceFromVolumesDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "volumeGroupBackupId": + mm := VolumeGroupSourceFromVolumeGroupBackupDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +func (m volumegroupsourcedetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_from_volume_group_backup_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_from_volume_group_backup_details.go new file mode 100644 index 000000000..ab489b895 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_from_volume_group_backup_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeGroupSourceFromVolumeGroupBackupDetails Specifies the volume group backup to restore from. +type VolumeGroupSourceFromVolumeGroupBackupDetails struct { + + // The OCID of the volume group backup to restore from. + VolumeGroupBackupId *string `mandatory:"true" json:"volumeGroupBackupId"` +} + +func (m VolumeGroupSourceFromVolumeGroupBackupDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m VolumeGroupSourceFromVolumeGroupBackupDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeVolumeGroupSourceFromVolumeGroupBackupDetails VolumeGroupSourceFromVolumeGroupBackupDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeVolumeGroupSourceFromVolumeGroupBackupDetails + }{ + "volumeGroupBackupId", + (MarshalTypeVolumeGroupSourceFromVolumeGroupBackupDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_from_volume_group_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_from_volume_group_details.go new file mode 100644 index 000000000..9fb0c21a4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_from_volume_group_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeGroupSourceFromVolumeGroupDetails Specifies the volume group to clone from. +type VolumeGroupSourceFromVolumeGroupDetails struct { + + // The OCID of the volume group to clone from. + VolumeGroupId *string `mandatory:"true" json:"volumeGroupId"` +} + +func (m VolumeGroupSourceFromVolumeGroupDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m VolumeGroupSourceFromVolumeGroupDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeVolumeGroupSourceFromVolumeGroupDetails VolumeGroupSourceFromVolumeGroupDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeVolumeGroupSourceFromVolumeGroupDetails + }{ + "volumeGroupId", + (MarshalTypeVolumeGroupSourceFromVolumeGroupDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_from_volumes_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_from_volumes_details.go new file mode 100644 index 000000000..44573b79d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_group_source_from_volumes_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeGroupSourceFromVolumesDetails Specifies the volumes in a volume group. +type VolumeGroupSourceFromVolumesDetails struct { + + // OCIDs for the volumes in this volume group. + VolumeIds []string `mandatory:"true" json:"volumeIds"` +} + +func (m VolumeGroupSourceFromVolumesDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m VolumeGroupSourceFromVolumesDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeVolumeGroupSourceFromVolumesDetails VolumeGroupSourceFromVolumesDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeVolumeGroupSourceFromVolumesDetails + }{ + "volumeIds", + (MarshalTypeVolumeGroupSourceFromVolumesDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_kms_key.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_kms_key.go new file mode 100644 index 000000000..cb787741d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_kms_key.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeKmsKey The Key Management master encryption key associated with this volume. +type VolumeKmsKey struct { + + // The OCID of the Key Management key assigned to this volume. If the volume is not using Key Management, then the `kmsKeyId` will be a null string. + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` +} + +func (m VolumeKmsKey) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_details.go new file mode 100644 index 000000000..278e77f49 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_details.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeSourceDetails Specifies the volume source details for a new Block volume. The volume source is either another Block volume in the same Availability Domain or a Block volume backup. +// This is an optional field. If not specified or set to null, the new Block volume will be empty. +// When specified, the new Block volume will contain data from the source volume or backup. +type VolumeSourceDetails interface { +} + +type volumesourcedetails struct { + JsonData []byte + Type string `json:"type"` +} + +// UnmarshalJSON unmarshals json +func (m *volumesourcedetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalervolumesourcedetails volumesourcedetails + s := struct { + Model Unmarshalervolumesourcedetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.Type = s.Model.Type + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *volumesourcedetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Type { + case "blockVolumeReplica": + mm := VolumeSourceFromBlockVolumeReplicaDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "volume": + mm := VolumeSourceFromVolumeDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + case "volumeBackup": + mm := VolumeSourceFromVolumeBackupDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +func (m volumesourcedetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_from_block_volume_replica_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_from_block_volume_replica_details.go new file mode 100644 index 000000000..fa120edcc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_from_block_volume_replica_details.go @@ -0,0 +1,46 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeSourceFromBlockVolumeReplicaDetails Specifies the source block volume replica which the block volume will be created from. +// The block volume replica shoulbe be in the same availability domain as the block volume. +// Only one volume can be created from a replica at the same time. +type VolumeSourceFromBlockVolumeReplicaDetails struct { + + // The OCID of the block volume replica. + Id *string `mandatory:"true" json:"id"` +} + +func (m VolumeSourceFromBlockVolumeReplicaDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m VolumeSourceFromBlockVolumeReplicaDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeVolumeSourceFromBlockVolumeReplicaDetails VolumeSourceFromBlockVolumeReplicaDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeVolumeSourceFromBlockVolumeReplicaDetails + }{ + "blockVolumeReplica", + (MarshalTypeVolumeSourceFromBlockVolumeReplicaDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_from_volume_backup_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_from_volume_backup_details.go new file mode 100644 index 000000000..c5d4c6f81 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_from_volume_backup_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeSourceFromVolumeBackupDetails Specifies the volume backup. +type VolumeSourceFromVolumeBackupDetails struct { + + // The OCID of the volume backup. + Id *string `mandatory:"true" json:"id"` +} + +func (m VolumeSourceFromVolumeBackupDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m VolumeSourceFromVolumeBackupDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeVolumeSourceFromVolumeBackupDetails VolumeSourceFromVolumeBackupDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeVolumeSourceFromVolumeBackupDetails + }{ + "volumeBackup", + (MarshalTypeVolumeSourceFromVolumeBackupDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_from_volume_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_from_volume_details.go new file mode 100644 index 000000000..a4b05636d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/volume_source_from_volume_details.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Core Services API +// +// Use the Core Services API to manage resources such as virtual cloud networks (VCNs), +// compute instances, and block storage volumes. For more information, see the console +// documentation for the Networking (https://docs.cloud.oracle.com/iaas/Content/Network/Concepts/overview.htm), +// Compute (https://docs.cloud.oracle.com/iaas/Content/Compute/Concepts/computeoverview.htm), and +// Block Volume (https://docs.cloud.oracle.com/iaas/Content/Block/Concepts/overview.htm) services. +// + +package core + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// VolumeSourceFromVolumeDetails Specifies the source volume. +type VolumeSourceFromVolumeDetails struct { + + // The OCID of the volume. + Id *string `mandatory:"true" json:"id"` +} + +func (m VolumeSourceFromVolumeDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m VolumeSourceFromVolumeDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeVolumeSourceFromVolumeDetails VolumeSourceFromVolumeDetails + s := struct { + DiscriminatorParam string `json:"type"` + MarshalTypeVolumeSourceFromVolumeDetails + }{ + "volume", + (MarshalTypeVolumeSourceFromVolumeDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/core/withdraw_byoip_range_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/core/withdraw_byoip_range_request_response.go new file mode 100644 index 000000000..711ada085 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/core/withdraw_byoip_range_request_response.go @@ -0,0 +1,71 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package core + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// WithdrawByoipRangeRequest wrapper for the WithdrawByoipRange operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/core/WithdrawByoipRange.go.html to see an example of how to use WithdrawByoipRangeRequest. +type WithdrawByoipRangeRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the `ByoipRange` resource containing the BYOIP CIDR block. + ByoipRangeId *string `mandatory:"true" contributesTo:"path" name:"byoipRangeId"` + + // Unique identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request WithdrawByoipRangeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request WithdrawByoipRangeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request WithdrawByoipRangeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request WithdrawByoipRangeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// WithdrawByoipRangeResponse wrapper for the WithdrawByoipRange operation +type WithdrawByoipRangeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact + // Oracle about a particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response WithdrawByoipRangeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response WithdrawByoipRangeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/activate_domain_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/activate_domain_request_response.go new file mode 100644 index 000000000..a16216807 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/activate_domain_request_response.go @@ -0,0 +1,86 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ActivateDomainRequest wrapper for the ActivateDomain operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ActivateDomain.go.html to see an example of how to use ActivateDomainRequest. +type ActivateDomainRequest struct { + + // The OCID of the domain + DomainId *string `mandatory:"true" contributesTo:"path" name:"domainId"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ActivateDomainRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ActivateDomainRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ActivateDomainRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ActivateDomainRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ActivateDomainResponse wrapper for the ActivateDomain operation +type ActivateDomainResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response ActivateDomainResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ActivateDomainResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/activate_mfa_totp_device_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/activate_mfa_totp_device_request_response.go new file mode 100644 index 000000000..d57e2a4f0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/activate_mfa_totp_device_request_response.go @@ -0,0 +1,95 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ActivateMfaTotpDeviceRequest wrapper for the ActivateMfaTotpDevice operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ActivateMfaTotpDevice.go.html to see an example of how to use ActivateMfaTotpDeviceRequest. +type ActivateMfaTotpDeviceRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The OCID of the MFA TOTP device. + MfaTotpDeviceId *string `mandatory:"true" contributesTo:"path" name:"mfaTotpDeviceId"` + + // MFA TOTP token + MfaTotpToken `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ActivateMfaTotpDeviceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ActivateMfaTotpDeviceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ActivateMfaTotpDeviceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ActivateMfaTotpDeviceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ActivateMfaTotpDeviceResponse wrapper for the ActivateMfaTotpDevice operation +type ActivateMfaTotpDeviceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The MfaTotpDeviceSummary instance + MfaTotpDeviceSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response ActivateMfaTotpDeviceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ActivateMfaTotpDeviceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/add_user_to_group_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/add_user_to_group_details.go new file mode 100644 index 000000000..b184ce5b4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/add_user_to_group_details.go @@ -0,0 +1,28 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AddUserToGroupDetails The representation of AddUserToGroupDetails +type AddUserToGroupDetails struct { + + // The OCID of the user. + UserId *string `mandatory:"true" json:"userId"` + + // The OCID of the group. + GroupId *string `mandatory:"true" json:"groupId"` +} + +func (m AddUserToGroupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/add_user_to_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/add_user_to_group_request_response.go new file mode 100644 index 000000000..7b7b1b709 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/add_user_to_group_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AddUserToGroupRequest wrapper for the AddUserToGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/AddUserToGroup.go.html to see an example of how to use AddUserToGroupRequest. +type AddUserToGroupRequest struct { + + // Request object for adding a user to a group. + AddUserToGroupDetails `contributesTo:"body"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AddUserToGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AddUserToGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AddUserToGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AddUserToGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AddUserToGroupResponse wrapper for the AddUserToGroup operation +type AddUserToGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The UserGroupMembership instance + UserGroupMembership `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response AddUserToGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AddUserToGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/allowed_domain_license_type_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/allowed_domain_license_type_summary.go new file mode 100644 index 000000000..d318113b6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/allowed_domain_license_type_summary.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AllowedDomainLicenseTypeSummary The 'AllowedDomainLicenseTypeSummary' object contains information about the 'Domain License type'. +type AllowedDomainLicenseTypeSummary struct { + + // The license type name. + // Example: "Oracle Apps Premium" + Name *string `mandatory:"true" json:"name"` + + // The license type identifier. + // Example: "oracle-apps-premium" + LicenseType *string `mandatory:"true" json:"licenseType"` + + // The license type description. + Description *string `mandatory:"true" json:"description"` +} + +func (m AllowedDomainLicenseTypeSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/api_key.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/api_key.go new file mode 100644 index 000000000..59772420e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/api_key.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ApiKey A PEM-format RSA credential for securing requests to the Oracle Cloud Infrastructure REST API. Also known +// as an *API signing key*. Specifically, this is the public key from the key pair. The private key remains with +// the user calling the API. For information about generating a key pair +// in the required PEM format, see Required Keys and OCIDs (https://docs.cloud.oracle.com/Content/API/Concepts/apisigningkey.htm). +// **Important:** This is **not** the SSH key for accessing compute instances. +// Each user can have a maximum of three API signing keys. +// For more information about user credentials, see User Credentials (https://docs.cloud.oracle.com/Content/Identity/Concepts/usercredentials.htm). +type ApiKey struct { + + // An Oracle-assigned identifier for the key, in this format: + // TENANCY_OCID/USER_OCID/KEY_FINGERPRINT. + KeyId *string `mandatory:"false" json:"keyId"` + + // The key's value. + KeyValue *string `mandatory:"false" json:"keyValue"` + + // The key's fingerprint (e.g., 12:34:56:78:90:ab:cd:ef:12:34:56:78:90:ab:cd:ef). + Fingerprint *string `mandatory:"false" json:"fingerprint"` + + // The OCID of the user the key belongs to. + UserId *string `mandatory:"false" json:"userId"` + + // Date and time the `ApiKey` object was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // The API key's current state. After creating an `ApiKey` object, make sure its `lifecycleState` changes from + // CREATING to ACTIVE before using it. + LifecycleState ApiKeyLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` +} + +func (m ApiKey) String() string { + return common.PointerString(m) +} + +// ApiKeyLifecycleStateEnum Enum with underlying type: string +type ApiKeyLifecycleStateEnum string + +// Set of constants representing the allowable values for ApiKeyLifecycleStateEnum +const ( + ApiKeyLifecycleStateCreating ApiKeyLifecycleStateEnum = "CREATING" + ApiKeyLifecycleStateActive ApiKeyLifecycleStateEnum = "ACTIVE" + ApiKeyLifecycleStateInactive ApiKeyLifecycleStateEnum = "INACTIVE" + ApiKeyLifecycleStateDeleting ApiKeyLifecycleStateEnum = "DELETING" + ApiKeyLifecycleStateDeleted ApiKeyLifecycleStateEnum = "DELETED" +) + +var mappingApiKeyLifecycleState = map[string]ApiKeyLifecycleStateEnum{ + "CREATING": ApiKeyLifecycleStateCreating, + "ACTIVE": ApiKeyLifecycleStateActive, + "INACTIVE": ApiKeyLifecycleStateInactive, + "DELETING": ApiKeyLifecycleStateDeleting, + "DELETED": ApiKeyLifecycleStateDeleted, +} + +// GetApiKeyLifecycleStateEnumValues Enumerates the set of values for ApiKeyLifecycleStateEnum +func GetApiKeyLifecycleStateEnumValues() []ApiKeyLifecycleStateEnum { + values := make([]ApiKeyLifecycleStateEnum, 0) + for _, v := range mappingApiKeyLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/assemble_effective_tag_set_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/assemble_effective_tag_set_request_response.go new file mode 100644 index 000000000..bd9202137 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/assemble_effective_tag_set_request_response.go @@ -0,0 +1,82 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AssembleEffectiveTagSetRequest wrapper for the AssembleEffectiveTagSet operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/AssembleEffectiveTagSet.go.html to see an example of how to use AssembleEffectiveTagSetRequest. +type AssembleEffectiveTagSetRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState TagDefaultSummaryLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AssembleEffectiveTagSetRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AssembleEffectiveTagSetRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AssembleEffectiveTagSetRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AssembleEffectiveTagSetRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AssembleEffectiveTagSetResponse wrapper for the AssembleEffectiveTagSet operation +type AssembleEffectiveTagSetResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []TagDefaultSummary instance + Items []TagDefaultSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of tag default values. When paging through a list, if this header appears in + // the response, then a partial list might have been returned. Include this value as the `page` parameter + // for the subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response AssembleEffectiveTagSetResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AssembleEffectiveTagSetResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/auth_token.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/auth_token.go new file mode 100644 index 000000000..60d556d0d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/auth_token.go @@ -0,0 +1,86 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AuthToken An `AuthToken` is an Oracle-generated token string that you can use to authenticate with third-party APIs +// that do not support Oracle Cloud Infrastructure's signature-based authentication. For example, use an `AuthToken` +// to authenticate with a Swift client with the Object Storage Service. +// The auth token is associated with the user's Console login. Auth tokens never expire. A user can have up to two +// auth tokens at a time. +// **Note:** The token is always an Oracle-generated string; you can't change it to a string of your choice. +// For more information, see Managing User Credentials (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingcredentials.htm). +type AuthToken struct { + + // The auth token. The value is available only in the response for `CreateAuthToken`, and not + // for `ListAuthTokens` or `UpdateAuthToken`. + Token *string `mandatory:"false" json:"token"` + + // The OCID of the auth token. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the user the auth token belongs to. + UserId *string `mandatory:"false" json:"userId"` + + // The description you assign to the auth token. Does not have to be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` + + // Date and time the `AuthToken` object was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // Date and time when this auth token will expire, in the format defined by RFC3339. + // Null if it never expires. + // Example: `2016-08-25T21:10:29.600Z` + TimeExpires *common.SDKTime `mandatory:"false" json:"timeExpires"` + + // The token's current state. After creating an auth token, make sure its `lifecycleState` changes from + // CREATING to ACTIVE before using it. + LifecycleState AuthTokenLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` +} + +func (m AuthToken) String() string { + return common.PointerString(m) +} + +// AuthTokenLifecycleStateEnum Enum with underlying type: string +type AuthTokenLifecycleStateEnum string + +// Set of constants representing the allowable values for AuthTokenLifecycleStateEnum +const ( + AuthTokenLifecycleStateCreating AuthTokenLifecycleStateEnum = "CREATING" + AuthTokenLifecycleStateActive AuthTokenLifecycleStateEnum = "ACTIVE" + AuthTokenLifecycleStateInactive AuthTokenLifecycleStateEnum = "INACTIVE" + AuthTokenLifecycleStateDeleting AuthTokenLifecycleStateEnum = "DELETING" + AuthTokenLifecycleStateDeleted AuthTokenLifecycleStateEnum = "DELETED" +) + +var mappingAuthTokenLifecycleState = map[string]AuthTokenLifecycleStateEnum{ + "CREATING": AuthTokenLifecycleStateCreating, + "ACTIVE": AuthTokenLifecycleStateActive, + "INACTIVE": AuthTokenLifecycleStateInactive, + "DELETING": AuthTokenLifecycleStateDeleting, + "DELETED": AuthTokenLifecycleStateDeleted, +} + +// GetAuthTokenLifecycleStateEnumValues Enumerates the set of values for AuthTokenLifecycleStateEnum +func GetAuthTokenLifecycleStateEnumValues() []AuthTokenLifecycleStateEnum { + values := make([]AuthTokenLifecycleStateEnum, 0) + for _, v := range mappingAuthTokenLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/authentication_policy.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/authentication_policy.go new file mode 100644 index 000000000..62fcc97b5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/authentication_policy.go @@ -0,0 +1,28 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AuthenticationPolicy Authentication policy, currently set for the given compartment +type AuthenticationPolicy struct { + PasswordPolicy *PasswordPolicy `mandatory:"false" json:"passwordPolicy"` + + // Compartment OCID. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + NetworkPolicy *NetworkPolicy `mandatory:"false" json:"networkPolicy"` +} + +func (m AuthenticationPolicy) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/availability_domain.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/availability_domain.go new file mode 100644 index 000000000..f05a632ff --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/availability_domain.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// AvailabilityDomain One or more isolated, fault-tolerant Oracle data centers that host cloud resources such as instances, volumes, +// and subnets. A region contains several Availability Domains. For more information, see +// Regions and Availability Domains (https://docs.cloud.oracle.com/Content/General/Concepts/regions.htm). +type AvailabilityDomain struct { + + // The name of the Availability Domain. + Name *string `mandatory:"false" json:"name"` + + // The OCID of the Availability Domain. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the tenancy. + CompartmentId *string `mandatory:"false" json:"compartmentId"` +} + +func (m AvailabilityDomain) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/base_tag_definition_validator.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/base_tag_definition_validator.go new file mode 100644 index 000000000..7972ad693 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/base_tag_definition_validator.go @@ -0,0 +1,97 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BaseTagDefinitionValidator Validates a definedTag value. Each validator performs validation steps in addition to the standard +// validation for definedTag values. For more information, see +// Limits on Tags (https://docs.cloud.oracle.com/Content/Identity/Concepts/taggingoverview.htm#Limits). +// If you define a validator after a value has been set for a defined tag, then any updates that +// attempt to change the value must pass the additional validation defined by the current rule. +// Previously set values (even those that would fail the current validation) are not updated. You can +// still update other attributes to resources that contain a non-valid defined tag. +// To clear the validator call UpdateTag with +// DefaultTagDefinitionValidator (https://docs.cloud.oracle.com/api/#/en/identity/latest/datatypes/DefaultTagDefinitionValidator). +type BaseTagDefinitionValidator interface { +} + +type basetagdefinitionvalidator struct { + JsonData []byte + ValidatorType string `json:"validatorType"` +} + +// UnmarshalJSON unmarshals json +func (m *basetagdefinitionvalidator) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerbasetagdefinitionvalidator basetagdefinitionvalidator + s := struct { + Model Unmarshalerbasetagdefinitionvalidator + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.ValidatorType = s.Model.ValidatorType + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *basetagdefinitionvalidator) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.ValidatorType { + case "DEFAULT": + mm := DefaultTagDefinitionValidator{} + err = json.Unmarshal(data, &mm) + return mm, err + case "ENUM": + mm := EnumTagDefinitionValidator{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +func (m basetagdefinitionvalidator) String() string { + return common.PointerString(m) +} + +// BaseTagDefinitionValidatorValidatorTypeEnum Enum with underlying type: string +type BaseTagDefinitionValidatorValidatorTypeEnum string + +// Set of constants representing the allowable values for BaseTagDefinitionValidatorValidatorTypeEnum +const ( + BaseTagDefinitionValidatorValidatorTypeEnumvalue BaseTagDefinitionValidatorValidatorTypeEnum = "ENUM" + BaseTagDefinitionValidatorValidatorTypeDefault BaseTagDefinitionValidatorValidatorTypeEnum = "DEFAULT" +) + +var mappingBaseTagDefinitionValidatorValidatorType = map[string]BaseTagDefinitionValidatorValidatorTypeEnum{ + "ENUM": BaseTagDefinitionValidatorValidatorTypeEnumvalue, + "DEFAULT": BaseTagDefinitionValidatorValidatorTypeDefault, +} + +// GetBaseTagDefinitionValidatorValidatorTypeEnumValues Enumerates the set of values for BaseTagDefinitionValidatorValidatorTypeEnum +func GetBaseTagDefinitionValidatorValidatorTypeEnumValues() []BaseTagDefinitionValidatorValidatorTypeEnum { + values := make([]BaseTagDefinitionValidatorValidatorTypeEnum, 0) + for _, v := range mappingBaseTagDefinitionValidatorValidatorType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_action_resource.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_action_resource.go new file mode 100644 index 000000000..4f764f508 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_action_resource.go @@ -0,0 +1,52 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BulkActionResource The bulk action resource entity. +type BulkActionResource struct { + + // The resource OCID. + Identifier *string `mandatory:"true" json:"identifier"` + + // The resource-type. To get the list of supported resource-types use + // ListBulkActionResourceTypes. + EntityType *string `mandatory:"true" json:"entityType"` + + // Additional information that helps to identity the resource for bulk action. + // The APIs to delete and move most resource types only require the resource identifier (ocid). + // But some resource-types require additional identifying information. + // This information is provided in the resource's public API document. It is also + // available through the + // ListBulkActionResourceTypes. + // **Example**: + // The APIs to delete or move the `buckets` resource-type require `namespaceName` and `bucketName` to identify the resource, as + // shown in the APIs, DeleteBucket and + // UpdateBucket. + // To add a bucket for bulk actions, specify `namespaceName` and `bucketName` in + // the metadata property as shown in this example + // { + // "identifier": "" + // "entityType": "bucket", + // "metadata": + // { + // "namespaceName": "sampleNamespace", + // "bucketName": "sampleBucket" + // } + // } + Metadata map[string]string `mandatory:"false" json:"metadata"` +} + +func (m BulkActionResource) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_action_resource_type.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_action_resource_type.go new file mode 100644 index 000000000..00ae4812b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_action_resource_type.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BulkActionResourceType The representation of BulkActionResourceType +type BulkActionResourceType struct { + + // The unique name of the resource-type. + Name *string `mandatory:"true" json:"name"` + + // List of metadata keys required to identify a specific resource. Some resource-types require information besides an OCID to identify + // a specific resource. For example, the resource-type `buckets` requires metadataKeys DeleteBucket. + MetadataKeys []string `mandatory:"false" json:"metadataKeys"` +} + +func (m BulkActionResourceType) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_action_resource_type_collection.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_action_resource_type_collection.go new file mode 100644 index 000000000..7d987f57b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_action_resource_type_collection.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BulkActionResourceTypeCollection Collection of resource-types supported by a compartment bulk action. +type BulkActionResourceTypeCollection struct { + + // Collection of the resource-types supported by a compartment bulk action. + Items []BulkActionResourceType `mandatory:"true" json:"items"` +} + +func (m BulkActionResourceTypeCollection) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_resources_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_resources_details.go new file mode 100644 index 000000000..dbe7b98b8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_resources_details.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BulkDeleteResourcesDetails The representation of BulkDeleteResourcesDetails +type BulkDeleteResourcesDetails struct { + + // The resources to be deleted. + Resources []BulkActionResource `mandatory:"true" json:"resources"` +} + +func (m BulkDeleteResourcesDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_resources_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_resources_request_response.go new file mode 100644 index 000000000..de7fca414 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_resources_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// BulkDeleteResourcesRequest wrapper for the BulkDeleteResources operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/BulkDeleteResources.go.html to see an example of how to use BulkDeleteResourcesRequest. +type BulkDeleteResourcesRequest struct { + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"path" name:"compartmentId"` + + // Request object for bulk delete resources in a compartment. + BulkDeleteResourcesDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request BulkDeleteResourcesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request BulkDeleteResourcesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request BulkDeleteResourcesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request BulkDeleteResourcesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// BulkDeleteResourcesResponse wrapper for the BulkDeleteResources operation +type BulkDeleteResourcesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response BulkDeleteResourcesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response BulkDeleteResourcesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_tags_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_tags_details.go new file mode 100644 index 000000000..515a946cf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_tags_details.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BulkDeleteTagsDetails Properties for deleting tags in bulk +type BulkDeleteTagsDetails struct { + + // The OCIDs of the tag definitions to delete + TagDefinitionIds []string `mandatory:"true" json:"tagDefinitionIds"` +} + +func (m BulkDeleteTagsDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_tags_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_tags_request_response.go new file mode 100644 index 000000000..6f002dc96 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_delete_tags_request_response.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// BulkDeleteTagsRequest wrapper for the BulkDeleteTags operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/BulkDeleteTags.go.html to see an example of how to use BulkDeleteTagsRequest. +type BulkDeleteTagsRequest struct { + + // Request object for deleting tags in bulk. + BulkDeleteTagsDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request BulkDeleteTagsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request BulkDeleteTagsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request BulkDeleteTagsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request BulkDeleteTagsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// BulkDeleteTagsResponse wrapper for the BulkDeleteTags operation +type BulkDeleteTagsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response BulkDeleteTagsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response BulkDeleteTagsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_operation_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_operation_details.go new file mode 100644 index 000000000..de1f3ea2a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_operation_details.go @@ -0,0 +1,62 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BulkEditOperationDetails The representation of BulkEditOperationDetails +type BulkEditOperationDetails struct { + + // An enum-like description of the type of operation. + // * `ADD_WHERE_ABSENT` adds a defined tag only if the tag does not already exist on the resource. + // * `SET_WHERE_PRESENT` updates the value for a defined tag only if the tag is present on the resource. + // * `ADD_OR_SET` combines the first two operations to add a defined tag if it does not already exist on the resource + // or update the value for a defined tag only if the tag is present on the resource. + // * `REMOVE` removes the defined tag from the resource. The tag is removed from the resource regardless of the tag value. + OperationType BulkEditOperationDetailsOperationTypeEnum `mandatory:"true" json:"operationType"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"true" json:"definedTags"` +} + +func (m BulkEditOperationDetails) String() string { + return common.PointerString(m) +} + +// BulkEditOperationDetailsOperationTypeEnum Enum with underlying type: string +type BulkEditOperationDetailsOperationTypeEnum string + +// Set of constants representing the allowable values for BulkEditOperationDetailsOperationTypeEnum +const ( + BulkEditOperationDetailsOperationTypeAddWhereAbsent BulkEditOperationDetailsOperationTypeEnum = "ADD_WHERE_ABSENT" + BulkEditOperationDetailsOperationTypeSetWherePresent BulkEditOperationDetailsOperationTypeEnum = "SET_WHERE_PRESENT" + BulkEditOperationDetailsOperationTypeAddOrSet BulkEditOperationDetailsOperationTypeEnum = "ADD_OR_SET" + BulkEditOperationDetailsOperationTypeRemove BulkEditOperationDetailsOperationTypeEnum = "REMOVE" +) + +var mappingBulkEditOperationDetailsOperationType = map[string]BulkEditOperationDetailsOperationTypeEnum{ + "ADD_WHERE_ABSENT": BulkEditOperationDetailsOperationTypeAddWhereAbsent, + "SET_WHERE_PRESENT": BulkEditOperationDetailsOperationTypeSetWherePresent, + "ADD_OR_SET": BulkEditOperationDetailsOperationTypeAddOrSet, + "REMOVE": BulkEditOperationDetailsOperationTypeRemove, +} + +// GetBulkEditOperationDetailsOperationTypeEnumValues Enumerates the set of values for BulkEditOperationDetailsOperationTypeEnum +func GetBulkEditOperationDetailsOperationTypeEnumValues() []BulkEditOperationDetailsOperationTypeEnum { + values := make([]BulkEditOperationDetailsOperationTypeEnum, 0) + for _, v := range mappingBulkEditOperationDetailsOperationType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_resource.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_resource.go new file mode 100644 index 000000000..85a62fc6f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_resource.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BulkEditResource The representation of BulkEditResource +type BulkEditResource struct { + + // The unique OCID of the resource. + Id *string `mandatory:"true" json:"id"` + + // The type of resource. See ListBulkEditTagsResourceTypes. + ResourceType *string `mandatory:"true" json:"resourceType"` + + // Additional information that identifies the resource for bulk editing of tags. This information is provided in the resource's API documentation. + Metadata map[string]string `mandatory:"false" json:"metadata"` +} + +func (m BulkEditResource) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_details.go new file mode 100644 index 000000000..3559c00f2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_details.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BulkEditTagsDetails The representation of BulkEditTagsDetails +type BulkEditTagsDetails struct { + + // The OCID of the compartment where the bulk tag edit request is submitted. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The resources to be updated. + Resources []BulkEditResource `mandatory:"true" json:"resources"` + + // The operations associated with the request to bulk edit tags. + BulkEditOperations []BulkEditOperationDetails `mandatory:"true" json:"bulkEditOperations"` +} + +func (m BulkEditTagsDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_request_response.go new file mode 100644 index 000000000..410f031ff --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_request_response.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// BulkEditTagsRequest wrapper for the BulkEditTags operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/BulkEditTags.go.html to see an example of how to use BulkEditTagsRequest. +type BulkEditTagsRequest struct { + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // The request object for bulk editing tags on resources in the compartment. + BulkEditTagsDetails `contributesTo:"body"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request BulkEditTagsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request BulkEditTagsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request BulkEditTagsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request BulkEditTagsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// BulkEditTagsResponse wrapper for the BulkEditTags operation +type BulkEditTagsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response BulkEditTagsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response BulkEditTagsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_resource_type.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_resource_type.go new file mode 100644 index 000000000..dedd70cc2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_resource_type.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BulkEditTagsResourceType The representation of BulkEditTagsResourceType +type BulkEditTagsResourceType struct { + + // The unique name of the resource type. + ResourceType *string `mandatory:"true" json:"resourceType"` + + // The metadata keys required to identify the resource. + // For example, for a bucket, the value of `metadataKeys` will be "namespaceName", "bucketName". + // This information will match the API documentation. + // See UpdateBucket (https://docs.cloud.oracle.com/api/#/en/objectstorage/latest/Bucket/UpdateBucket) and + // DeleteBucket (https://docs.cloud.oracle.com/api/#/en/objectstorage/latest/Bucket/DeleteBucket). + MetadataKeys []string `mandatory:"false" json:"metadataKeys"` +} + +func (m BulkEditTagsResourceType) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_resource_type_collection.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_resource_type_collection.go new file mode 100644 index 000000000..bb41d6b36 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_edit_tags_resource_type_collection.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BulkEditTagsResourceTypeCollection The list of resource types that support bulk editing of tags. +type BulkEditTagsResourceTypeCollection struct { + + // The collection of resource types that support bulk editing of tags. + Items []BulkEditTagsResourceType `mandatory:"true" json:"items"` +} + +func (m BulkEditTagsResourceTypeCollection) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_move_resources_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_move_resources_details.go new file mode 100644 index 000000000..b094dfc83 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_move_resources_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BulkMoveResourcesDetails The representation of BulkMoveResourcesDetails +type BulkMoveResourcesDetails struct { + + // The resources to be moved. + Resources []BulkActionResource `mandatory:"true" json:"resources"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the destination compartment + // into which to move the resources. + TargetCompartmentId *string `mandatory:"true" json:"targetCompartmentId"` +} + +func (m BulkMoveResourcesDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_move_resources_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_move_resources_request_response.go new file mode 100644 index 000000000..419ccf72b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/bulk_move_resources_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// BulkMoveResourcesRequest wrapper for the BulkMoveResources operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/BulkMoveResources.go.html to see an example of how to use BulkMoveResourcesRequest. +type BulkMoveResourcesRequest struct { + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"path" name:"compartmentId"` + + // Request object for bulk move resources in the compartment. + BulkMoveResourcesDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request BulkMoveResourcesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request BulkMoveResourcesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request BulkMoveResourcesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request BulkMoveResourcesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// BulkMoveResourcesResponse wrapper for the BulkMoveResources operation +type BulkMoveResourcesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response BulkMoveResourcesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response BulkMoveResourcesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/cascade_delete_tag_namespace_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/cascade_delete_tag_namespace_request_response.go new file mode 100644 index 000000000..a35cfa8a9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/cascade_delete_tag_namespace_request_response.go @@ -0,0 +1,86 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CascadeDeleteTagNamespaceRequest wrapper for the CascadeDeleteTagNamespace operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CascadeDeleteTagNamespace.go.html to see an example of how to use CascadeDeleteTagNamespaceRequest. +type CascadeDeleteTagNamespaceRequest struct { + + // The OCID of the tag namespace. + TagNamespaceId *string `mandatory:"true" contributesTo:"path" name:"tagNamespaceId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CascadeDeleteTagNamespaceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CascadeDeleteTagNamespaceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CascadeDeleteTagNamespaceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CascadeDeleteTagNamespaceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CascadeDeleteTagNamespaceResponse wrapper for the CascadeDeleteTagNamespace operation +type CascadeDeleteTagNamespaceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response CascadeDeleteTagNamespaceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CascadeDeleteTagNamespaceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_compartment_details.go new file mode 100644 index 000000000..71d772732 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_compartment_details.go @@ -0,0 +1,26 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeDomainCompartmentDetails The representation of ChangeDomainCompartmentDetails +type ChangeDomainCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the destination compartment + // into which to move the domain. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeDomainCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_compartment_request_response.go new file mode 100644 index 000000000..321e6436f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_compartment_request_response.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeDomainCompartmentRequest wrapper for the ChangeDomainCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ChangeDomainCompartment.go.html to see an example of how to use ChangeDomainCompartmentRequest. +type ChangeDomainCompartmentRequest struct { + + // The OCID of the domain + DomainId *string `mandatory:"true" contributesTo:"path" name:"domainId"` + + // the request object for moving compartment of a domain + ChangeDomainCompartmentDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeDomainCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeDomainCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeDomainCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeDomainCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeDomainCompartmentResponse wrapper for the ChangeDomainCompartment operation +type ChangeDomainCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response ChangeDomainCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeDomainCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_license_type_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_license_type_details.go new file mode 100644 index 000000000..9960937c9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_license_type_details.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeDomainLicenseTypeDetails Update domain license type +type ChangeDomainLicenseTypeDetails struct { + + // The License type of Domain + LicenseType *string `mandatory:"false" json:"licenseType"` +} + +func (m ChangeDomainLicenseTypeDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_license_type_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_license_type_request_response.go new file mode 100644 index 000000000..2d8fd6f16 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_domain_license_type_request_response.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeDomainLicenseTypeRequest wrapper for the ChangeDomainLicenseType operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ChangeDomainLicenseType.go.html to see an example of how to use ChangeDomainLicenseTypeRequest. +type ChangeDomainLicenseTypeRequest struct { + + // The OCID of the domain + DomainId *string `mandatory:"true" contributesTo:"path" name:"domainId"` + + // the request object for domain license type update + ChangeDomainLicenseTypeDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeDomainLicenseTypeRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeDomainLicenseTypeRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeDomainLicenseTypeRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeDomainLicenseTypeRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeDomainLicenseTypeResponse wrapper for the ChangeDomainLicenseType operation +type ChangeDomainLicenseTypeResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response ChangeDomainLicenseTypeResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeDomainLicenseTypeResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_tag_namespace_compartment_detail.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_tag_namespace_compartment_detail.go new file mode 100644 index 000000000..792fb03ad --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_tag_namespace_compartment_detail.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeTagNamespaceCompartmentDetail Details of the compartment the resource is being moved to. +type ChangeTagNamespaceCompartmentDetail struct { + + // The Oracle Cloud ID (OCID) of the destination compartment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` +} + +func (m ChangeTagNamespaceCompartmentDetail) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_tag_namespace_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_tag_namespace_compartment_request_response.go new file mode 100644 index 000000000..7918844a5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_tag_namespace_compartment_request_response.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ChangeTagNamespaceCompartmentRequest wrapper for the ChangeTagNamespaceCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ChangeTagNamespaceCompartment.go.html to see an example of how to use ChangeTagNamespaceCompartmentRequest. +type ChangeTagNamespaceCompartmentRequest struct { + + // The OCID of the tag namespace. + TagNamespaceId *string `mandatory:"true" contributesTo:"path" name:"tagNamespaceId"` + + // Request object for changing the compartment of a tag namespace. + ChangeTagNamespaceCompartmentDetail `contributesTo:"body"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ChangeTagNamespaceCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ChangeTagNamespaceCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ChangeTagNamespaceCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ChangeTagNamespaceCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ChangeTagNamespaceCompartmentResponse wrapper for the ChangeTagNamespaceCompartment operation +type ChangeTagNamespaceCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ChangeTagNamespaceCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ChangeTagNamespaceCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_tas_domain_license_type_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_tas_domain_license_type_details.go new file mode 100644 index 000000000..744509731 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/change_tas_domain_license_type_details.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ChangeTasDomainLicenseTypeDetails Update domain license type +type ChangeTasDomainLicenseTypeDetails struct { + + // The License type of Domain + LicenseType *string `mandatory:"false" json:"licenseType"` +} + +func (m ChangeTasDomainLicenseTypeDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/compartment.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/compartment.go new file mode 100644 index 000000000..7c07e0861 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/compartment.go @@ -0,0 +1,105 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Compartment A collection of related resources. Compartments are a fundamental component of Oracle Cloud Infrastructure +// for organizing and isolating your cloud resources. You use them to clearly separate resources for the purposes +// of measuring usage and billing, access (through the use of IAM Service policies), and isolation (separating the +// resources for one project or business unit from another). A common approach is to create a compartment for each +// major part of your organization. For more information, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/Content/Identity/Concepts/overview.htm) and also +// Setting Up Your Tenancy (https://docs.cloud.oracle.com/Content/GSG/Concepts/settinguptenancy.htm). +// To place a resource in a compartment, simply specify the compartment ID in the "Create" request object when +// initially creating the resource. For example, to launch an instance into a particular compartment, specify +// that compartment's OCID in the `LaunchInstance` request. You can't move an existing resource from one +// compartment to another. +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, +// see Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you supply string values +// using the API. +type Compartment struct { + + // The OCID of the compartment. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the parent compartment containing the compartment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name you assign to the compartment during creation. The name must be unique across all + // compartments in the parent. Avoid entering confidential information. + Name *string `mandatory:"true" json:"name"` + + // The description you assign to the compartment. Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` + + // Date and time the compartment was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The compartment's current state. After creating a compartment, make sure its `lifecycleState` changes from + // CREATING to ACTIVE before using it. + LifecycleState CompartmentLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` + + // Indicates whether or not the compartment is accessible for the user making the request. + // Returns true when the user has INSPECT permissions directly on a resource in the + // compartment or indirectly (permissions can be on a resource in a subcompartment). + IsAccessible *bool `mandatory:"false" json:"isAccessible"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m Compartment) String() string { + return common.PointerString(m) +} + +// CompartmentLifecycleStateEnum Enum with underlying type: string +type CompartmentLifecycleStateEnum string + +// Set of constants representing the allowable values for CompartmentLifecycleStateEnum +const ( + CompartmentLifecycleStateCreating CompartmentLifecycleStateEnum = "CREATING" + CompartmentLifecycleStateActive CompartmentLifecycleStateEnum = "ACTIVE" + CompartmentLifecycleStateInactive CompartmentLifecycleStateEnum = "INACTIVE" + CompartmentLifecycleStateDeleting CompartmentLifecycleStateEnum = "DELETING" + CompartmentLifecycleStateDeleted CompartmentLifecycleStateEnum = "DELETED" +) + +var mappingCompartmentLifecycleState = map[string]CompartmentLifecycleStateEnum{ + "CREATING": CompartmentLifecycleStateCreating, + "ACTIVE": CompartmentLifecycleStateActive, + "INACTIVE": CompartmentLifecycleStateInactive, + "DELETING": CompartmentLifecycleStateDeleting, + "DELETED": CompartmentLifecycleStateDeleted, +} + +// GetCompartmentLifecycleStateEnumValues Enumerates the set of values for CompartmentLifecycleStateEnum +func GetCompartmentLifecycleStateEnumValues() []CompartmentLifecycleStateEnum { + values := make([]CompartmentLifecycleStateEnum, 0) + for _, v := range mappingCompartmentLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_api_key_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_api_key_details.go new file mode 100644 index 000000000..708a1e14c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_api_key_details.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateApiKeyDetails The representation of CreateApiKeyDetails +type CreateApiKeyDetails struct { + + // The public key. Must be an RSA key in PEM format. + Key *string `mandatory:"true" json:"key"` +} + +func (m CreateApiKeyDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_auth_token_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_auth_token_details.go new file mode 100644 index 000000000..4ce85d0a2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_auth_token_details.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateAuthTokenDetails The representation of CreateAuthTokenDetails +type CreateAuthTokenDetails struct { + + // The description you assign to the auth token during creation. Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` +} + +func (m CreateAuthTokenDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_auth_token_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_auth_token_request_response.go new file mode 100644 index 000000000..e7d119ab8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_auth_token_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateAuthTokenRequest wrapper for the CreateAuthToken operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateAuthToken.go.html to see an example of how to use CreateAuthTokenRequest. +type CreateAuthTokenRequest struct { + + // Request object for creating a new auth token. + CreateAuthTokenDetails `contributesTo:"body"` + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateAuthTokenRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateAuthTokenRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateAuthTokenRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateAuthTokenRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateAuthTokenResponse wrapper for the CreateAuthToken operation +type CreateAuthTokenResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The AuthToken instance + AuthToken `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateAuthTokenResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateAuthTokenResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_compartment_details.go new file mode 100644 index 000000000..19e3514c7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_compartment_details.go @@ -0,0 +1,42 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateCompartmentDetails The representation of CreateCompartmentDetails +type CreateCompartmentDetails struct { + + // The OCID of the parent compartment containing the compartment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name you assign to the compartment during creation. The name must be unique across all compartments + // in the parent compartment. Avoid entering confidential information. + Name *string `mandatory:"true" json:"name"` + + // The description you assign to the compartment during creation. Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m CreateCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_compartment_request_response.go new file mode 100644 index 000000000..6e33c3d10 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_compartment_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateCompartmentRequest wrapper for the CreateCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateCompartment.go.html to see an example of how to use CreateCompartmentRequest. +type CreateCompartmentRequest struct { + + // Request object for creating a new compartment. + CreateCompartmentDetails `contributesTo:"body"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateCompartmentResponse wrapper for the CreateCompartment operation +type CreateCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Compartment instance + Compartment `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_customer_secret_key_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_customer_secret_key_details.go new file mode 100644 index 000000000..35c35ff4a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_customer_secret_key_details.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateCustomerSecretKeyDetails The representation of CreateCustomerSecretKeyDetails +type CreateCustomerSecretKeyDetails struct { + + // The name you assign to the secret key during creation. Does not have to be unique, and it's changeable. + DisplayName *string `mandatory:"true" json:"displayName"` +} + +func (m CreateCustomerSecretKeyDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_customer_secret_key_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_customer_secret_key_request_response.go new file mode 100644 index 000000000..d2cf817c0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_customer_secret_key_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateCustomerSecretKeyRequest wrapper for the CreateCustomerSecretKey operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateCustomerSecretKey.go.html to see an example of how to use CreateCustomerSecretKeyRequest. +type CreateCustomerSecretKeyRequest struct { + + // Request object for creating a new secret key. + CreateCustomerSecretKeyDetails `contributesTo:"body"` + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateCustomerSecretKeyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateCustomerSecretKeyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateCustomerSecretKeyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateCustomerSecretKeyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateCustomerSecretKeyResponse wrapper for the CreateCustomerSecretKey operation +type CreateCustomerSecretKeyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The CustomerSecretKey instance + CustomerSecretKey `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateCustomerSecretKeyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateCustomerSecretKeyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_db_credential_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_db_credential_details.go new file mode 100644 index 000000000..3fc303ef0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_db_credential_details.go @@ -0,0 +1,28 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateDbCredentialDetails The representation of CreateDbCredentialDetails +type CreateDbCredentialDetails struct { + + // The password for the DB credentials during creation. + Password *string `mandatory:"true" json:"password"` + + // The description you assign to the DB credentials during creation. + Description *string `mandatory:"true" json:"description"` +} + +func (m CreateDbCredentialDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_db_credential_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_db_credential_request_response.go new file mode 100644 index 000000000..0448320af --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_db_credential_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateDbCredentialRequest wrapper for the CreateDbCredential operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateDbCredential.go.html to see an example of how to use CreateDbCredentialRequest. +type CreateDbCredentialRequest struct { + + // Request object for creating a new DB credential with the user. + CreateDbCredentialDetails `contributesTo:"body"` + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateDbCredentialRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateDbCredentialRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateDbCredentialRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateDbCredentialRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateDbCredentialResponse wrapper for the CreateDbCredential operation +type CreateDbCredentialResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DbCredential instance + DbCredential `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateDbCredentialResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateDbCredentialResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_domain_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_domain_details.go new file mode 100644 index 000000000..b10aa0160 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_domain_details.go @@ -0,0 +1,73 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateDomainDetails Create a domain details +type CreateDomainDetails struct { + + // The OCID of the Compartment where domain is created + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The mutable display name of the domain. + DisplayName *string `mandatory:"true" json:"displayName"` + + // Domain entity description + Description *string `mandatory:"true" json:"description"` + + // The region's name identifier. See Regions and Availability Domains (https://docs.cloud.oracle.com/Content/General/Concepts/regions.htm) + // for the full list of supported region names. + // Example: `us-phoenix-1` + HomeRegion *string `mandatory:"true" json:"homeRegion"` + + // The License type of Domain + LicenseType *string `mandatory:"true" json:"licenseType"` + + // Indicates whether domain is hidden on login screen or not. + IsHiddenOnLogin *bool `mandatory:"false" json:"isHiddenOnLogin"` + + // The admin first name + AdminFirstName *string `mandatory:"false" json:"adminFirstName"` + + // The admin last name + AdminLastName *string `mandatory:"false" json:"adminLastName"` + + // The admin user name + AdminUserName *string `mandatory:"false" json:"adminUserName"` + + // The admin email address + AdminEmail *string `mandatory:"false" json:"adminEmail"` + + // Indicates if admin user created in IDCS stripe would like to receive notification like welcome email + // or not. + // Required field only if admin information is provided, otherwise optional. + IsNotificationBypassed *bool `mandatory:"false" json:"isNotificationBypassed"` + + // Optional field to indicate whether users in the domain are required to have a primary email address or not + // Defaults to true + IsPrimaryEmailRequired *bool `mandatory:"false" json:"isPrimaryEmailRequired"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m CreateDomainDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_domain_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_domain_request_response.go new file mode 100644 index 000000000..263d27f9e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_domain_request_response.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateDomainRequest wrapper for the CreateDomain operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateDomain.go.html to see an example of how to use CreateDomainRequest. +type CreateDomainRequest struct { + + // The request object for creating a new domain + CreateDomainDetails `contributesTo:"body"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateDomainRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateDomainRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateDomainRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateDomainRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateDomainResponse wrapper for the CreateDomain operation +type CreateDomainResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response CreateDomainResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateDomainResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_dynamic_group_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_dynamic_group_details.go new file mode 100644 index 000000000..9a996260a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_dynamic_group_details.go @@ -0,0 +1,46 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateDynamicGroupDetails Properties for creating a dynamic group. +type CreateDynamicGroupDetails struct { + + // The OCID of the tenancy containing the group. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name you assign to the group during creation. The name must be unique across all groups + // in the tenancy and cannot be changed. + Name *string `mandatory:"true" json:"name"` + + // The matching rule to dynamically match an instance certificate to this dynamic group. + // For rule syntax, see Managing Dynamic Groups (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingdynamicgroups.htm). + MatchingRule *string `mandatory:"true" json:"matchingRule"` + + // The description you assign to the group during creation. Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m CreateDynamicGroupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_dynamic_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_dynamic_group_request_response.go new file mode 100644 index 000000000..8507cb895 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_dynamic_group_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateDynamicGroupRequest wrapper for the CreateDynamicGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateDynamicGroup.go.html to see an example of how to use CreateDynamicGroupRequest. +type CreateDynamicGroupRequest struct { + + // Request object for creating a new dynamic group. + CreateDynamicGroupDetails `contributesTo:"body"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateDynamicGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateDynamicGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateDynamicGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateDynamicGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateDynamicGroupResponse wrapper for the CreateDynamicGroup operation +type CreateDynamicGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DynamicGroup instance + DynamicGroup `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateDynamicGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateDynamicGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_group_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_group_details.go new file mode 100644 index 000000000..dc1afb743 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_group_details.go @@ -0,0 +1,42 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateGroupDetails The representation of CreateGroupDetails +type CreateGroupDetails struct { + + // The OCID of the tenancy containing the group. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name you assign to the group during creation. The name must be unique across all groups + // in the tenancy and cannot be changed. + Name *string `mandatory:"true" json:"name"` + + // The description you assign to the group during creation. Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m CreateGroupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_group_request_response.go new file mode 100644 index 000000000..e5d0be6fb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_group_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateGroupRequest wrapper for the CreateGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateGroup.go.html to see an example of how to use CreateGroupRequest. +type CreateGroupRequest struct { + + // Request object for creating a new group. + CreateGroupDetails `contributesTo:"body"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateGroupResponse wrapper for the CreateGroup operation +type CreateGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Group instance + Group `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_identity_provider_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_identity_provider_details.go new file mode 100644 index 000000000..df3bdd118 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_identity_provider_details.go @@ -0,0 +1,178 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateIdentityProviderDetails The representation of CreateIdentityProviderDetails +type CreateIdentityProviderDetails interface { + + // The OCID of your tenancy. + GetCompartmentId() *string + + // The name you assign to the `IdentityProvider` during creation. + // The name must be unique across all `IdentityProvider` objects in the + // tenancy and cannot be changed. + GetName() *string + + // The description you assign to the `IdentityProvider` during creation. + // Does not have to be unique, and it's changeable. + GetDescription() *string + + // The identity provider service or product. + // Supported identity providers are Oracle Identity Cloud Service (IDCS) and Microsoft + // Active Directory Federation Services (ADFS). + // Example: `IDCS` + GetProductType() CreateIdentityProviderDetailsProductTypeEnum + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + GetFreeformTags() map[string]string + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + GetDefinedTags() map[string]map[string]interface{} +} + +type createidentityproviderdetails struct { + JsonData []byte + CompartmentId *string `mandatory:"true" json:"compartmentId"` + Name *string `mandatory:"true" json:"name"` + Description *string `mandatory:"true" json:"description"` + ProductType CreateIdentityProviderDetailsProductTypeEnum `mandatory:"true" json:"productType"` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + Protocol string `json:"protocol"` +} + +// UnmarshalJSON unmarshals json +func (m *createidentityproviderdetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalercreateidentityproviderdetails createidentityproviderdetails + s := struct { + Model Unmarshalercreateidentityproviderdetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.CompartmentId = s.Model.CompartmentId + m.Name = s.Model.Name + m.Description = s.Model.Description + m.ProductType = s.Model.ProductType + m.FreeformTags = s.Model.FreeformTags + m.DefinedTags = s.Model.DefinedTags + m.Protocol = s.Model.Protocol + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *createidentityproviderdetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Protocol { + case "SAML2": + mm := CreateSaml2IdentityProviderDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetCompartmentId returns CompartmentId +func (m createidentityproviderdetails) GetCompartmentId() *string { + return m.CompartmentId +} + +//GetName returns Name +func (m createidentityproviderdetails) GetName() *string { + return m.Name +} + +//GetDescription returns Description +func (m createidentityproviderdetails) GetDescription() *string { + return m.Description +} + +//GetProductType returns ProductType +func (m createidentityproviderdetails) GetProductType() CreateIdentityProviderDetailsProductTypeEnum { + return m.ProductType +} + +//GetFreeformTags returns FreeformTags +func (m createidentityproviderdetails) GetFreeformTags() map[string]string { + return m.FreeformTags +} + +//GetDefinedTags returns DefinedTags +func (m createidentityproviderdetails) GetDefinedTags() map[string]map[string]interface{} { + return m.DefinedTags +} + +func (m createidentityproviderdetails) String() string { + return common.PointerString(m) +} + +// CreateIdentityProviderDetailsProductTypeEnum Enum with underlying type: string +type CreateIdentityProviderDetailsProductTypeEnum string + +// Set of constants representing the allowable values for CreateIdentityProviderDetailsProductTypeEnum +const ( + CreateIdentityProviderDetailsProductTypeIdcs CreateIdentityProviderDetailsProductTypeEnum = "IDCS" + CreateIdentityProviderDetailsProductTypeAdfs CreateIdentityProviderDetailsProductTypeEnum = "ADFS" +) + +var mappingCreateIdentityProviderDetailsProductType = map[string]CreateIdentityProviderDetailsProductTypeEnum{ + "IDCS": CreateIdentityProviderDetailsProductTypeIdcs, + "ADFS": CreateIdentityProviderDetailsProductTypeAdfs, +} + +// GetCreateIdentityProviderDetailsProductTypeEnumValues Enumerates the set of values for CreateIdentityProviderDetailsProductTypeEnum +func GetCreateIdentityProviderDetailsProductTypeEnumValues() []CreateIdentityProviderDetailsProductTypeEnum { + values := make([]CreateIdentityProviderDetailsProductTypeEnum, 0) + for _, v := range mappingCreateIdentityProviderDetailsProductType { + values = append(values, v) + } + return values +} + +// CreateIdentityProviderDetailsProtocolEnum Enum with underlying type: string +type CreateIdentityProviderDetailsProtocolEnum string + +// Set of constants representing the allowable values for CreateIdentityProviderDetailsProtocolEnum +const ( + CreateIdentityProviderDetailsProtocolSaml2 CreateIdentityProviderDetailsProtocolEnum = "SAML2" + CreateIdentityProviderDetailsProtocolAdfs CreateIdentityProviderDetailsProtocolEnum = "ADFS" +) + +var mappingCreateIdentityProviderDetailsProtocol = map[string]CreateIdentityProviderDetailsProtocolEnum{ + "SAML2": CreateIdentityProviderDetailsProtocolSaml2, + "ADFS": CreateIdentityProviderDetailsProtocolAdfs, +} + +// GetCreateIdentityProviderDetailsProtocolEnumValues Enumerates the set of values for CreateIdentityProviderDetailsProtocolEnum +func GetCreateIdentityProviderDetailsProtocolEnumValues() []CreateIdentityProviderDetailsProtocolEnum { + values := make([]CreateIdentityProviderDetailsProtocolEnum, 0) + for _, v := range mappingCreateIdentityProviderDetailsProtocol { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_identity_provider_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_identity_provider_request_response.go new file mode 100644 index 000000000..a94a345b4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_identity_provider_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateIdentityProviderRequest wrapper for the CreateIdentityProvider operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateIdentityProvider.go.html to see an example of how to use CreateIdentityProviderRequest. +type CreateIdentityProviderRequest struct { + + // Request object for creating a new SAML2 identity provider. + CreateIdentityProviderDetails `contributesTo:"body"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateIdentityProviderRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateIdentityProviderRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateIdentityProviderRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateIdentityProviderRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateIdentityProviderResponse wrapper for the CreateIdentityProvider operation +type CreateIdentityProviderResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IdentityProvider instance + IdentityProvider `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateIdentityProviderResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateIdentityProviderResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_idp_group_mapping_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_idp_group_mapping_details.go new file mode 100644 index 000000000..ff6ce8ceb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_idp_group_mapping_details.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateIdpGroupMappingDetails The representation of CreateIdpGroupMappingDetails +type CreateIdpGroupMappingDetails struct { + + // The name of the IdP group you want to map. + IdpGroupName *string `mandatory:"true" json:"idpGroupName"` + + // The OCID of the IAM Service Group + // you want to map to the IdP group. + GroupId *string `mandatory:"true" json:"groupId"` +} + +func (m CreateIdpGroupMappingDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_idp_group_mapping_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_idp_group_mapping_request_response.go new file mode 100644 index 000000000..05ba46fff --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_idp_group_mapping_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateIdpGroupMappingRequest wrapper for the CreateIdpGroupMapping operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateIdpGroupMapping.go.html to see an example of how to use CreateIdpGroupMappingRequest. +type CreateIdpGroupMappingRequest struct { + + // Add a mapping from an SAML2.0 identity provider group to a BMC group. + CreateIdpGroupMappingDetails `contributesTo:"body"` + + // The OCID of the identity provider. + IdentityProviderId *string `mandatory:"true" contributesTo:"path" name:"identityProviderId"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateIdpGroupMappingRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateIdpGroupMappingRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateIdpGroupMappingRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateIdpGroupMappingRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateIdpGroupMappingResponse wrapper for the CreateIdpGroupMapping operation +type CreateIdpGroupMappingResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IdpGroupMapping instance + IdpGroupMapping `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateIdpGroupMappingResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateIdpGroupMappingResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_mfa_totp_device_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_mfa_totp_device_request_response.go new file mode 100644 index 000000000..9473e30a9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_mfa_totp_device_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateMfaTotpDeviceRequest wrapper for the CreateMfaTotpDevice operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateMfaTotpDevice.go.html to see an example of how to use CreateMfaTotpDeviceRequest. +type CreateMfaTotpDeviceRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateMfaTotpDeviceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateMfaTotpDeviceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateMfaTotpDeviceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateMfaTotpDeviceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateMfaTotpDeviceResponse wrapper for the CreateMfaTotpDevice operation +type CreateMfaTotpDeviceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The MfaTotpDevice instance + MfaTotpDevice `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateMfaTotpDeviceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateMfaTotpDeviceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_network_source_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_network_source_details.go new file mode 100644 index 000000000..348890f7f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_network_source_details.go @@ -0,0 +1,54 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateNetworkSourceDetails Properties for creating a network source object. +type CreateNetworkSourceDetails struct { + + // The OCID of the tenancy (root compartment) containing the network source object. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name you assign to the network source during creation. The name must be unique across all groups + // in the tenancy and cannot be changed. + Name *string `mandatory:"true" json:"name"` + + // The description you assign to the network source during creation. Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` + + // A list of allowed public IP addresses and CIDR ranges. + PublicSourceList []string `mandatory:"false" json:"publicSourceList"` + + // A list of allowed VCN OCID and IP range pairs. + // Example:`"vcnId": "ocid1.vcn.oc1.iad.aaaaaaaaexampleuniqueID", "ipRanges": [ "129.213.39.0/24" ]` + VirtualSourceList []NetworkSourcesVirtualSourceList `mandatory:"false" json:"virtualSourceList"` + + // A list of services allowed to make on-behalf-of requests. These requests can have different source IP addresses + // than those listed in the network source. + // Currently, only `all` and `none` are supported. The default is `all`. + Services []string `mandatory:"false" json:"services"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m CreateNetworkSourceDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_network_source_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_network_source_request_response.go new file mode 100644 index 000000000..117d0004e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_network_source_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateNetworkSourceRequest wrapper for the CreateNetworkSource operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateNetworkSource.go.html to see an example of how to use CreateNetworkSourceRequest. +type CreateNetworkSourceRequest struct { + + // Request object for creating a new network source. + CreateNetworkSourceDetails `contributesTo:"body"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateNetworkSourceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateNetworkSourceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateNetworkSourceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateNetworkSourceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateNetworkSourceResponse wrapper for the CreateNetworkSource operation +type CreateNetworkSourceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The NetworkSources instance + NetworkSources `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateNetworkSourceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateNetworkSourceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_o_auth2_client_credential_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_o_auth2_client_credential_details.go new file mode 100644 index 000000000..15555308d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_o_auth2_client_credential_details.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateOAuth2ClientCredentialDetails The representation of CreateOAuth2ClientCredentialDetails +type CreateOAuth2ClientCredentialDetails struct { + + // Name of the oauth credential to help user differentiate them. + Name *string `mandatory:"true" json:"name"` + + // Description of the oauth credential to help user differentiate them. + Description *string `mandatory:"true" json:"description"` + + // Allowed scopes for the given oauth credential. + Scopes []FullyQualifiedScope `mandatory:"true" json:"scopes"` +} + +func (m CreateOAuth2ClientCredentialDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_o_auth_client_credential_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_o_auth_client_credential_request_response.go new file mode 100644 index 000000000..2c8608dc6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_o_auth_client_credential_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateOAuthClientCredentialRequest wrapper for the CreateOAuthClientCredential operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateOAuthClientCredential.go.html to see an example of how to use CreateOAuthClientCredentialRequest. +type CreateOAuthClientCredentialRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // Request object containing the information required to generate an Oauth token. + CreateOAuth2ClientCredentialDetails `contributesTo:"body"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateOAuthClientCredentialRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateOAuthClientCredentialRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateOAuthClientCredentialRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateOAuthClientCredentialRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateOAuthClientCredentialResponse wrapper for the CreateOAuthClientCredential operation +type CreateOAuthClientCredentialResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The OAuth2ClientCredential instance + OAuth2ClientCredential `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateOAuthClientCredentialResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateOAuthClientCredentialResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_or_reset_u_i_password_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_or_reset_u_i_password_request_response.go new file mode 100644 index 000000000..e5fbda7c5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_or_reset_u_i_password_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateOrResetUIPasswordRequest wrapper for the CreateOrResetUIPassword operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateOrResetUIPassword.go.html to see an example of how to use CreateOrResetUIPasswordRequest. +type CreateOrResetUIPasswordRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateOrResetUIPasswordRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateOrResetUIPasswordRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateOrResetUIPasswordRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateOrResetUIPasswordRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateOrResetUIPasswordResponse wrapper for the CreateOrResetUIPassword operation +type CreateOrResetUIPasswordResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The UiPassword instance + UiPassword `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateOrResetUIPasswordResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateOrResetUIPasswordResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_policy_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_policy_details.go new file mode 100644 index 000000000..4c54ca58d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_policy_details.go @@ -0,0 +1,52 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreatePolicyDetails The representation of CreatePolicyDetails +type CreatePolicyDetails struct { + + // The OCID of the compartment containing the policy (either the tenancy or another compartment). + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name you assign to the policy during creation. The name must be unique across all policies + // in the tenancy and cannot be changed. + Name *string `mandatory:"true" json:"name"` + + // An array of policy statements written in the policy language. See + // How Policies Work (https://docs.cloud.oracle.com/Content/Identity/Concepts/policies.htm) and + // Common Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/commonpolicies.htm). + Statements []string `mandatory:"true" json:"statements"` + + // The description you assign to the policy during creation. Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` + + // The version of the policy. If null or set to an empty string, when a request comes in for authorization, the + // policy will be evaluated according to the current behavior of the services at that moment. If set to a particular + // date (YYYY-MM-DD), the policy will be evaluated according to the behavior of the services on that date. + VersionDate *common.SDKDate `mandatory:"false" json:"versionDate"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m CreatePolicyDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_policy_request_response.go new file mode 100644 index 000000000..dfccb5bb1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_policy_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreatePolicyRequest wrapper for the CreatePolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreatePolicy.go.html to see an example of how to use CreatePolicyRequest. +type CreatePolicyRequest struct { + + // Request object for creating a new policy. + CreatePolicyDetails `contributesTo:"body"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreatePolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreatePolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreatePolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreatePolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreatePolicyResponse wrapper for the CreatePolicy operation +type CreatePolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Policy instance + Policy `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreatePolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreatePolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_region_subscription_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_region_subscription_details.go new file mode 100644 index 000000000..bdd21716c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_region_subscription_details.go @@ -0,0 +1,27 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateRegionSubscriptionDetails The representation of CreateRegionSubscriptionDetails +type CreateRegionSubscriptionDetails struct { + + // The regions's key. See Regions and Availability Domains (https://docs.cloud.oracle.com/Content/General/Concepts/regions.htm) for + // the full list of supported 3-letter region codes. + // Example: `PHX` + RegionKey *string `mandatory:"true" json:"regionKey"` +} + +func (m CreateRegionSubscriptionDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_region_subscription_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_region_subscription_request_response.go new file mode 100644 index 000000000..ca155d167 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_region_subscription_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateRegionSubscriptionRequest wrapper for the CreateRegionSubscription operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateRegionSubscription.go.html to see an example of how to use CreateRegionSubscriptionRequest. +type CreateRegionSubscriptionRequest struct { + + // Request object for activate a new region. + CreateRegionSubscriptionDetails `contributesTo:"body"` + + // The OCID of the tenancy. + TenancyId *string `mandatory:"true" contributesTo:"path" name:"tenancyId"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateRegionSubscriptionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateRegionSubscriptionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateRegionSubscriptionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateRegionSubscriptionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateRegionSubscriptionResponse wrapper for the CreateRegionSubscription operation +type CreateRegionSubscriptionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The RegionSubscription instance + RegionSubscription `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateRegionSubscriptionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateRegionSubscriptionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_saml2_identity_provider_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_saml2_identity_provider_details.go new file mode 100644 index 000000000..01527233d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_saml2_identity_provider_details.go @@ -0,0 +1,106 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateSaml2IdentityProviderDetails The representation of CreateSaml2IdentityProviderDetails +type CreateSaml2IdentityProviderDetails struct { + + // The OCID of your tenancy. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name you assign to the `IdentityProvider` during creation. + // The name must be unique across all `IdentityProvider` objects in the + // tenancy and cannot be changed. + Name *string `mandatory:"true" json:"name"` + + // The description you assign to the `IdentityProvider` during creation. + // Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` + + // The URL for retrieving the identity provider's metadata, + // which contains information required for federating. + MetadataUrl *string `mandatory:"true" json:"metadataUrl"` + + // The XML that contains the information required for federating. + Metadata *string `mandatory:"true" json:"metadata"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Extra name value pairs associated with this identity provider. + // Example: `{"clientId": "app_sf3kdjf3"}` + FreeformAttributes map[string]string `mandatory:"false" json:"freeformAttributes"` + + // The identity provider service or product. + // Supported identity providers are Oracle Identity Cloud Service (IDCS) and Microsoft + // Active Directory Federation Services (ADFS). + // Example: `IDCS` + ProductType CreateIdentityProviderDetailsProductTypeEnum `mandatory:"true" json:"productType"` +} + +//GetCompartmentId returns CompartmentId +func (m CreateSaml2IdentityProviderDetails) GetCompartmentId() *string { + return m.CompartmentId +} + +//GetName returns Name +func (m CreateSaml2IdentityProviderDetails) GetName() *string { + return m.Name +} + +//GetDescription returns Description +func (m CreateSaml2IdentityProviderDetails) GetDescription() *string { + return m.Description +} + +//GetProductType returns ProductType +func (m CreateSaml2IdentityProviderDetails) GetProductType() CreateIdentityProviderDetailsProductTypeEnum { + return m.ProductType +} + +//GetFreeformTags returns FreeformTags +func (m CreateSaml2IdentityProviderDetails) GetFreeformTags() map[string]string { + return m.FreeformTags +} + +//GetDefinedTags returns DefinedTags +func (m CreateSaml2IdentityProviderDetails) GetDefinedTags() map[string]map[string]interface{} { + return m.DefinedTags +} + +func (m CreateSaml2IdentityProviderDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m CreateSaml2IdentityProviderDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeCreateSaml2IdentityProviderDetails CreateSaml2IdentityProviderDetails + s := struct { + DiscriminatorParam string `json:"protocol"` + MarshalTypeCreateSaml2IdentityProviderDetails + }{ + "SAML2", + (MarshalTypeCreateSaml2IdentityProviderDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_smtp_credential_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_smtp_credential_details.go new file mode 100644 index 000000000..8cb72a4cc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_smtp_credential_details.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateSmtpCredentialDetails The representation of CreateSmtpCredentialDetails +type CreateSmtpCredentialDetails struct { + + // The description you assign to the SMTP credentials during creation. Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` +} + +func (m CreateSmtpCredentialDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_smtp_credential_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_smtp_credential_request_response.go new file mode 100644 index 000000000..114dca83f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_smtp_credential_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateSmtpCredentialRequest wrapper for the CreateSmtpCredential operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateSmtpCredential.go.html to see an example of how to use CreateSmtpCredentialRequest. +type CreateSmtpCredentialRequest struct { + + // Request object for creating a new SMTP credential with the user. + CreateSmtpCredentialDetails `contributesTo:"body"` + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateSmtpCredentialRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateSmtpCredentialRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateSmtpCredentialRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateSmtpCredentialRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateSmtpCredentialResponse wrapper for the CreateSmtpCredential operation +type CreateSmtpCredentialResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The SmtpCredential instance + SmtpCredential `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateSmtpCredentialResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateSmtpCredentialResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_swift_password_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_swift_password_details.go new file mode 100644 index 000000000..9808bbd4c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_swift_password_details.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateSwiftPasswordDetails The representation of CreateSwiftPasswordDetails +type CreateSwiftPasswordDetails struct { + + // The description you assign to the Swift password during creation. Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` +} + +func (m CreateSwiftPasswordDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_swift_password_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_swift_password_request_response.go new file mode 100644 index 000000000..eb6d5fdf1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_swift_password_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateSwiftPasswordRequest wrapper for the CreateSwiftPassword operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateSwiftPassword.go.html to see an example of how to use CreateSwiftPasswordRequest. +type CreateSwiftPasswordRequest struct { + + // Request object for creating a new swift password. + CreateSwiftPasswordDetails `contributesTo:"body"` + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateSwiftPasswordRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateSwiftPasswordRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateSwiftPasswordRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateSwiftPasswordRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateSwiftPasswordResponse wrapper for the CreateSwiftPassword operation +type CreateSwiftPasswordResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The SwiftPassword instance + SwiftPassword `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateSwiftPasswordResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateSwiftPasswordResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_default_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_default_details.go new file mode 100644 index 000000000..8c8d11ff3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_default_details.go @@ -0,0 +1,39 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateTagDefaultDetails The representation of CreateTagDefaultDetails +type CreateTagDefaultDetails struct { + + // The OCID of the compartment. The tag default will be applied to all new resources created in this compartment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the tag definition. The tag default will always assign a default value for this tag definition. + TagDefinitionId *string `mandatory:"true" json:"tagDefinitionId"` + + // The default value for the tag definition. This will be applied to all new resources created in the compartment. + Value *string `mandatory:"true" json:"value"` + + // If you specify that a value is required, a value is set during resource creation (either by + // the user creating the resource or another tag defualt). If no value is set, resource + // creation is blocked. + // * If the `isRequired` flag is set to "true", the value is set during resource creation. + // * If the `isRequired` flag is set to "false", the value you enter is set during resource creation. + // Example: `false` + IsRequired *bool `mandatory:"false" json:"isRequired"` +} + +func (m CreateTagDefaultDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_default_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_default_request_response.go new file mode 100644 index 000000000..fdcf2a2f3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_default_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateTagDefaultRequest wrapper for the CreateTagDefault operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateTagDefault.go.html to see an example of how to use CreateTagDefaultRequest. +type CreateTagDefaultRequest struct { + + // Request object for creating a new tag default. + CreateTagDefaultDetails `contributesTo:"body"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateTagDefaultRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateTagDefaultRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateTagDefaultRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateTagDefaultRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateTagDefaultResponse wrapper for the CreateTagDefault operation +type CreateTagDefaultResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The TagDefault instance + TagDefault `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateTagDefaultResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateTagDefaultResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_details.go new file mode 100644 index 000000000..3656bd7ba --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_details.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateTagDetails The representation of CreateTagDetails +type CreateTagDetails struct { + + // The name you assign to the tag during creation. This is the tag key definition. + // The name must be unique within the tag namespace and cannot be changed. + Name *string `mandatory:"true" json:"name"` + + // The description you assign to the tag during creation. + Description *string `mandatory:"true" json:"description"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Indicates whether the tag is enabled for cost tracking. + IsCostTracking *bool `mandatory:"false" json:"isCostTracking"` + + Validator BaseTagDefinitionValidator `mandatory:"false" json:"validator"` +} + +func (m CreateTagDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *CreateTagDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + FreeformTags map[string]string `json:"freeformTags"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + IsCostTracking *bool `json:"isCostTracking"` + Validator basetagdefinitionvalidator `json:"validator"` + Name *string `json:"name"` + Description *string `json:"description"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.FreeformTags = model.FreeformTags + + m.DefinedTags = model.DefinedTags + + m.IsCostTracking = model.IsCostTracking + + nn, e = model.Validator.UnmarshalPolymorphicJSON(model.Validator.JsonData) + if e != nil { + return + } + if nn != nil { + m.Validator = nn.(BaseTagDefinitionValidator) + } else { + m.Validator = nil + } + + m.Name = model.Name + + m.Description = model.Description + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_namespace_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_namespace_details.go new file mode 100644 index 000000000..f2422608b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_namespace_details.go @@ -0,0 +1,41 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateTagNamespaceDetails The representation of CreateTagNamespaceDetails +type CreateTagNamespaceDetails struct { + + // The OCID of the tenancy containing the tag namespace. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name you assign to the tag namespace during creation. It must be unique across all tag namespaces in the tenancy and cannot be changed. + Name *string `mandatory:"true" json:"name"` + + // The description you assign to the tag namespace during creation. + Description *string `mandatory:"true" json:"description"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m CreateTagNamespaceDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_namespace_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_namespace_request_response.go new file mode 100644 index 000000000..34ae3699e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_namespace_request_response.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateTagNamespaceRequest wrapper for the CreateTagNamespace operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateTagNamespace.go.html to see an example of how to use CreateTagNamespaceRequest. +type CreateTagNamespaceRequest struct { + + // Request object for creating a new tag namespace. + CreateTagNamespaceDetails `contributesTo:"body"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateTagNamespaceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateTagNamespaceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateTagNamespaceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateTagNamespaceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateTagNamespaceResponse wrapper for the CreateTagNamespace operation +type CreateTagNamespaceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The TagNamespace instance + TagNamespace `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreateTagNamespaceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateTagNamespaceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_request_response.go new file mode 100644 index 000000000..aa96597cf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_tag_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateTagRequest wrapper for the CreateTag operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateTag.go.html to see an example of how to use CreateTagRequest. +type CreateTagRequest struct { + + // The OCID of the tag namespace. + TagNamespaceId *string `mandatory:"true" contributesTo:"path" name:"tagNamespaceId"` + + // Request object for creating a new tag in the specified tag namespace. + CreateTagDetails `contributesTo:"body"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateTagRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateTagRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateTagRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateTagRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateTagResponse wrapper for the CreateTag operation +type CreateTagResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Tag instance + Tag `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateTagResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateTagResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_user_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_user_details.go new file mode 100644 index 000000000..fb606f4dd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_user_details.go @@ -0,0 +1,45 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateUserDetails The representation of CreateUserDetails +type CreateUserDetails struct { + + // The OCID of the tenancy containing the user. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name you assign to the user during creation. This is the user's login for the Console. + // The name must be unique across all users in the tenancy and cannot be changed. + Name *string `mandatory:"true" json:"name"` + + // The description you assign to the user during creation. Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` + + // The email you assign to the user. Has to be unique across the tenancy. + Email *string `mandatory:"false" json:"email"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m CreateUserDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_user_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_user_request_response.go new file mode 100644 index 000000000..8ef567a28 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/create_user_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateUserRequest wrapper for the CreateUser operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateUser.go.html to see an example of how to use CreateUserRequest. +type CreateUserRequest struct { + + // Request object for creating a new user. + CreateUserDetails `contributesTo:"body"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateUserRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateUserRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateUserRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateUserRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateUserResponse wrapper for the CreateUser operation +type CreateUserResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The User instance + User `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateUserResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateUserResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/customer_secret_key.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/customer_secret_key.go new file mode 100644 index 000000000..1565a9a14 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/customer_secret_key.go @@ -0,0 +1,83 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CustomerSecretKey A `CustomerSecretKey` is an Oracle-provided key for using the Object Storage Service's +// Amazon S3 compatible API (https://docs.cloud.oracle.com/Content/Object/Tasks/s3compatibleapi.htm). The key consists of a +// secret key/access key pair. A user can have up to two secret keys at a time. +// **Note:** The secret key is always an Oracle-generated string; you can't change it to a string of your choice. +// For more information, see Managing User Credentials (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingcredentials.htm). +type CustomerSecretKey struct { + + // The secret key. + Key *string `mandatory:"false" json:"key"` + + // The access key portion of the key pair. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the user the password belongs to. + UserId *string `mandatory:"false" json:"userId"` + + // The display name you assign to the secret key. Does not have to be unique, and it's changeable. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Date and time the `CustomerSecretKey` object was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // Date and time when this password will expire, in the format defined by RFC3339. + // Null if it never expires. + // Example: `2016-08-25T21:10:29.600Z` + TimeExpires *common.SDKTime `mandatory:"false" json:"timeExpires"` + + // The secret key's current state. After creating a secret key, make sure its `lifecycleState` changes from + // CREATING to ACTIVE before using it. + LifecycleState CustomerSecretKeyLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` +} + +func (m CustomerSecretKey) String() string { + return common.PointerString(m) +} + +// CustomerSecretKeyLifecycleStateEnum Enum with underlying type: string +type CustomerSecretKeyLifecycleStateEnum string + +// Set of constants representing the allowable values for CustomerSecretKeyLifecycleStateEnum +const ( + CustomerSecretKeyLifecycleStateCreating CustomerSecretKeyLifecycleStateEnum = "CREATING" + CustomerSecretKeyLifecycleStateActive CustomerSecretKeyLifecycleStateEnum = "ACTIVE" + CustomerSecretKeyLifecycleStateInactive CustomerSecretKeyLifecycleStateEnum = "INACTIVE" + CustomerSecretKeyLifecycleStateDeleting CustomerSecretKeyLifecycleStateEnum = "DELETING" + CustomerSecretKeyLifecycleStateDeleted CustomerSecretKeyLifecycleStateEnum = "DELETED" +) + +var mappingCustomerSecretKeyLifecycleState = map[string]CustomerSecretKeyLifecycleStateEnum{ + "CREATING": CustomerSecretKeyLifecycleStateCreating, + "ACTIVE": CustomerSecretKeyLifecycleStateActive, + "INACTIVE": CustomerSecretKeyLifecycleStateInactive, + "DELETING": CustomerSecretKeyLifecycleStateDeleting, + "DELETED": CustomerSecretKeyLifecycleStateDeleted, +} + +// GetCustomerSecretKeyLifecycleStateEnumValues Enumerates the set of values for CustomerSecretKeyLifecycleStateEnum +func GetCustomerSecretKeyLifecycleStateEnumValues() []CustomerSecretKeyLifecycleStateEnum { + values := make([]CustomerSecretKeyLifecycleStateEnum, 0) + for _, v := range mappingCustomerSecretKeyLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/customer_secret_key_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/customer_secret_key_summary.go new file mode 100644 index 000000000..9bcc033db --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/customer_secret_key_summary.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CustomerSecretKeySummary As the name suggests, a `CustomerSecretKeySummary` object contains information about a `CustomerSecretKey`. +// A `CustomerSecretKey` is an Oracle-provided key for using the Object Storage Service's Amazon S3 compatible API. +type CustomerSecretKeySummary struct { + + // The OCID of the secret key. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the user the password belongs to. + UserId *string `mandatory:"false" json:"userId"` + + // The displayName you assign to the secret key. Does not have to be unique, and it's changeable. + DisplayName *string `mandatory:"false" json:"displayName"` + + // Date and time the `CustomerSecretKey` object was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // Date and time when this password will expire, in the format defined by RFC3339. + // Null if it never expires. + // Example: `2016-08-25T21:10:29.600Z` + TimeExpires *common.SDKTime `mandatory:"false" json:"timeExpires"` + + // The secret key's current state. After creating a secret key, make sure its `lifecycleState` changes from + // CREATING to ACTIVE before using it. + LifecycleState CustomerSecretKeySummaryLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` +} + +func (m CustomerSecretKeySummary) String() string { + return common.PointerString(m) +} + +// CustomerSecretKeySummaryLifecycleStateEnum Enum with underlying type: string +type CustomerSecretKeySummaryLifecycleStateEnum string + +// Set of constants representing the allowable values for CustomerSecretKeySummaryLifecycleStateEnum +const ( + CustomerSecretKeySummaryLifecycleStateCreating CustomerSecretKeySummaryLifecycleStateEnum = "CREATING" + CustomerSecretKeySummaryLifecycleStateActive CustomerSecretKeySummaryLifecycleStateEnum = "ACTIVE" + CustomerSecretKeySummaryLifecycleStateInactive CustomerSecretKeySummaryLifecycleStateEnum = "INACTIVE" + CustomerSecretKeySummaryLifecycleStateDeleting CustomerSecretKeySummaryLifecycleStateEnum = "DELETING" + CustomerSecretKeySummaryLifecycleStateDeleted CustomerSecretKeySummaryLifecycleStateEnum = "DELETED" +) + +var mappingCustomerSecretKeySummaryLifecycleState = map[string]CustomerSecretKeySummaryLifecycleStateEnum{ + "CREATING": CustomerSecretKeySummaryLifecycleStateCreating, + "ACTIVE": CustomerSecretKeySummaryLifecycleStateActive, + "INACTIVE": CustomerSecretKeySummaryLifecycleStateInactive, + "DELETING": CustomerSecretKeySummaryLifecycleStateDeleting, + "DELETED": CustomerSecretKeySummaryLifecycleStateDeleted, +} + +// GetCustomerSecretKeySummaryLifecycleStateEnumValues Enumerates the set of values for CustomerSecretKeySummaryLifecycleStateEnum +func GetCustomerSecretKeySummaryLifecycleStateEnumValues() []CustomerSecretKeySummaryLifecycleStateEnum { + values := make([]CustomerSecretKeySummaryLifecycleStateEnum, 0) + for _, v := range mappingCustomerSecretKeySummaryLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/db_credential.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/db_credential.go new file mode 100644 index 000000000..2d1c454f5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/db_credential.go @@ -0,0 +1,72 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DbCredential Database credentials are needed for onboarding cloud database to identity. +// The DB credentials are used for DB authentication with the service. +type DbCredential struct { + + // The OCID of the DB credential. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the user the DB credential belongs to. + UserId *string `mandatory:"false" json:"userId"` + + // Date and time the `DbCredential` object was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // Date and time when this credential will expire, in the format defined by RFC3339. + // Null if it never expires. + // Example: `2016-08-25T21:10:29.600Z` + TimeExpires *common.SDKTime `mandatory:"false" json:"timeExpires"` + + // The credential's current state. After creating a DB credential, make sure its `lifecycleState` changes from + // CREATING to ACTIVE before using it. + LifecycleState DbCredentialLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The detailed status of INACTIVE lifecycleState. + LifecycleDetails *int64 `mandatory:"false" json:"lifecycleDetails"` +} + +func (m DbCredential) String() string { + return common.PointerString(m) +} + +// DbCredentialLifecycleStateEnum Enum with underlying type: string +type DbCredentialLifecycleStateEnum string + +// Set of constants representing the allowable values for DbCredentialLifecycleStateEnum +const ( + DbCredentialLifecycleStateCreating DbCredentialLifecycleStateEnum = "CREATING" + DbCredentialLifecycleStateActive DbCredentialLifecycleStateEnum = "ACTIVE" + DbCredentialLifecycleStateDeleting DbCredentialLifecycleStateEnum = "DELETING" + DbCredentialLifecycleStateDeleted DbCredentialLifecycleStateEnum = "DELETED" +) + +var mappingDbCredentialLifecycleState = map[string]DbCredentialLifecycleStateEnum{ + "CREATING": DbCredentialLifecycleStateCreating, + "ACTIVE": DbCredentialLifecycleStateActive, + "DELETING": DbCredentialLifecycleStateDeleting, + "DELETED": DbCredentialLifecycleStateDeleted, +} + +// GetDbCredentialLifecycleStateEnumValues Enumerates the set of values for DbCredentialLifecycleStateEnum +func GetDbCredentialLifecycleStateEnumValues() []DbCredentialLifecycleStateEnum { + values := make([]DbCredentialLifecycleStateEnum, 0) + for _, v := range mappingDbCredentialLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/db_credential_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/db_credential_summary.go new file mode 100644 index 000000000..e7b0eefa6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/db_credential_summary.go @@ -0,0 +1,46 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DbCredentialSummary As the name suggests, an `DbCredentialSummary` object contains information about an `DbCredential`. +// The DB credential is used for DB authentication with +// the [DB Service]. +type DbCredentialSummary struct { + + // The OCID of the DB credential. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the user the DB credential belongs to. + UserId *string `mandatory:"false" json:"userId"` + + // The description you assign to the DB credential. Does not have to be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` + + // Date and time the `DbCredential` object was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // Date and time when this credential will expire, in the format defined by RFC3339. + // Null if it never expires. + // Example: `2016-08-25T21:10:29.600Z` + TimeExpires *common.SDKTime `mandatory:"false" json:"timeExpires"` + + // The credential's current state. After creating a DB credential, make sure its `lifecycleState` changes from + // CREATING to ACTIVE before using it. + LifecycleState DbCredentialLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` +} + +func (m DbCredentialSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/deactivate_domain_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/deactivate_domain_request_response.go new file mode 100644 index 000000000..27ef1cebb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/deactivate_domain_request_response.go @@ -0,0 +1,86 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeactivateDomainRequest wrapper for the DeactivateDomain operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeactivateDomain.go.html to see an example of how to use DeactivateDomainRequest. +type DeactivateDomainRequest struct { + + // The OCID of the domain + DomainId *string `mandatory:"true" contributesTo:"path" name:"domainId"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeactivateDomainRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeactivateDomainRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeactivateDomainRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeactivateDomainRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeactivateDomainResponse wrapper for the DeactivateDomain operation +type DeactivateDomainResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response DeactivateDomainResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeactivateDomainResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/default_tag_definition_validator.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/default_tag_definition_validator.go new file mode 100644 index 000000000..fde99225e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/default_tag_definition_validator.go @@ -0,0 +1,39 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DefaultTagDefinitionValidator Use this validator to clear any existing validator on the tag key definition with the UpdateTag +// operation. Using this `validatorType` is the same as not setting any value on the validator field. +// The resultant value for `validatorType` returned in the response body is `null`. +type DefaultTagDefinitionValidator struct { +} + +func (m DefaultTagDefinitionValidator) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m DefaultTagDefinitionValidator) MarshalJSON() (buff []byte, e error) { + type MarshalTypeDefaultTagDefinitionValidator DefaultTagDefinitionValidator + s := struct { + DiscriminatorParam string `json:"validatorType"` + MarshalTypeDefaultTagDefinitionValidator + }{ + "DEFAULT", + (MarshalTypeDefaultTagDefinitionValidator)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_api_key_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_api_key_request_response.go new file mode 100644 index 000000000..f08d61738 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_api_key_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteApiKeyRequest wrapper for the DeleteApiKey operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteApiKey.go.html to see an example of how to use DeleteApiKeyRequest. +type DeleteApiKeyRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The key's fingerprint. + Fingerprint *string `mandatory:"true" contributesTo:"path" name:"fingerprint"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteApiKeyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteApiKeyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteApiKeyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteApiKeyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteApiKeyResponse wrapper for the DeleteApiKey operation +type DeleteApiKeyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteApiKeyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteApiKeyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_auth_token_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_auth_token_request_response.go new file mode 100644 index 000000000..64a6c6d9b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_auth_token_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteAuthTokenRequest wrapper for the DeleteAuthToken operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteAuthToken.go.html to see an example of how to use DeleteAuthTokenRequest. +type DeleteAuthTokenRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The OCID of the auth token. + AuthTokenId *string `mandatory:"true" contributesTo:"path" name:"authTokenId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteAuthTokenRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteAuthTokenRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteAuthTokenRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteAuthTokenRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteAuthTokenResponse wrapper for the DeleteAuthToken operation +type DeleteAuthTokenResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteAuthTokenResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteAuthTokenResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_compartment_request_response.go new file mode 100644 index 000000000..3c4971740 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_compartment_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteCompartmentRequest wrapper for the DeleteCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteCompartment.go.html to see an example of how to use DeleteCompartmentRequest. +type DeleteCompartmentRequest struct { + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"path" name:"compartmentId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteCompartmentResponse wrapper for the DeleteCompartment operation +type DeleteCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response DeleteCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_customer_secret_key_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_customer_secret_key_request_response.go new file mode 100644 index 000000000..11fbf7491 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_customer_secret_key_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteCustomerSecretKeyRequest wrapper for the DeleteCustomerSecretKey operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteCustomerSecretKey.go.html to see an example of how to use DeleteCustomerSecretKeyRequest. +type DeleteCustomerSecretKeyRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The OCID of the secret key. + CustomerSecretKeyId *string `mandatory:"true" contributesTo:"path" name:"customerSecretKeyId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteCustomerSecretKeyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteCustomerSecretKeyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteCustomerSecretKeyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteCustomerSecretKeyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteCustomerSecretKeyResponse wrapper for the DeleteCustomerSecretKey operation +type DeleteCustomerSecretKeyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteCustomerSecretKeyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteCustomerSecretKeyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_db_credential_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_db_credential_request_response.go new file mode 100644 index 000000000..abc08a8cb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_db_credential_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteDbCredentialRequest wrapper for the DeleteDbCredential operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteDbCredential.go.html to see an example of how to use DeleteDbCredentialRequest. +type DeleteDbCredentialRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The OCID of the DB credential. + DbCredentialId *string `mandatory:"true" contributesTo:"path" name:"dbCredentialId"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteDbCredentialRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteDbCredentialRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteDbCredentialRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteDbCredentialRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteDbCredentialResponse wrapper for the DeleteDbCredential operation +type DeleteDbCredentialResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteDbCredentialResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteDbCredentialResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_domain_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_domain_request_response.go new file mode 100644 index 000000000..625e85e87 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_domain_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteDomainRequest wrapper for the DeleteDomain operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteDomain.go.html to see an example of how to use DeleteDomainRequest. +type DeleteDomainRequest struct { + + // The OCID of the domain + DomainId *string `mandatory:"true" contributesTo:"path" name:"domainId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteDomainRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteDomainRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteDomainRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteDomainRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteDomainResponse wrapper for the DeleteDomain operation +type DeleteDomainResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response DeleteDomainResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteDomainResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_dynamic_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_dynamic_group_request_response.go new file mode 100644 index 000000000..6eb33cfc1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_dynamic_group_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteDynamicGroupRequest wrapper for the DeleteDynamicGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteDynamicGroup.go.html to see an example of how to use DeleteDynamicGroupRequest. +type DeleteDynamicGroupRequest struct { + + // The OCID of the dynamic group. + DynamicGroupId *string `mandatory:"true" contributesTo:"path" name:"dynamicGroupId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteDynamicGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteDynamicGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteDynamicGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteDynamicGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteDynamicGroupResponse wrapper for the DeleteDynamicGroup operation +type DeleteDynamicGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteDynamicGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteDynamicGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_group_request_response.go new file mode 100644 index 000000000..01f63aa7c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_group_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteGroupRequest wrapper for the DeleteGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteGroup.go.html to see an example of how to use DeleteGroupRequest. +type DeleteGroupRequest struct { + + // The OCID of the group. + GroupId *string `mandatory:"true" contributesTo:"path" name:"groupId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteGroupResponse wrapper for the DeleteGroup operation +type DeleteGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_identity_provider_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_identity_provider_request_response.go new file mode 100644 index 000000000..f97b81907 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_identity_provider_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteIdentityProviderRequest wrapper for the DeleteIdentityProvider operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteIdentityProvider.go.html to see an example of how to use DeleteIdentityProviderRequest. +type DeleteIdentityProviderRequest struct { + + // The OCID of the identity provider. + IdentityProviderId *string `mandatory:"true" contributesTo:"path" name:"identityProviderId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteIdentityProviderRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteIdentityProviderRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteIdentityProviderRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteIdentityProviderRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteIdentityProviderResponse wrapper for the DeleteIdentityProvider operation +type DeleteIdentityProviderResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteIdentityProviderResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteIdentityProviderResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_idp_group_mapping_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_idp_group_mapping_request_response.go new file mode 100644 index 000000000..e902be818 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_idp_group_mapping_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteIdpGroupMappingRequest wrapper for the DeleteIdpGroupMapping operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteIdpGroupMapping.go.html to see an example of how to use DeleteIdpGroupMappingRequest. +type DeleteIdpGroupMappingRequest struct { + + // The OCID of the identity provider. + IdentityProviderId *string `mandatory:"true" contributesTo:"path" name:"identityProviderId"` + + // The OCID of the group mapping. + MappingId *string `mandatory:"true" contributesTo:"path" name:"mappingId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteIdpGroupMappingRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteIdpGroupMappingRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteIdpGroupMappingRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteIdpGroupMappingRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteIdpGroupMappingResponse wrapper for the DeleteIdpGroupMapping operation +type DeleteIdpGroupMappingResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteIdpGroupMappingResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteIdpGroupMappingResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_mfa_totp_device_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_mfa_totp_device_request_response.go new file mode 100644 index 000000000..af18d1041 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_mfa_totp_device_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteMfaTotpDeviceRequest wrapper for the DeleteMfaTotpDevice operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteMfaTotpDevice.go.html to see an example of how to use DeleteMfaTotpDeviceRequest. +type DeleteMfaTotpDeviceRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The OCID of the MFA TOTP device. + MfaTotpDeviceId *string `mandatory:"true" contributesTo:"path" name:"mfaTotpDeviceId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteMfaTotpDeviceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteMfaTotpDeviceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteMfaTotpDeviceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteMfaTotpDeviceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteMfaTotpDeviceResponse wrapper for the DeleteMfaTotpDevice operation +type DeleteMfaTotpDeviceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteMfaTotpDeviceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteMfaTotpDeviceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_network_source_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_network_source_request_response.go new file mode 100644 index 000000000..a695e1869 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_network_source_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteNetworkSourceRequest wrapper for the DeleteNetworkSource operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteNetworkSource.go.html to see an example of how to use DeleteNetworkSourceRequest. +type DeleteNetworkSourceRequest struct { + + // The OCID of the network source. + NetworkSourceId *string `mandatory:"true" contributesTo:"path" name:"networkSourceId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteNetworkSourceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteNetworkSourceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteNetworkSourceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteNetworkSourceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteNetworkSourceResponse wrapper for the DeleteNetworkSource operation +type DeleteNetworkSourceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteNetworkSourceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteNetworkSourceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_o_auth_client_credential_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_o_auth_client_credential_request_response.go new file mode 100644 index 000000000..28c51f5c6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_o_auth_client_credential_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteOAuthClientCredentialRequest wrapper for the DeleteOAuthClientCredential operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteOAuthClientCredential.go.html to see an example of how to use DeleteOAuthClientCredentialRequest. +type DeleteOAuthClientCredentialRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The ID of the Oauth credential. + Oauth2ClientCredentialId *string `mandatory:"true" contributesTo:"path" name:"oauth2ClientCredentialId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteOAuthClientCredentialRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteOAuthClientCredentialRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteOAuthClientCredentialRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteOAuthClientCredentialRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteOAuthClientCredentialResponse wrapper for the DeleteOAuthClientCredential operation +type DeleteOAuthClientCredentialResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteOAuthClientCredentialResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteOAuthClientCredentialResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_policy_request_response.go new file mode 100644 index 000000000..0d4c5039d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_policy_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeletePolicyRequest wrapper for the DeletePolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeletePolicy.go.html to see an example of how to use DeletePolicyRequest. +type DeletePolicyRequest struct { + + // The OCID of the policy. + PolicyId *string `mandatory:"true" contributesTo:"path" name:"policyId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeletePolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeletePolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeletePolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeletePolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeletePolicyResponse wrapper for the DeletePolicy operation +type DeletePolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeletePolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeletePolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_smtp_credential_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_smtp_credential_request_response.go new file mode 100644 index 000000000..360cce775 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_smtp_credential_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteSmtpCredentialRequest wrapper for the DeleteSmtpCredential operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteSmtpCredential.go.html to see an example of how to use DeleteSmtpCredentialRequest. +type DeleteSmtpCredentialRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The OCID of the SMTP credential. + SmtpCredentialId *string `mandatory:"true" contributesTo:"path" name:"smtpCredentialId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteSmtpCredentialRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteSmtpCredentialRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteSmtpCredentialRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteSmtpCredentialRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteSmtpCredentialResponse wrapper for the DeleteSmtpCredential operation +type DeleteSmtpCredentialResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteSmtpCredentialResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteSmtpCredentialResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_swift_password_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_swift_password_request_response.go new file mode 100644 index 000000000..c23e1d3b6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_swift_password_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteSwiftPasswordRequest wrapper for the DeleteSwiftPassword operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteSwiftPassword.go.html to see an example of how to use DeleteSwiftPasswordRequest. +type DeleteSwiftPasswordRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The OCID of the Swift password. + SwiftPasswordId *string `mandatory:"true" contributesTo:"path" name:"swiftPasswordId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteSwiftPasswordRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteSwiftPasswordRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteSwiftPasswordRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteSwiftPasswordRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteSwiftPasswordResponse wrapper for the DeleteSwiftPassword operation +type DeleteSwiftPasswordResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteSwiftPasswordResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteSwiftPasswordResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_tag_default_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_tag_default_request_response.go new file mode 100644 index 000000000..16fefe5ef --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_tag_default_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteTagDefaultRequest wrapper for the DeleteTagDefault operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteTagDefault.go.html to see an example of how to use DeleteTagDefaultRequest. +type DeleteTagDefaultRequest struct { + + // The OCID of the tag default. + TagDefaultId *string `mandatory:"true" contributesTo:"path" name:"tagDefaultId"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteTagDefaultRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteTagDefaultRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteTagDefaultRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteTagDefaultRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteTagDefaultResponse wrapper for the DeleteTagDefault operation +type DeleteTagDefaultResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteTagDefaultResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteTagDefaultResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_tag_namespace_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_tag_namespace_request_response.go new file mode 100644 index 000000000..8c174274a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_tag_namespace_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteTagNamespaceRequest wrapper for the DeleteTagNamespace operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteTagNamespace.go.html to see an example of how to use DeleteTagNamespaceRequest. +type DeleteTagNamespaceRequest struct { + + // The OCID of the tag namespace. + TagNamespaceId *string `mandatory:"true" contributesTo:"path" name:"tagNamespaceId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteTagNamespaceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteTagNamespaceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteTagNamespaceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteTagNamespaceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteTagNamespaceResponse wrapper for the DeleteTagNamespace operation +type DeleteTagNamespaceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteTagNamespaceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteTagNamespaceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_tag_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_tag_request_response.go new file mode 100644 index 000000000..5a65ebe9a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_tag_request_response.go @@ -0,0 +1,82 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteTagRequest wrapper for the DeleteTag operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteTag.go.html to see an example of how to use DeleteTagRequest. +type DeleteTagRequest struct { + + // The OCID of the tag namespace. + TagNamespaceId *string `mandatory:"true" contributesTo:"path" name:"tagNamespaceId"` + + // The name of the tag. + TagName *string `mandatory:"true" contributesTo:"path" name:"tagName"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteTagRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteTagRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteTagRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteTagRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteTagResponse wrapper for the DeleteTag operation +type DeleteTagResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response DeleteTagResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteTagResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_user_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_user_request_response.go new file mode 100644 index 000000000..b377d227d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/delete_user_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteUserRequest wrapper for the DeleteUser operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteUser.go.html to see an example of how to use DeleteUserRequest. +type DeleteUserRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteUserRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteUserRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteUserRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteUserRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteUserResponse wrapper for the DeleteUser operation +type DeleteUserResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteUserResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteUserResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/domain.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/domain.go new file mode 100644 index 000000000..3ef273297 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/domain.go @@ -0,0 +1,153 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Domain Properties for a Domain +type Domain struct { + + // The OCID of the domain + Id *string `mandatory:"true" json:"id"` + + // The OCID of the compartment containing the domain. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The mutable display name of the domain + DisplayName *string `mandatory:"true" json:"displayName"` + + // The domain descripition + Description *string `mandatory:"true" json:"description"` + + // Region agnostic domain URL. + Url *string `mandatory:"true" json:"url"` + + // Region specific domain URL. + HomeRegionUrl *string `mandatory:"true" json:"homeRegionUrl"` + + // The home region for the domain. + // See Regions and Availability Domains (https://docs.cloud.oracle.com/Content/General/Concepts/regions.htm) + // for the full list of supported region names. + // Example: `us-phoenix-1` + HomeRegion *string `mandatory:"true" json:"homeRegion"` + + // The regions domain is replication to. + ReplicaRegions []ReplicatedRegionDetails `mandatory:"true" json:"replicaRegions"` + + // The type of the domain. + Type DomainTypeEnum `mandatory:"true" json:"type"` + + // The License type of Domain + LicenseType *string `mandatory:"true" json:"licenseType"` + + // Indicates whether domain is hidden on login screen or not. + IsHiddenOnLogin *bool `mandatory:"true" json:"isHiddenOnLogin"` + + // Date and time the domain was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The current state. + LifecycleState DomainLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // Any additional details about the current state of the Domain. + LifecycleDetails DomainLifecycleDetailsEnum `mandatory:"false" json:"lifecycleDetails,omitempty"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m Domain) String() string { + return common.PointerString(m) +} + +// DomainTypeEnum Enum with underlying type: string +type DomainTypeEnum string + +// Set of constants representing the allowable values for DomainTypeEnum +const ( + DomainTypeDefault DomainTypeEnum = "DEFAULT" + DomainTypeSecondary DomainTypeEnum = "SECONDARY" +) + +var mappingDomainType = map[string]DomainTypeEnum{ + "DEFAULT": DomainTypeDefault, + "SECONDARY": DomainTypeSecondary, +} + +// GetDomainTypeEnumValues Enumerates the set of values for DomainTypeEnum +func GetDomainTypeEnumValues() []DomainTypeEnum { + values := make([]DomainTypeEnum, 0) + for _, v := range mappingDomainType { + values = append(values, v) + } + return values +} + +// DomainLifecycleStateEnum Enum with underlying type: string +type DomainLifecycleStateEnum string + +// Set of constants representing the allowable values for DomainLifecycleStateEnum +const ( + DomainLifecycleStateCreating DomainLifecycleStateEnum = "CREATING" + DomainLifecycleStateActive DomainLifecycleStateEnum = "ACTIVE" + DomainLifecycleStateDeleting DomainLifecycleStateEnum = "DELETING" + DomainLifecycleStateInactive DomainLifecycleStateEnum = "INACTIVE" +) + +var mappingDomainLifecycleState = map[string]DomainLifecycleStateEnum{ + "CREATING": DomainLifecycleStateCreating, + "ACTIVE": DomainLifecycleStateActive, + "DELETING": DomainLifecycleStateDeleting, + "INACTIVE": DomainLifecycleStateInactive, +} + +// GetDomainLifecycleStateEnumValues Enumerates the set of values for DomainLifecycleStateEnum +func GetDomainLifecycleStateEnumValues() []DomainLifecycleStateEnum { + values := make([]DomainLifecycleStateEnum, 0) + for _, v := range mappingDomainLifecycleState { + values = append(values, v) + } + return values +} + +// DomainLifecycleDetailsEnum Enum with underlying type: string +type DomainLifecycleDetailsEnum string + +// Set of constants representing the allowable values for DomainLifecycleDetailsEnum +const ( + DomainLifecycleDetailsDeactivating DomainLifecycleDetailsEnum = "DEACTIVATING" + DomainLifecycleDetailsActivating DomainLifecycleDetailsEnum = "ACTIVATING" + DomainLifecycleDetailsUpdating DomainLifecycleDetailsEnum = "UPDATING" +) + +var mappingDomainLifecycleDetails = map[string]DomainLifecycleDetailsEnum{ + "DEACTIVATING": DomainLifecycleDetailsDeactivating, + "ACTIVATING": DomainLifecycleDetailsActivating, + "UPDATING": DomainLifecycleDetailsUpdating, +} + +// GetDomainLifecycleDetailsEnumValues Enumerates the set of values for DomainLifecycleDetailsEnum +func GetDomainLifecycleDetailsEnumValues() []DomainLifecycleDetailsEnum { + values := make([]DomainLifecycleDetailsEnum, 0) + for _, v := range mappingDomainLifecycleDetails { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/domain_replication.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/domain_replication.go new file mode 100644 index 000000000..7e13f5651 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/domain_replication.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DomainReplication Domain replication states. +type DomainReplication struct { + + // Version number indicating the value of kievTxnId, starting from which, the domain replication events need to be returned. + OpcWaterMark *float32 `mandatory:"true" json:"opcWaterMark"` + + // Custom value defining the order of records with same kievTxnId + TxnSeqNumber *float32 `mandatory:"true" json:"txnSeqNumber"` + + // The domain's replication state + DomainReplicationStates []DomainReplicationStates `mandatory:"true" json:"domainReplicationStates"` +} + +func (m DomainReplication) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/domain_replication_states.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/domain_replication_states.go new file mode 100644 index 000000000..2925cefeb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/domain_replication_states.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DomainReplicationStates Domain replication replication log for all domains for a given region +type DomainReplicationStates struct { + + // The OCID of the domain + DomainId *string `mandatory:"true" json:"domainId"` + + // The IDCS replicated region state + State ReplicatedRegionDetailsStateEnum `mandatory:"true" json:"state"` + + // The replica region for domain. + ReplicaRegion *string `mandatory:"true" json:"replicaRegion"` +} + +func (m DomainReplicationStates) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/domain_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/domain_summary.go new file mode 100644 index 000000000..bba8b70d2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/domain_summary.go @@ -0,0 +1,100 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DomainSummary As the name suggests, a `DomainSummary` object contains information about a `Domain`. +type DomainSummary struct { + + // The OCID of the domain + Id *string `mandatory:"true" json:"id"` + + // The OCID of the comparment containing the domain. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The mutable display name of the domain + DisplayName *string `mandatory:"true" json:"displayName"` + + // The domain descripition + Description *string `mandatory:"true" json:"description"` + + // Region agnostic domain URL. + Url *string `mandatory:"true" json:"url"` + + // Region specific domain URL. + HomeRegionUrl *string `mandatory:"true" json:"homeRegionUrl"` + + // The home region for the domain. + HomeRegion *string `mandatory:"true" json:"homeRegion"` + + // The regions domain is replicated to. + ReplicaRegions []ReplicatedRegionDetails `mandatory:"true" json:"replicaRegions"` + + // The type of the domain. + Type DomainTypeEnum `mandatory:"true" json:"type"` + + // The License type of Domain + LicenseType *string `mandatory:"true" json:"licenseType"` + + // Indicates whether domain is hidden on login screen or not. + IsHiddenOnLogin *bool `mandatory:"true" json:"isHiddenOnLogin"` + + // Date and time the domain was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The current state. + LifecycleState DomainLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // Any additional details about the current state of the Domain. + LifecycleDetails DomainSummaryLifecycleDetailsEnum `mandatory:"false" json:"lifecycleDetails,omitempty"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m DomainSummary) String() string { + return common.PointerString(m) +} + +// DomainSummaryLifecycleDetailsEnum Enum with underlying type: string +type DomainSummaryLifecycleDetailsEnum string + +// Set of constants representing the allowable values for DomainSummaryLifecycleDetailsEnum +const ( + DomainSummaryLifecycleDetailsDeactivating DomainSummaryLifecycleDetailsEnum = "DEACTIVATING" + DomainSummaryLifecycleDetailsActivating DomainSummaryLifecycleDetailsEnum = "ACTIVATING" + DomainSummaryLifecycleDetailsUpdating DomainSummaryLifecycleDetailsEnum = "UPDATING" +) + +var mappingDomainSummaryLifecycleDetails = map[string]DomainSummaryLifecycleDetailsEnum{ + "DEACTIVATING": DomainSummaryLifecycleDetailsDeactivating, + "ACTIVATING": DomainSummaryLifecycleDetailsActivating, + "UPDATING": DomainSummaryLifecycleDetailsUpdating, +} + +// GetDomainSummaryLifecycleDetailsEnumValues Enumerates the set of values for DomainSummaryLifecycleDetailsEnum +func GetDomainSummaryLifecycleDetailsEnumValues() []DomainSummaryLifecycleDetailsEnum { + values := make([]DomainSummaryLifecycleDetailsEnum, 0) + for _, v := range mappingDomainSummaryLifecycleDetails { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/dynamic_group.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/dynamic_group.go new file mode 100644 index 000000000..93bada0f8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/dynamic_group.go @@ -0,0 +1,98 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// DynamicGroup A dynamic group defines a matching rule. Every bare metal or virtual machine instance is deployed with an instance certificate. +// The certificate contains metadata about the instance. This includes the instance OCID and the compartment OCID, along +// with a few other optional properties. When an API call is made using this instance certificate as the authenticator, +// the certificate can be matched to one or multiple dynamic groups. The instance can then get access to the API +// based on the permissions granted in policies written for the dynamic groups. +// This works like regular user/group membership. But in that case, the membership is a static relationship, whereas +// in a dynamic group, the membership of an instance certificate to a dynamic group is determined during runtime. +// For more information, see Managing Dynamic Groups (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingdynamicgroups.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you supply string values using +// the API. +type DynamicGroup struct { + + // The OCID of the group. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the tenancy containing the group. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name you assign to the group during creation. The name must be unique across all groups in + // the tenancy and cannot be changed. + Name *string `mandatory:"true" json:"name"` + + // The description you assign to the group. Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` + + // A rule string that defines which instance certificates will be matched. + // For syntax, see Managing Dynamic Groups (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingdynamicgroups.htm). + MatchingRule *string `mandatory:"true" json:"matchingRule"` + + // Date and time the group was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The group's current state. After creating a group, make sure its `lifecycleState` changes from CREATING to + // ACTIVE before using it. + LifecycleState DynamicGroupLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m DynamicGroup) String() string { + return common.PointerString(m) +} + +// DynamicGroupLifecycleStateEnum Enum with underlying type: string +type DynamicGroupLifecycleStateEnum string + +// Set of constants representing the allowable values for DynamicGroupLifecycleStateEnum +const ( + DynamicGroupLifecycleStateCreating DynamicGroupLifecycleStateEnum = "CREATING" + DynamicGroupLifecycleStateActive DynamicGroupLifecycleStateEnum = "ACTIVE" + DynamicGroupLifecycleStateInactive DynamicGroupLifecycleStateEnum = "INACTIVE" + DynamicGroupLifecycleStateDeleting DynamicGroupLifecycleStateEnum = "DELETING" + DynamicGroupLifecycleStateDeleted DynamicGroupLifecycleStateEnum = "DELETED" +) + +var mappingDynamicGroupLifecycleState = map[string]DynamicGroupLifecycleStateEnum{ + "CREATING": DynamicGroupLifecycleStateCreating, + "ACTIVE": DynamicGroupLifecycleStateActive, + "INACTIVE": DynamicGroupLifecycleStateInactive, + "DELETING": DynamicGroupLifecycleStateDeleting, + "DELETED": DynamicGroupLifecycleStateDeleted, +} + +// GetDynamicGroupLifecycleStateEnumValues Enumerates the set of values for DynamicGroupLifecycleStateEnum +func GetDynamicGroupLifecycleStateEnumValues() []DynamicGroupLifecycleStateEnum { + values := make([]DynamicGroupLifecycleStateEnum, 0) + for _, v := range mappingDynamicGroupLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/enable_replication_to_region_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/enable_replication_to_region_details.go new file mode 100644 index 000000000..bc37135b0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/enable_replication_to_region_details.go @@ -0,0 +1,28 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// EnableReplicationToRegionDetails Domain replication request packet +type EnableReplicationToRegionDetails struct { + + // A region for which domain replication is requested for. + // See Regions and Availability Domains (https://docs.cloud.oracle.com/Content/General/Concepts/regions.htm) + // for the full list of supported region names. + // Example: `us-phoenix-1` + ReplicaRegion *string `mandatory:"false" json:"replicaRegion"` +} + +func (m EnableReplicationToRegionDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/enable_replication_to_region_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/enable_replication_to_region_request_response.go new file mode 100644 index 000000000..b403c3a8f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/enable_replication_to_region_request_response.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// EnableReplicationToRegionRequest wrapper for the EnableReplicationToRegion operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/EnableReplicationToRegion.go.html to see an example of how to use EnableReplicationToRegionRequest. +type EnableReplicationToRegionRequest struct { + + // The OCID of the domain + DomainId *string `mandatory:"true" contributesTo:"path" name:"domainId"` + + // the request object for region we are replicating domain region + EnableReplicationToRegionDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request EnableReplicationToRegionRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request EnableReplicationToRegionRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request EnableReplicationToRegionRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request EnableReplicationToRegionRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// EnableReplicationToRegionResponse wrapper for the EnableReplicationToRegion operation +type EnableReplicationToRegionResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response EnableReplicationToRegionResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response EnableReplicationToRegionResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/enum_tag_definition_validator.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/enum_tag_definition_validator.go new file mode 100644 index 000000000..aaaa72dbb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/enum_tag_definition_validator.go @@ -0,0 +1,42 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// EnumTagDefinitionValidator Used to validate the value set for a defined tag and contains the list of allowable `values`. +// You must specify at least one valid value in the `values` array. You can't have blank or +// or empty strings (`""`). Duplicate values are not allowed. +type EnumTagDefinitionValidator struct { + + // The list of allowed values for a definedTag value. + Values []string `mandatory:"false" json:"values"` +} + +func (m EnumTagDefinitionValidator) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m EnumTagDefinitionValidator) MarshalJSON() (buff []byte, e error) { + type MarshalTypeEnumTagDefinitionValidator EnumTagDefinitionValidator + s := struct { + DiscriminatorParam string `json:"validatorType"` + MarshalTypeEnumTagDefinitionValidator + }{ + "ENUM", + (MarshalTypeEnumTagDefinitionValidator)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/fault_domain.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/fault_domain.go new file mode 100644 index 000000000..10293327c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/fault_domain.go @@ -0,0 +1,36 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// FaultDomain A Fault Domain is a logical grouping of hardware and infrastructure within an Availability Domain that can become +// unavailable in its entirety either due to hardware failure such as Top-of-rack (TOR) switch failure or due to +// planned software maintenance such as security updates that reboot your instances. +type FaultDomain struct { + + // The name of the Fault Domain. + Name *string `mandatory:"false" json:"name"` + + // The OCID of the Fault Domain. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the compartment. Currently only tenancy (root) compartment can be provided. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The name of the availabilityDomain where the Fault Domain belongs. + AvailabilityDomain *string `mandatory:"false" json:"availabilityDomain"` +} + +func (m FaultDomain) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/fully_qualified_scope.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/fully_qualified_scope.go new file mode 100644 index 000000000..a98c0d059 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/fully_qualified_scope.go @@ -0,0 +1,28 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// FullyQualifiedScope The representation of FullyQualifiedScope +type FullyQualifiedScope struct { + + // Audience for the given scope context. + Audience *string `mandatory:"true" json:"audience"` + + // Allowed permission scope for the given context. + Scope *string `mandatory:"true" json:"scope"` +} + +func (m FullyQualifiedScope) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/generate_totp_seed_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/generate_totp_seed_request_response.go new file mode 100644 index 000000000..c60fcd50d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/generate_totp_seed_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GenerateTotpSeedRequest wrapper for the GenerateTotpSeed operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GenerateTotpSeed.go.html to see an example of how to use GenerateTotpSeedRequest. +type GenerateTotpSeedRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The OCID of the MFA TOTP device. + MfaTotpDeviceId *string `mandatory:"true" contributesTo:"path" name:"mfaTotpDeviceId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GenerateTotpSeedRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GenerateTotpSeedRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GenerateTotpSeedRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GenerateTotpSeedRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GenerateTotpSeedResponse wrapper for the GenerateTotpSeed operation +type GenerateTotpSeedResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The MfaTotpDevice instance + MfaTotpDevice `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GenerateTotpSeedResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GenerateTotpSeedResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_authentication_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_authentication_policy_request_response.go new file mode 100644 index 000000000..f8c063958 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_authentication_policy_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetAuthenticationPolicyRequest wrapper for the GetAuthenticationPolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetAuthenticationPolicy.go.html to see an example of how to use GetAuthenticationPolicyRequest. +type GetAuthenticationPolicyRequest struct { + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"path" name:"compartmentId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetAuthenticationPolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetAuthenticationPolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetAuthenticationPolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetAuthenticationPolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetAuthenticationPolicyResponse wrapper for the GetAuthenticationPolicy operation +type GetAuthenticationPolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The AuthenticationPolicy instance + AuthenticationPolicy `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GetAuthenticationPolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetAuthenticationPolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_compartment_request_response.go new file mode 100644 index 000000000..178b18792 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_compartment_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetCompartmentRequest wrapper for the GetCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetCompartment.go.html to see an example of how to use GetCompartmentRequest. +type GetCompartmentRequest struct { + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"path" name:"compartmentId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetCompartmentResponse wrapper for the GetCompartment operation +type GetCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Compartment instance + Compartment `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GetCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_domain_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_domain_request_response.go new file mode 100644 index 000000000..a516e1072 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_domain_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetDomainRequest wrapper for the GetDomain operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetDomain.go.html to see an example of how to use GetDomainRequest. +type GetDomainRequest struct { + + // The OCID of the domain + DomainId *string `mandatory:"true" contributesTo:"path" name:"domainId"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetDomainRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetDomainRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetDomainRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetDomainRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetDomainResponse wrapper for the GetDomain operation +type GetDomainResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Domain instance + Domain `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GetDomainResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetDomainResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_dynamic_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_dynamic_group_request_response.go new file mode 100644 index 000000000..f474dd4a3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_dynamic_group_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetDynamicGroupRequest wrapper for the GetDynamicGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetDynamicGroup.go.html to see an example of how to use GetDynamicGroupRequest. +type GetDynamicGroupRequest struct { + + // The OCID of the dynamic group. + DynamicGroupId *string `mandatory:"true" contributesTo:"path" name:"dynamicGroupId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetDynamicGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetDynamicGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetDynamicGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetDynamicGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetDynamicGroupResponse wrapper for the GetDynamicGroup operation +type GetDynamicGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DynamicGroup instance + DynamicGroup `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GetDynamicGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetDynamicGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_group_request_response.go new file mode 100644 index 000000000..70d52bbdf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_group_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetGroupRequest wrapper for the GetGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetGroup.go.html to see an example of how to use GetGroupRequest. +type GetGroupRequest struct { + + // The OCID of the group. + GroupId *string `mandatory:"true" contributesTo:"path" name:"groupId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetGroupResponse wrapper for the GetGroup operation +type GetGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Group instance + Group `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GetGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_iam_work_request_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_iam_work_request_request_response.go new file mode 100644 index 000000000..1d9d5820e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_iam_work_request_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetIamWorkRequestRequest wrapper for the GetIamWorkRequest operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetIamWorkRequest.go.html to see an example of how to use GetIamWorkRequestRequest. +type GetIamWorkRequestRequest struct { + + // The OCID of the IAM work request. + IamWorkRequestId *string `mandatory:"true" contributesTo:"path" name:"iamWorkRequestId"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetIamWorkRequestRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetIamWorkRequestRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetIamWorkRequestRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetIamWorkRequestRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetIamWorkRequestResponse wrapper for the GetIamWorkRequest operation +type GetIamWorkRequestResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IamWorkRequest instance + IamWorkRequest `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetIamWorkRequestResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetIamWorkRequestResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_identity_provider_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_identity_provider_request_response.go new file mode 100644 index 000000000..b6715103e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_identity_provider_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetIdentityProviderRequest wrapper for the GetIdentityProvider operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetIdentityProvider.go.html to see an example of how to use GetIdentityProviderRequest. +type GetIdentityProviderRequest struct { + + // The OCID of the identity provider. + IdentityProviderId *string `mandatory:"true" contributesTo:"path" name:"identityProviderId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetIdentityProviderRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetIdentityProviderRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetIdentityProviderRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetIdentityProviderRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetIdentityProviderResponse wrapper for the GetIdentityProvider operation +type GetIdentityProviderResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IdentityProvider instance + IdentityProvider `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GetIdentityProviderResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetIdentityProviderResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_idp_group_mapping_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_idp_group_mapping_request_response.go new file mode 100644 index 000000000..2bafaa975 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_idp_group_mapping_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetIdpGroupMappingRequest wrapper for the GetIdpGroupMapping operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetIdpGroupMapping.go.html to see an example of how to use GetIdpGroupMappingRequest. +type GetIdpGroupMappingRequest struct { + + // The OCID of the identity provider. + IdentityProviderId *string `mandatory:"true" contributesTo:"path" name:"identityProviderId"` + + // The OCID of the group mapping. + MappingId *string `mandatory:"true" contributesTo:"path" name:"mappingId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetIdpGroupMappingRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetIdpGroupMappingRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetIdpGroupMappingRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetIdpGroupMappingRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetIdpGroupMappingResponse wrapper for the GetIdpGroupMapping operation +type GetIdpGroupMappingResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IdpGroupMapping instance + IdpGroupMapping `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GetIdpGroupMappingResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetIdpGroupMappingResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_mfa_totp_device_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_mfa_totp_device_request_response.go new file mode 100644 index 000000000..8702e851a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_mfa_totp_device_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetMfaTotpDeviceRequest wrapper for the GetMfaTotpDevice operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetMfaTotpDevice.go.html to see an example of how to use GetMfaTotpDeviceRequest. +type GetMfaTotpDeviceRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The OCID of the MFA TOTP device. + MfaTotpDeviceId *string `mandatory:"true" contributesTo:"path" name:"mfaTotpDeviceId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetMfaTotpDeviceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetMfaTotpDeviceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetMfaTotpDeviceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetMfaTotpDeviceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetMfaTotpDeviceResponse wrapper for the GetMfaTotpDevice operation +type GetMfaTotpDeviceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The MfaTotpDeviceSummary instance + MfaTotpDeviceSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GetMfaTotpDeviceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetMfaTotpDeviceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_network_source_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_network_source_request_response.go new file mode 100644 index 000000000..e7dc5f8da --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_network_source_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetNetworkSourceRequest wrapper for the GetNetworkSource operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetNetworkSource.go.html to see an example of how to use GetNetworkSourceRequest. +type GetNetworkSourceRequest struct { + + // The OCID of the network source. + NetworkSourceId *string `mandatory:"true" contributesTo:"path" name:"networkSourceId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetNetworkSourceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetNetworkSourceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetNetworkSourceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetNetworkSourceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetNetworkSourceResponse wrapper for the GetNetworkSource operation +type GetNetworkSourceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The NetworkSources instance + NetworkSources `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GetNetworkSourceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetNetworkSourceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_policy_request_response.go new file mode 100644 index 000000000..d4fe09fbb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_policy_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetPolicyRequest wrapper for the GetPolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetPolicy.go.html to see an example of how to use GetPolicyRequest. +type GetPolicyRequest struct { + + // The OCID of the policy. + PolicyId *string `mandatory:"true" contributesTo:"path" name:"policyId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetPolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetPolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetPolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetPolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetPolicyResponse wrapper for the GetPolicy operation +type GetPolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Policy instance + Policy `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GetPolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetPolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_standard_tag_template_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_standard_tag_template_request_response.go new file mode 100644 index 000000000..50dc35bfe --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_standard_tag_template_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetStandardTagTemplateRequest wrapper for the GetStandardTagTemplate operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetStandardTagTemplate.go.html to see an example of how to use GetStandardTagTemplateRequest. +type GetStandardTagTemplateRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The name of the standard tag namespace tempate that is requested + StandardTagNamespaceName *string `mandatory:"true" contributesTo:"path" name:"standardTagNamespaceName"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetStandardTagTemplateRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetStandardTagTemplateRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetStandardTagTemplateRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetStandardTagTemplateRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetStandardTagTemplateResponse wrapper for the GetStandardTagTemplate operation +type GetStandardTagTemplateResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The StandardTagNamespaceTemplate instance + StandardTagNamespaceTemplate `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetStandardTagTemplateResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetStandardTagTemplateResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tag_default_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tag_default_request_response.go new file mode 100644 index 000000000..55510b191 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tag_default_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetTagDefaultRequest wrapper for the GetTagDefault operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetTagDefault.go.html to see an example of how to use GetTagDefaultRequest. +type GetTagDefaultRequest struct { + + // The OCID of the tag default. + TagDefaultId *string `mandatory:"true" contributesTo:"path" name:"tagDefaultId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetTagDefaultRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetTagDefaultRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetTagDefaultRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetTagDefaultRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetTagDefaultResponse wrapper for the GetTagDefault operation +type GetTagDefaultResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The TagDefault instance + TagDefault `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GetTagDefaultResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetTagDefaultResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tag_namespace_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tag_namespace_request_response.go new file mode 100644 index 000000000..3d9105245 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tag_namespace_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetTagNamespaceRequest wrapper for the GetTagNamespace operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetTagNamespace.go.html to see an example of how to use GetTagNamespaceRequest. +type GetTagNamespaceRequest struct { + + // The OCID of the tag namespace. + TagNamespaceId *string `mandatory:"true" contributesTo:"path" name:"tagNamespaceId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetTagNamespaceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetTagNamespaceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetTagNamespaceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetTagNamespaceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetTagNamespaceResponse wrapper for the GetTagNamespace operation +type GetTagNamespaceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The TagNamespace instance + TagNamespace `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetTagNamespaceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetTagNamespaceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tag_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tag_request_response.go new file mode 100644 index 000000000..e8bc84c64 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tag_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetTagRequest wrapper for the GetTag operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetTag.go.html to see an example of how to use GetTagRequest. +type GetTagRequest struct { + + // The OCID of the tag namespace. + TagNamespaceId *string `mandatory:"true" contributesTo:"path" name:"tagNamespaceId"` + + // The name of the tag. + TagName *string `mandatory:"true" contributesTo:"path" name:"tagName"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetTagRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetTagRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetTagRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetTagRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetTagResponse wrapper for the GetTag operation +type GetTagResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Tag instance + Tag `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GetTagResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetTagResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tagging_work_request_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tagging_work_request_request_response.go new file mode 100644 index 000000000..eac84a3f7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tagging_work_request_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetTaggingWorkRequestRequest wrapper for the GetTaggingWorkRequest operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetTaggingWorkRequest.go.html to see an example of how to use GetTaggingWorkRequestRequest. +type GetTaggingWorkRequestRequest struct { + + // The OCID of the work request. + WorkRequestId *string `mandatory:"true" contributesTo:"path" name:"workRequestId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetTaggingWorkRequestRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetTaggingWorkRequestRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetTaggingWorkRequestRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetTaggingWorkRequestRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetTaggingWorkRequestResponse wrapper for the GetTaggingWorkRequest operation +type GetTaggingWorkRequestResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The TaggingWorkRequest instance + TaggingWorkRequest `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The number of seconds that the client should wait before polling again. + RetryAfter *float32 `presentIn:"header" name:"retry-after"` +} + +func (response GetTaggingWorkRequestResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetTaggingWorkRequestResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tenancy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tenancy_request_response.go new file mode 100644 index 000000000..b886e014a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_tenancy_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetTenancyRequest wrapper for the GetTenancy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetTenancy.go.html to see an example of how to use GetTenancyRequest. +type GetTenancyRequest struct { + + // The OCID of the tenancy. + TenancyId *string `mandatory:"true" contributesTo:"path" name:"tenancyId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetTenancyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetTenancyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetTenancyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetTenancyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetTenancyResponse wrapper for the GetTenancy operation +type GetTenancyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Tenancy instance + Tenancy `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetTenancyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetTenancyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_user_group_membership_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_user_group_membership_request_response.go new file mode 100644 index 000000000..d2a79c838 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_user_group_membership_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetUserGroupMembershipRequest wrapper for the GetUserGroupMembership operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetUserGroupMembership.go.html to see an example of how to use GetUserGroupMembershipRequest. +type GetUserGroupMembershipRequest struct { + + // The OCID of the userGroupMembership. + UserGroupMembershipId *string `mandatory:"true" contributesTo:"path" name:"userGroupMembershipId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetUserGroupMembershipRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetUserGroupMembershipRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetUserGroupMembershipRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetUserGroupMembershipRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetUserGroupMembershipResponse wrapper for the GetUserGroupMembership operation +type GetUserGroupMembershipResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The UserGroupMembership instance + UserGroupMembership `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GetUserGroupMembershipResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetUserGroupMembershipResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_user_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_user_request_response.go new file mode 100644 index 000000000..b165b1ea0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_user_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetUserRequest wrapper for the GetUser operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetUser.go.html to see an example of how to use GetUserRequest. +type GetUserRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetUserRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetUserRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetUserRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetUserRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetUserResponse wrapper for the GetUser operation +type GetUserResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The User instance + User `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GetUserResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetUserResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_user_u_i_password_information_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_user_u_i_password_information_request_response.go new file mode 100644 index 000000000..1d39fae82 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_user_u_i_password_information_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetUserUIPasswordInformationRequest wrapper for the GetUserUIPasswordInformation operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetUserUIPasswordInformation.go.html to see an example of how to use GetUserUIPasswordInformationRequest. +type GetUserUIPasswordInformationRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetUserUIPasswordInformationRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetUserUIPasswordInformationRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetUserUIPasswordInformationRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetUserUIPasswordInformationRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetUserUIPasswordInformationResponse wrapper for the GetUserUIPasswordInformation operation +type GetUserUIPasswordInformationResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The UiPasswordInformation instance + UiPasswordInformation `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response GetUserUIPasswordInformationResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetUserUIPasswordInformationResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_work_request_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_work_request_request_response.go new file mode 100644 index 000000000..ab11697c7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/get_work_request_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetWorkRequestRequest wrapper for the GetWorkRequest operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetWorkRequest.go.html to see an example of how to use GetWorkRequestRequest. +type GetWorkRequestRequest struct { + + // The OCID of the work request. + WorkRequestId *string `mandatory:"true" contributesTo:"path" name:"workRequestId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetWorkRequestRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetWorkRequestRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetWorkRequestRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetWorkRequestRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetWorkRequestResponse wrapper for the GetWorkRequest operation +type GetWorkRequestResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The WorkRequest instance + WorkRequest `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The number of seconds that the client should wait before polling again. + RetryAfter *float32 `presentIn:"header" name:"retry-after"` +} + +func (response GetWorkRequestResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetWorkRequestResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/group.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/group.go new file mode 100644 index 000000000..9b4168735 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/group.go @@ -0,0 +1,97 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Group A collection of users who all need the same type of access to a particular set of resources or compartment. +// For conceptual information about groups and other IAM Service components, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/Content/Identity/Concepts/overview.htm). +// If you're federating with an identity provider (IdP), you need to create mappings between the groups +// defined in the IdP and groups you define in the IAM service. For more information, see +// Identity Providers and Federation (https://docs.cloud.oracle.com/Content/Identity/Concepts/federation.htm). Also see +// IdentityProvider and +// IdpGroupMapping. +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, +// see Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you supply string values +// using the API. +type Group struct { + + // The OCID of the group. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the tenancy containing the group. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name you assign to the group during creation. The name must be unique across all groups in + // the tenancy and cannot be changed. + Name *string `mandatory:"true" json:"name"` + + // The description you assign to the group. Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` + + // Date and time the group was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The group's current state. After creating a group, make sure its `lifecycleState` changes from CREATING to + // ACTIVE before using it. + LifecycleState GroupLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m Group) String() string { + return common.PointerString(m) +} + +// GroupLifecycleStateEnum Enum with underlying type: string +type GroupLifecycleStateEnum string + +// Set of constants representing the allowable values for GroupLifecycleStateEnum +const ( + GroupLifecycleStateCreating GroupLifecycleStateEnum = "CREATING" + GroupLifecycleStateActive GroupLifecycleStateEnum = "ACTIVE" + GroupLifecycleStateInactive GroupLifecycleStateEnum = "INACTIVE" + GroupLifecycleStateDeleting GroupLifecycleStateEnum = "DELETING" + GroupLifecycleStateDeleted GroupLifecycleStateEnum = "DELETED" +) + +var mappingGroupLifecycleState = map[string]GroupLifecycleStateEnum{ + "CREATING": GroupLifecycleStateCreating, + "ACTIVE": GroupLifecycleStateActive, + "INACTIVE": GroupLifecycleStateInactive, + "DELETING": GroupLifecycleStateDeleting, + "DELETED": GroupLifecycleStateDeleted, +} + +// GetGroupLifecycleStateEnumValues Enumerates the set of values for GroupLifecycleStateEnum +func GetGroupLifecycleStateEnumValues() []GroupLifecycleStateEnum { + values := make([]GroupLifecycleStateEnum, 0) + for _, v := range mappingGroupLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request.go new file mode 100644 index 000000000..527b04953 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request.go @@ -0,0 +1,118 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IamWorkRequest A IAM work request object that allows users to track Asynchronous API status. +type IamWorkRequest struct { + + // The OCID of the work request. + Id *string `mandatory:"true" json:"id"` + + // The asynchronous operation tracked by this IAM work request. + OperationType IamWorkRequestOperationTypeEnum `mandatory:"true" json:"operationType"` + + // Status of the work request + Status IamWorkRequestStatusEnum `mandatory:"true" json:"status"` + + // The OCID of the compartment containing this IAM work request. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The resources this work request affects. + Resources []IamWorkRequestResource `mandatory:"false" json:"resources"` + + // How much progress the operation has made. + PercentComplete *float32 `mandatory:"false" json:"percentComplete"` + + // Date and time the work was accepted, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeAccepted *common.SDKTime `mandatory:"false" json:"timeAccepted"` + + // Date and time the work started, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeStarted *common.SDKTime `mandatory:"false" json:"timeStarted"` + + // Date and time the work completed, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeFinished *common.SDKTime `mandatory:"false" json:"timeFinished"` +} + +func (m IamWorkRequest) String() string { + return common.PointerString(m) +} + +// IamWorkRequestOperationTypeEnum Enum with underlying type: string +type IamWorkRequestOperationTypeEnum string + +// Set of constants representing the allowable values for IamWorkRequestOperationTypeEnum +const ( + IamWorkRequestOperationTypeCreateDomain IamWorkRequestOperationTypeEnum = "CREATE_DOMAIN" + IamWorkRequestOperationTypeReplicateDomainToRegion IamWorkRequestOperationTypeEnum = "REPLICATE_DOMAIN_TO_REGION" + IamWorkRequestOperationTypeUpdateDomain IamWorkRequestOperationTypeEnum = "UPDATE_DOMAIN" + IamWorkRequestOperationTypeActivateDomain IamWorkRequestOperationTypeEnum = "ACTIVATE_DOMAIN" + IamWorkRequestOperationTypeDeactivateDomain IamWorkRequestOperationTypeEnum = "DEACTIVATE_DOMAIN" + IamWorkRequestOperationTypeDeleteDomain IamWorkRequestOperationTypeEnum = "DELETE_DOMAIN" + IamWorkRequestOperationTypeChangeCompartmentForDomain IamWorkRequestOperationTypeEnum = "CHANGE_COMPARTMENT_FOR_DOMAIN" + IamWorkRequestOperationTypeChangeLicenseTypeForDomain IamWorkRequestOperationTypeEnum = "CHANGE_LICENSE_TYPE_FOR_DOMAIN" +) + +var mappingIamWorkRequestOperationType = map[string]IamWorkRequestOperationTypeEnum{ + "CREATE_DOMAIN": IamWorkRequestOperationTypeCreateDomain, + "REPLICATE_DOMAIN_TO_REGION": IamWorkRequestOperationTypeReplicateDomainToRegion, + "UPDATE_DOMAIN": IamWorkRequestOperationTypeUpdateDomain, + "ACTIVATE_DOMAIN": IamWorkRequestOperationTypeActivateDomain, + "DEACTIVATE_DOMAIN": IamWorkRequestOperationTypeDeactivateDomain, + "DELETE_DOMAIN": IamWorkRequestOperationTypeDeleteDomain, + "CHANGE_COMPARTMENT_FOR_DOMAIN": IamWorkRequestOperationTypeChangeCompartmentForDomain, + "CHANGE_LICENSE_TYPE_FOR_DOMAIN": IamWorkRequestOperationTypeChangeLicenseTypeForDomain, +} + +// GetIamWorkRequestOperationTypeEnumValues Enumerates the set of values for IamWorkRequestOperationTypeEnum +func GetIamWorkRequestOperationTypeEnumValues() []IamWorkRequestOperationTypeEnum { + values := make([]IamWorkRequestOperationTypeEnum, 0) + for _, v := range mappingIamWorkRequestOperationType { + values = append(values, v) + } + return values +} + +// IamWorkRequestStatusEnum Enum with underlying type: string +type IamWorkRequestStatusEnum string + +// Set of constants representing the allowable values for IamWorkRequestStatusEnum +const ( + IamWorkRequestStatusAccepted IamWorkRequestStatusEnum = "ACCEPTED" + IamWorkRequestStatusInProgress IamWorkRequestStatusEnum = "IN_PROGRESS" + IamWorkRequestStatusFailed IamWorkRequestStatusEnum = "FAILED" + IamWorkRequestStatusSucceeded IamWorkRequestStatusEnum = "SUCCEEDED" + IamWorkRequestStatusCanceling IamWorkRequestStatusEnum = "CANCELING" + IamWorkRequestStatusCanceled IamWorkRequestStatusEnum = "CANCELED" +) + +var mappingIamWorkRequestStatus = map[string]IamWorkRequestStatusEnum{ + "ACCEPTED": IamWorkRequestStatusAccepted, + "IN_PROGRESS": IamWorkRequestStatusInProgress, + "FAILED": IamWorkRequestStatusFailed, + "SUCCEEDED": IamWorkRequestStatusSucceeded, + "CANCELING": IamWorkRequestStatusCanceling, + "CANCELED": IamWorkRequestStatusCanceled, +} + +// GetIamWorkRequestStatusEnumValues Enumerates the set of values for IamWorkRequestStatusEnum +func GetIamWorkRequestStatusEnumValues() []IamWorkRequestStatusEnum { + values := make([]IamWorkRequestStatusEnum, 0) + for _, v := range mappingIamWorkRequestStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_error_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_error_summary.go new file mode 100644 index 000000000..56c19763b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_error_summary.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IamWorkRequestErrorSummary An error encountered while executing an operation that is tracked by a IAM work request. +type IamWorkRequestErrorSummary struct { + + // A machine-usable code for the error that occured. + Code *string `mandatory:"true" json:"code"` + + // A human-readable error string. + Message *string `mandatory:"true" json:"message"` + + // The date and time the error occurred. + Timestamp *common.SDKTime `mandatory:"true" json:"timestamp"` +} + +func (m IamWorkRequestErrorSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_log_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_log_summary.go new file mode 100644 index 000000000..7cf5c633d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_log_summary.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IamWorkRequestLogSummary The log entity for a IAM work request. +type IamWorkRequestLogSummary struct { + + // A human-readable error string. + Message *string `mandatory:"true" json:"message"` + + // Date and time the log was written, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + Timestamp *common.SDKTime `mandatory:"false" json:"timestamp"` +} + +func (m IamWorkRequestLogSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_resource.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_resource.go new file mode 100644 index 000000000..a4ee3f0b3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_resource.go @@ -0,0 +1,66 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IamWorkRequestResource A IAM work request resource entry +type IamWorkRequestResource struct { + + // The way in which this resource is affected by the work tracked in the work request. + // A resource being created, updated, or deleted will remain in the IN_PROGRESS state until + // work is complete for that resource at which point it will transition to CREATED, UPDATED, + // or DELETED, respectively. + ActionType IamWorkRequestResourceActionTypeEnum `mandatory:"true" json:"actionType"` + + // The resource type the work request is affects. + EntityType *string `mandatory:"true" json:"entityType"` + + // An OCID of the resource that the work request affects. + Identifier *string `mandatory:"true" json:"identifier"` + + // The URI path that the user can do a GET on to access the resource metadata. + EntityUri *string `mandatory:"false" json:"entityUri"` +} + +func (m IamWorkRequestResource) String() string { + return common.PointerString(m) +} + +// IamWorkRequestResourceActionTypeEnum Enum with underlying type: string +type IamWorkRequestResourceActionTypeEnum string + +// Set of constants representing the allowable values for IamWorkRequestResourceActionTypeEnum +const ( + IamWorkRequestResourceActionTypeCreated IamWorkRequestResourceActionTypeEnum = "CREATED" + IamWorkRequestResourceActionTypeUpdated IamWorkRequestResourceActionTypeEnum = "UPDATED" + IamWorkRequestResourceActionTypeDeleted IamWorkRequestResourceActionTypeEnum = "DELETED" + IamWorkRequestResourceActionTypeRelated IamWorkRequestResourceActionTypeEnum = "RELATED" + IamWorkRequestResourceActionTypeInProgress IamWorkRequestResourceActionTypeEnum = "IN_PROGRESS" +) + +var mappingIamWorkRequestResourceActionType = map[string]IamWorkRequestResourceActionTypeEnum{ + "CREATED": IamWorkRequestResourceActionTypeCreated, + "UPDATED": IamWorkRequestResourceActionTypeUpdated, + "DELETED": IamWorkRequestResourceActionTypeDeleted, + "RELATED": IamWorkRequestResourceActionTypeRelated, + "IN_PROGRESS": IamWorkRequestResourceActionTypeInProgress, +} + +// GetIamWorkRequestResourceActionTypeEnumValues Enumerates the set of values for IamWorkRequestResourceActionTypeEnum +func GetIamWorkRequestResourceActionTypeEnumValues() []IamWorkRequestResourceActionTypeEnum { + values := make([]IamWorkRequestResourceActionTypeEnum, 0) + for _, v := range mappingIamWorkRequestResourceActionType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_summary.go new file mode 100644 index 000000000..dfa054a84 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/iam_work_request_summary.go @@ -0,0 +1,118 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IamWorkRequestSummary The IAM work request summary. Tracks the status of the asynchronous operations. +type IamWorkRequestSummary struct { + + // The OCID of the work request. + Id *string `mandatory:"true" json:"id"` + + // The asynchronous operation tracked by this IAM work request. + OperationType IamWorkRequestSummaryOperationTypeEnum `mandatory:"true" json:"operationType"` + + // Status of the work request + Status IamWorkRequestSummaryStatusEnum `mandatory:"true" json:"status"` + + // The OCID of the compartment containing this IAM work request. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The resources this work request affects. + Resources []IamWorkRequestResource `mandatory:"false" json:"resources"` + + // How much progress the operation has made. + PercentComplete *float32 `mandatory:"false" json:"percentComplete"` + + // Date and time the work was accepted, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeAccepted *common.SDKTime `mandatory:"false" json:"timeAccepted"` + + // Date and time the work started, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeStarted *common.SDKTime `mandatory:"false" json:"timeStarted"` + + // Date and time the work completed, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeFinished *common.SDKTime `mandatory:"false" json:"timeFinished"` +} + +func (m IamWorkRequestSummary) String() string { + return common.PointerString(m) +} + +// IamWorkRequestSummaryOperationTypeEnum Enum with underlying type: string +type IamWorkRequestSummaryOperationTypeEnum string + +// Set of constants representing the allowable values for IamWorkRequestSummaryOperationTypeEnum +const ( + IamWorkRequestSummaryOperationTypeCreateDomain IamWorkRequestSummaryOperationTypeEnum = "CREATE_DOMAIN" + IamWorkRequestSummaryOperationTypeReplicateDomainToRegion IamWorkRequestSummaryOperationTypeEnum = "REPLICATE_DOMAIN_TO_REGION" + IamWorkRequestSummaryOperationTypeUpdateDomain IamWorkRequestSummaryOperationTypeEnum = "UPDATE_DOMAIN" + IamWorkRequestSummaryOperationTypeActivateDomain IamWorkRequestSummaryOperationTypeEnum = "ACTIVATE_DOMAIN" + IamWorkRequestSummaryOperationTypeDeactivateDomain IamWorkRequestSummaryOperationTypeEnum = "DEACTIVATE_DOMAIN" + IamWorkRequestSummaryOperationTypeDeleteDomain IamWorkRequestSummaryOperationTypeEnum = "DELETE_DOMAIN" + IamWorkRequestSummaryOperationTypeChangeCompartmentForDomain IamWorkRequestSummaryOperationTypeEnum = "CHANGE_COMPARTMENT_FOR_DOMAIN" + IamWorkRequestSummaryOperationTypeChangeLicenseTypeForDomain IamWorkRequestSummaryOperationTypeEnum = "CHANGE_LICENSE_TYPE_FOR_DOMAIN" +) + +var mappingIamWorkRequestSummaryOperationType = map[string]IamWorkRequestSummaryOperationTypeEnum{ + "CREATE_DOMAIN": IamWorkRequestSummaryOperationTypeCreateDomain, + "REPLICATE_DOMAIN_TO_REGION": IamWorkRequestSummaryOperationTypeReplicateDomainToRegion, + "UPDATE_DOMAIN": IamWorkRequestSummaryOperationTypeUpdateDomain, + "ACTIVATE_DOMAIN": IamWorkRequestSummaryOperationTypeActivateDomain, + "DEACTIVATE_DOMAIN": IamWorkRequestSummaryOperationTypeDeactivateDomain, + "DELETE_DOMAIN": IamWorkRequestSummaryOperationTypeDeleteDomain, + "CHANGE_COMPARTMENT_FOR_DOMAIN": IamWorkRequestSummaryOperationTypeChangeCompartmentForDomain, + "CHANGE_LICENSE_TYPE_FOR_DOMAIN": IamWorkRequestSummaryOperationTypeChangeLicenseTypeForDomain, +} + +// GetIamWorkRequestSummaryOperationTypeEnumValues Enumerates the set of values for IamWorkRequestSummaryOperationTypeEnum +func GetIamWorkRequestSummaryOperationTypeEnumValues() []IamWorkRequestSummaryOperationTypeEnum { + values := make([]IamWorkRequestSummaryOperationTypeEnum, 0) + for _, v := range mappingIamWorkRequestSummaryOperationType { + values = append(values, v) + } + return values +} + +// IamWorkRequestSummaryStatusEnum Enum with underlying type: string +type IamWorkRequestSummaryStatusEnum string + +// Set of constants representing the allowable values for IamWorkRequestSummaryStatusEnum +const ( + IamWorkRequestSummaryStatusAccepted IamWorkRequestSummaryStatusEnum = "ACCEPTED" + IamWorkRequestSummaryStatusInProgress IamWorkRequestSummaryStatusEnum = "IN_PROGRESS" + IamWorkRequestSummaryStatusFailed IamWorkRequestSummaryStatusEnum = "FAILED" + IamWorkRequestSummaryStatusSucceeded IamWorkRequestSummaryStatusEnum = "SUCCEEDED" + IamWorkRequestSummaryStatusCanceling IamWorkRequestSummaryStatusEnum = "CANCELING" + IamWorkRequestSummaryStatusCanceled IamWorkRequestSummaryStatusEnum = "CANCELED" +) + +var mappingIamWorkRequestSummaryStatus = map[string]IamWorkRequestSummaryStatusEnum{ + "ACCEPTED": IamWorkRequestSummaryStatusAccepted, + "IN_PROGRESS": IamWorkRequestSummaryStatusInProgress, + "FAILED": IamWorkRequestSummaryStatusFailed, + "SUCCEEDED": IamWorkRequestSummaryStatusSucceeded, + "CANCELING": IamWorkRequestSummaryStatusCanceling, + "CANCELED": IamWorkRequestSummaryStatusCanceled, +} + +// GetIamWorkRequestSummaryStatusEnumValues Enumerates the set of values for IamWorkRequestSummaryStatusEnum +func GetIamWorkRequestSummaryStatusEnumValues() []IamWorkRequestSummaryStatusEnum { + values := make([]IamWorkRequestSummaryStatusEnum, 0) + for _, v := range mappingIamWorkRequestSummaryStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/identity_client.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/identity_client.go new file mode 100644 index 000000000..977d34644 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/identity_client.go @@ -0,0 +1,8577 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "context" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" + "github.com/oracle/oci-go-sdk/v54/common/auth" + "net/http" + "time" +) + +//IdentityClient a client for Identity +type IdentityClient struct { + common.BaseClient + config *common.ConfigurationProvider +} + +// NewIdentityClientWithConfigurationProvider Creates a new default Identity client with the given configuration provider. +// the configuration provider will be used for the default signer as well as reading the region +func NewIdentityClientWithConfigurationProvider(configProvider common.ConfigurationProvider) (client IdentityClient, err error) { + provider, err := auth.GetGenericConfigurationProvider(configProvider) + if err != nil { + return client, err + } + baseClient, e := common.NewClientWithConfig(provider) + if e != nil { + return client, e + } + return newIdentityClientFromBaseClient(baseClient, provider) +} + +// NewIdentityClientWithOboToken Creates a new default Identity client with the given configuration provider. +// The obotoken will be added to default headers and signed; the configuration provider will be used for the signer +// as well as reading the region +func NewIdentityClientWithOboToken(configProvider common.ConfigurationProvider, oboToken string) (client IdentityClient, err error) { + baseClient, err := common.NewClientWithOboToken(configProvider, oboToken) + if err != nil { + return client, err + } + + return newIdentityClientFromBaseClient(baseClient, configProvider) +} + +func newIdentityClientFromBaseClient(baseClient common.BaseClient, configProvider common.ConfigurationProvider) (client IdentityClient, err error) { + // Identity service default circuit breaker is enabled + baseClient.Configuration.CircuitBreaker = common.NewCircuitBreaker(common.DefaultCircuitBreakerSetting()) + common.ConfigCircuitBreakerFromEnvVar(&baseClient) + common.ConfigCircuitBreakerFromGlobalVar(&baseClient) + + client = IdentityClient{BaseClient: baseClient} + client.BasePath = "20160918" + err = client.setConfigurationProvider(configProvider) + return +} + +// SetRegion overrides the region of this client. +func (client *IdentityClient) SetRegion(region string) { + client.Host = common.StringToRegion(region).EndpointForTemplate("identity", "https://identity.{region}.oci.{secondLevelDomain}") +} + +// SetConfigurationProvider sets the configuration provider including the region, returns an error if is not valid +func (client *IdentityClient) setConfigurationProvider(configProvider common.ConfigurationProvider) error { + if ok, err := common.IsConfigurationProviderValid(configProvider); !ok { + return err + } + + // Error has been checked already + region, _ := configProvider.Region() + client.SetRegion(region) + client.config = &configProvider + return nil +} + +// ConfigurationProvider the ConfigurationProvider used in this client, or null if none set +func (client *IdentityClient) ConfigurationProvider() *common.ConfigurationProvider { + return client.config +} + +// ActivateDomain If the domain's {@code lifecycleState} is INACTIVE, +// 1. Set the {@code lifecycleDetails} to ACTIVATING and asynchronously starts enabling +// the domain and return 202 ACCEPTED. +// 1.1 Sets the domain status to ENABLED and set specified domain's +// {@code lifecycleState} to ACTIVE and set the {@code lifecycleDetails} to null. +// To track progress, HTTP GET on /iamWorkRequests/{iamWorkRequestsId} endpoint will provide +// the async operation's status. Deactivate a domain can be done using HTTP POST +// /domains/{domainId}/actions/deactivate. +// - If the domain's {@code lifecycleState} is ACTIVE, returns 202 ACCEPTED with no action +// taken on service side. +// - If domain is of {@code type} DEFAULT or DEFAULT_LIGHTWEIGHT or domain's {@code lifecycleState} is not INACTIVE, +// returns 400 BAD REQUEST. +// - If the domain doesn't exists, returns 404 NOT FOUND. +// - If the authenticated user is part of the domain to be activated, returns 400 BAD REQUEST +// - If error occurs while activating domain, returns 500 INTERNAL SERVER ERROR. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ActivateDomain.go.html to see an example of how to use ActivateDomain API. +func (client IdentityClient) ActivateDomain(ctx context.Context, request ActivateDomainRequest) (response ActivateDomainResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.activateDomain, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ActivateDomainResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ActivateDomainResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ActivateDomainResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ActivateDomainResponse") + } + return +} + +// activateDomain implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) activateDomain(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/domains/{domainId}/actions/activate", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ActivateDomainResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ActivateMfaTotpDevice Activates the specified MFA TOTP device for the user. Activation requires manual interaction with the Console. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ActivateMfaTotpDevice.go.html to see an example of how to use ActivateMfaTotpDevice API. +func (client IdentityClient) ActivateMfaTotpDevice(ctx context.Context, request ActivateMfaTotpDeviceRequest) (response ActivateMfaTotpDeviceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.activateMfaTotpDevice, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ActivateMfaTotpDeviceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ActivateMfaTotpDeviceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ActivateMfaTotpDeviceResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ActivateMfaTotpDeviceResponse") + } + return +} + +// activateMfaTotpDevice implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) activateMfaTotpDevice(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/users/{userId}/mfaTotpDevices/{mfaTotpDeviceId}/actions/activate", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ActivateMfaTotpDeviceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// AddUserToGroup Adds the specified user to the specified group and returns a `UserGroupMembership` object with its own OCID. +// After you send your request, the new object's `lifecycleState` will temporarily be CREATING. Before using the +// object, first make sure its `lifecycleState` has changed to ACTIVE. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/AddUserToGroup.go.html to see an example of how to use AddUserToGroup API. +func (client IdentityClient) AddUserToGroup(ctx context.Context, request AddUserToGroupRequest) (response AddUserToGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.addUserToGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AddUserToGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AddUserToGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AddUserToGroupResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AddUserToGroupResponse") + } + return +} + +// addUserToGroup implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) addUserToGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/userGroupMemberships", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AddUserToGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// AssembleEffectiveTagSet Assembles tag defaults in the specified compartment and any parent compartments to determine +// the tags to apply. Tag defaults from parent compartments do not override tag defaults +// referencing the same tag in a compartment lower down the hierarchy. This set of tag defaults +// includes all tag defaults from the current compartment back to the root compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/AssembleEffectiveTagSet.go.html to see an example of how to use AssembleEffectiveTagSet API. +func (client IdentityClient) AssembleEffectiveTagSet(ctx context.Context, request AssembleEffectiveTagSetRequest) (response AssembleEffectiveTagSetResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.assembleEffectiveTagSet, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AssembleEffectiveTagSetResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AssembleEffectiveTagSetResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AssembleEffectiveTagSetResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AssembleEffectiveTagSetResponse") + } + return +} + +// assembleEffectiveTagSet implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) assembleEffectiveTagSet(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/tagDefaults/actions/assembleEffectiveTagSet", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AssembleEffectiveTagSetResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// BulkDeleteResources Deletes multiple resources in the compartment. All resources must be in the same compartment. You must have the appropriate +// permissions to delete the resources in the request. This API can only be invoked from the tenancy's +// home region (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingregions.htm#Home). This operation creates a +// WorkRequest. Use the GetWorkRequest +// API to monitor the status of the bulk action. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/BulkDeleteResources.go.html to see an example of how to use BulkDeleteResources API. +func (client IdentityClient) BulkDeleteResources(ctx context.Context, request BulkDeleteResourcesRequest) (response BulkDeleteResourcesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.bulkDeleteResources, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = BulkDeleteResourcesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = BulkDeleteResourcesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(BulkDeleteResourcesResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into BulkDeleteResourcesResponse") + } + return +} + +// bulkDeleteResources implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) bulkDeleteResources(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/compartments/{compartmentId}/actions/bulkDeleteResources", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response BulkDeleteResourcesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// BulkDeleteTags Deletes the specified tag key definitions. This operation triggers a process that removes the +// tags from all resources in your tenancy. The tag key definitions must be within the same tag namespace. +// The following actions happen immediately: +// +// * If the tag is a cost-tracking tag, the tag no longer counts against your +// 10 cost-tracking tags limit, even if you do not disable the tag before running this operation. +// * If the tag is used with dynamic groups, the rules that contain the tag are no longer +// evaluated against the tag. +// After you start this operation, the state of the tag changes to DELETING, and tag removal +// from resources begins. This process can take up to 48 hours depending on the number of resources that +// are tagged and the regions in which those resources reside. +// When all tags have been removed, the state changes to DELETED. You cannot restore a deleted tag. After the tag state +// changes to DELETED, you can use the same tag name again. +// After you start this operation, you cannot start either the DeleteTag or the CascadeDeleteTagNamespace operation until this process completes. +// In order to delete tags, you must first retire the tags. Use UpdateTag +// to retire a tag. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/BulkDeleteTags.go.html to see an example of how to use BulkDeleteTags API. +func (client IdentityClient) BulkDeleteTags(ctx context.Context, request BulkDeleteTagsRequest) (response BulkDeleteTagsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.bulkDeleteTags, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = BulkDeleteTagsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = BulkDeleteTagsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(BulkDeleteTagsResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into BulkDeleteTagsResponse") + } + return +} + +// bulkDeleteTags implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) bulkDeleteTags(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/tags/actions/bulkDelete", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response BulkDeleteTagsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// BulkEditTags Edits the specified list of tag key definitions for the selected resources. +// This operation triggers a process that edits the tags on all selected resources. The possible actions are: +// * Add a defined tag when the tag does not already exist on the resource. +// * Update the value for a defined tag when the tag is present on the resource. +// * Add a defined tag when it does not already exist on the resource or update the value for a defined tag when the tag is present on the resource. +// * Remove a defined tag from a resource. The tag is removed from the resource regardless of the tag value. +// See BulkEditOperationDetails for more information. +// The edits can include a combination of operations and tag sets. +// However, multiple operations cannot apply to one key definition in the same request. +// For example, if one request adds `tag set-1` to a resource and sets a tag value to `tag set-2`, +// `tag set-1` and `tag set-2` cannot have any common tag definitions. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/BulkEditTags.go.html to see an example of how to use BulkEditTags API. +func (client IdentityClient) BulkEditTags(ctx context.Context, request BulkEditTagsRequest) (response BulkEditTagsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.bulkEditTags, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = BulkEditTagsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = BulkEditTagsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(BulkEditTagsResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into BulkEditTagsResponse") + } + return +} + +// bulkEditTags implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) bulkEditTags(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/tags/actions/bulkEdit", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response BulkEditTagsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// BulkMoveResources Moves multiple resources from one compartment to another. All resources must be in the same compartment. +// This API can only be invoked from the tenancy's home region (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingregions.htm#Home). +// To move resources, you must have the appropriate permissions to move the resource in both the source and target +// compartments. This operation creates a WorkRequest. +// Use the GetWorkRequest API to monitor the status of the bulk action. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/BulkMoveResources.go.html to see an example of how to use BulkMoveResources API. +func (client IdentityClient) BulkMoveResources(ctx context.Context, request BulkMoveResourcesRequest) (response BulkMoveResourcesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.bulkMoveResources, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = BulkMoveResourcesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = BulkMoveResourcesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(BulkMoveResourcesResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into BulkMoveResourcesResponse") + } + return +} + +// bulkMoveResources implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) bulkMoveResources(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/compartments/{compartmentId}/actions/bulkMoveResources", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response BulkMoveResourcesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CascadeDeleteTagNamespace Deletes the specified tag namespace. This operation triggers a process that removes all of the tags +// defined in the specified tag namespace from all resources in your tenancy and then deletes the tag namespace. +// After you start the delete operation: +// * New tag key definitions cannot be created under the namespace. +// * The state of the tag namespace changes to DELETING. +// * Tag removal from the resources begins. +// This process can take up to 48 hours depending on the number of tag definitions in the namespace, the number of resources +// that are tagged, and the locations of the regions in which those resources reside. +// After all tags are removed, the state changes to DELETED. You cannot restore a deleted tag namespace. After the deleted tag namespace +// changes its state to DELETED, you can use the name of the deleted tag namespace again. +// After you start this operation, you cannot start either the DeleteTag or the BulkDeleteTags operation until this process completes. +// To delete a tag namespace, you must first retire it. Use UpdateTagNamespace +// to retire a tag namespace. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CascadeDeleteTagNamespace.go.html to see an example of how to use CascadeDeleteTagNamespace API. +func (client IdentityClient) CascadeDeleteTagNamespace(ctx context.Context, request CascadeDeleteTagNamespaceRequest) (response CascadeDeleteTagNamespaceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.cascadeDeleteTagNamespace, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CascadeDeleteTagNamespaceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CascadeDeleteTagNamespaceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CascadeDeleteTagNamespaceResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CascadeDeleteTagNamespaceResponse") + } + return +} + +// cascadeDeleteTagNamespace implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) cascadeDeleteTagNamespace(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/tagNamespaces/{tagNamespaceId}/actions/cascadeDelete", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CascadeDeleteTagNamespaceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeDomainCompartment Change the containing compartment for a domain. +// This is an asynchronous call where the Domain's compartment is changed and is updated with the new compartment information. +// To track progress, HTTP GET on /iamWorkRequests/{iamWorkRequestsId} endpoint will provide +// the async operation's status. +// The compartment change is complete when accessed via domain URL and +// also returns new compartment OCID. +// - If the domain doesn't exists, returns 404 NOT FOUND. +// - If Domain {@code type} is DEFAULT or DEFAULT_LIGHTWEIGHT, return 400 BAD Request +// - If Domain is not active or being updated, returns 400 BAD REQUEST. +// - If error occurs while changing compartment for domain, return 500 INTERNAL SERVER ERROR. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ChangeDomainCompartment.go.html to see an example of how to use ChangeDomainCompartment API. +func (client IdentityClient) ChangeDomainCompartment(ctx context.Context, request ChangeDomainCompartmentRequest) (response ChangeDomainCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeDomainCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeDomainCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeDomainCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeDomainCompartmentResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeDomainCompartmentResponse") + } + return +} + +// changeDomainCompartment implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) changeDomainCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/domains/{domainId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeDomainCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeDomainLicenseType If the domain's {@code lifecycleState} is ACTIVE, validates the requested {@code licenseType} update +// is allowed and +// 1. Set the {@code lifecycleDetails} to UPDATING +// 2. Asynchronously starts updating the domain and return 202 ACCEPTED. +// 2.1 Successfully updates specified domain's {@code licenseType}. +// 3. On completion set the {@code lifecycleDetails} to null. +// To track progress, HTTP GET on /iamWorkRequests/{iamWorkRequestsId} endpoint will provide +// the async operation's status. +// - If license type update is successful, return 202 ACCEPTED +// - If requested {@code licenseType} validation fails, returns 400 Bad request. +// - If Domain is not active or being updated, returns 400 BAD REQUEST. +// - If Domain {@code type} is DEFAULT or DEFAULT_LIGHTWEIGHT, return 400 BAD Request +// - If the domain doesn't exists, returns 404 NOT FOUND +// - If any internal error occurs, returns 500 INTERNAL SERVER ERROR. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ChangeDomainLicenseType.go.html to see an example of how to use ChangeDomainLicenseType API. +func (client IdentityClient) ChangeDomainLicenseType(ctx context.Context, request ChangeDomainLicenseTypeRequest) (response ChangeDomainLicenseTypeResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeDomainLicenseType, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeDomainLicenseTypeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeDomainLicenseTypeResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeDomainLicenseTypeResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeDomainLicenseTypeResponse") + } + return +} + +// changeDomainLicenseType implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) changeDomainLicenseType(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/domains/{domainId}/actions/changeLicenseType", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeDomainLicenseTypeResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ChangeTagNamespaceCompartment Moves the specified tag namespace to the specified compartment within the same tenancy. +// To move the tag namespace, you must have the manage tag-namespaces permission on both compartments. +// For more information about IAM policies, see Details for IAM (https://docs.cloud.oracle.com/Content/Identity/Reference/iampolicyreference.htm). +// Moving a tag namespace moves all the tag key definitions contained in the tag namespace. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ChangeTagNamespaceCompartment.go.html to see an example of how to use ChangeTagNamespaceCompartment API. +func (client IdentityClient) ChangeTagNamespaceCompartment(ctx context.Context, request ChangeTagNamespaceCompartmentRequest) (response ChangeTagNamespaceCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.changeTagNamespaceCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ChangeTagNamespaceCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ChangeTagNamespaceCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ChangeTagNamespaceCompartmentResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ChangeTagNamespaceCompartmentResponse") + } + return +} + +// changeTagNamespaceCompartment implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) changeTagNamespaceCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/tagNamespaces/{tagNamespaceId}/actions/changeCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ChangeTagNamespaceCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateAuthToken Creates a new auth token for the specified user. For information about what auth tokens are for, see +// Managing User Credentials (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingcredentials.htm). +// You must specify a *description* for the auth token (although it can be an empty string). It does not +// have to be unique, and you can change it anytime with +// UpdateAuthToken. +// Every user has permission to create an auth token for *their own user ID*. An administrator in your organization +// does not need to write a policy to give users this ability. To compare, administrators who have permission to the +// tenancy can use this operation to create an auth token for any user, including themselves. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateAuthToken.go.html to see an example of how to use CreateAuthToken API. +func (client IdentityClient) CreateAuthToken(ctx context.Context, request CreateAuthTokenRequest) (response CreateAuthTokenResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createAuthToken, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateAuthTokenResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateAuthTokenResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateAuthTokenResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateAuthTokenResponse") + } + return +} + +// createAuthToken implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createAuthToken(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/users/{userId}/authTokens", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateAuthTokenResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateCompartment Creates a new compartment in the specified compartment. +// **Important:** Compartments cannot be deleted. +// Specify the parent compartment's OCID as the compartment ID in the request object. Remember that the tenancy +// is simply the root compartment. For information about OCIDs, see +// Resource Identifiers (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm). +// You must also specify a *name* for the compartment, which must be unique across all compartments in +// your tenancy. You can use this name or the OCID when writing policies that apply +// to the compartment. For more information about policies, see +// How Policies Work (https://docs.cloud.oracle.com/Content/Identity/Concepts/policies.htm). +// You must also specify a *description* for the compartment (although it can be an empty string). It does +// not have to be unique, and you can change it anytime with +// UpdateCompartment. +// After you send your request, the new object's `lifecycleState` will temporarily be CREATING. Before using the +// object, first make sure its `lifecycleState` has changed to ACTIVE. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateCompartment.go.html to see an example of how to use CreateCompartment API. +func (client IdentityClient) CreateCompartment(ctx context.Context, request CreateCompartmentRequest) (response CreateCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateCompartmentResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateCompartmentResponse") + } + return +} + +// createCompartment implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/compartments", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateCustomerSecretKey Creates a new secret key for the specified user. Secret keys are used for authentication with the Object Storage Service's Amazon S3 +// compatible API. The secret key consists of an Access Key/Secret Key pair. For information, see +// Managing User Credentials (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingcredentials.htm). +// You must specify a *description* for the secret key (although it can be an empty string). It does not +// have to be unique, and you can change it anytime with +// UpdateCustomerSecretKey. +// Every user has permission to create a secret key for *their own user ID*. An administrator in your organization +// does not need to write a policy to give users this ability. To compare, administrators who have permission to the +// tenancy can use this operation to create a secret key for any user, including themselves. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateCustomerSecretKey.go.html to see an example of how to use CreateCustomerSecretKey API. +func (client IdentityClient) CreateCustomerSecretKey(ctx context.Context, request CreateCustomerSecretKeyRequest) (response CreateCustomerSecretKeyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createCustomerSecretKey, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateCustomerSecretKeyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateCustomerSecretKeyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateCustomerSecretKeyResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateCustomerSecretKeyResponse") + } + return +} + +// createCustomerSecretKey implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createCustomerSecretKey(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/users/{userId}/customerSecretKeys", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateCustomerSecretKeyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateDbCredential Creates a new DB credential for the specified user. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateDbCredential.go.html to see an example of how to use CreateDbCredential API. +func (client IdentityClient) CreateDbCredential(ctx context.Context, request CreateDbCredentialRequest) (response CreateDbCredentialResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createDbCredential, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateDbCredentialResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateDbCredentialResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateDbCredentialResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateDbCredentialResponse") + } + return +} + +// createDbCredential implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createDbCredential(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/users/{userId}/dbCredentials", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateDbCredentialResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateDomain Creates a new domain in the tenancy with domain home in {@code homeRegion}. This is an asynchronous call - where, at start, +// {@code lifecycleState} of this domain is set to CREATING and {@code lifecycleDetails} to UPDATING. On domain creation completion +// this Domain's {@code lifecycleState} will be set to ACTIVE and {@code lifecycleDetails} to null. +// To track progress, HTTP GET on /iamWorkRequests/{iamWorkRequestsId} endpoint will provide +// the async operation's status. +// After creating a `Domain`, make sure its `lifecycleState` changes from CREATING to ACTIVE +// before using it. +// If the domain's {@code displayName} already exists, returns 400 BAD REQUEST. +// If any one of admin related fields are provided and one of the following 3 fields +// - {@code adminEmail}, {@code adminLastName} and {@code adminUserName} - is not provided, +// returns 400 BAD REQUEST. +// - If {@code isNotificationBypassed} is NOT provided when admin information is provided, +// returns 400 BAD REQUEST. +// - If any internal error occurs, return 500 INTERNAL SERVER ERROR. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateDomain.go.html to see an example of how to use CreateDomain API. +func (client IdentityClient) CreateDomain(ctx context.Context, request CreateDomainRequest) (response CreateDomainResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createDomain, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateDomainResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateDomainResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateDomainResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateDomainResponse") + } + return +} + +// createDomain implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createDomain(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/domains", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateDomainResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateDynamicGroup Creates a new dynamic group in your tenancy. +// You must specify your tenancy's OCID as the compartment ID in the request object (remember that the tenancy +// is simply the root compartment). Notice that IAM resources (users, groups, compartments, and some policies) +// reside within the tenancy itself, unlike cloud resources such as compute instances, which typically +// reside within compartments inside the tenancy. For information about OCIDs, see +// Resource Identifiers (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm). +// You must also specify a *name* for the dynamic group, which must be unique across all dynamic groups in your +// tenancy, and cannot be changed. Note that this name has to be also unique across all groups in your tenancy. +// You can use this name or the OCID when writing policies that apply to the dynamic group. For more information +// about policies, see How Policies Work (https://docs.cloud.oracle.com/Content/Identity/Concepts/policies.htm). +// You must also specify a *description* for the dynamic group (although it can be an empty string). It does not +// have to be unique, and you can change it anytime with UpdateDynamicGroup. +// After you send your request, the new object's `lifecycleState` will temporarily be CREATING. Before using the +// object, first make sure its `lifecycleState` has changed to ACTIVE. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateDynamicGroup.go.html to see an example of how to use CreateDynamicGroup API. +func (client IdentityClient) CreateDynamicGroup(ctx context.Context, request CreateDynamicGroupRequest) (response CreateDynamicGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createDynamicGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateDynamicGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateDynamicGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateDynamicGroupResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateDynamicGroupResponse") + } + return +} + +// createDynamicGroup implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createDynamicGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/dynamicGroups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateDynamicGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateGroup Creates a new group in your tenancy. +// You must specify your tenancy's OCID as the compartment ID in the request object (remember that the tenancy +// is simply the root compartment). Notice that IAM resources (users, groups, compartments, and some policies) +// reside within the tenancy itself, unlike cloud resources such as compute instances, which typically +// reside within compartments inside the tenancy. For information about OCIDs, see +// Resource Identifiers (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm). +// You must also specify a *name* for the group, which must be unique across all groups in your tenancy and +// cannot be changed. You can use this name or the OCID when writing policies that apply to the group. For more +// information about policies, see How Policies Work (https://docs.cloud.oracle.com/Content/Identity/Concepts/policies.htm). +// You must also specify a *description* for the group (although it can be an empty string). It does not +// have to be unique, and you can change it anytime with UpdateGroup. +// After you send your request, the new object's `lifecycleState` will temporarily be CREATING. Before using the +// object, first make sure its `lifecycleState` has changed to ACTIVE. +// After creating the group, you need to put users in it and write policies for it. +// See AddUserToGroup and +// CreatePolicy. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateGroup.go.html to see an example of how to use CreateGroup API. +func (client IdentityClient) CreateGroup(ctx context.Context, request CreateGroupRequest) (response CreateGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateGroupResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateGroupResponse") + } + return +} + +// createGroup implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/groups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateIdentityProvider **Deprecated.** For more information, see Deprecated IAM Service APIs (https://docs.cloud.oracle.com/Content/Identity/Reference/deprecatediamapis.htm). +// Creates a new identity provider in your tenancy. For more information, see +// Identity Providers and Federation (https://docs.cloud.oracle.com/Content/Identity/Concepts/federation.htm). +// You must specify your tenancy's OCID as the compartment ID in the request object. +// Remember that the tenancy is simply the root compartment. For information about +// OCIDs, see Resource Identifiers (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm). +// You must also specify a *name* for the `IdentityProvider`, which must be unique +// across all `IdentityProvider` objects in your tenancy and cannot be changed. +// You must also specify a *description* for the `IdentityProvider` (although +// it can be an empty string). It does not have to be unique, and you can change +// it anytime with +// UpdateIdentityProvider. +// After you send your request, the new object's `lifecycleState` will temporarily +// be CREATING. Before using the object, first make sure its `lifecycleState` has +// changed to ACTIVE. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateIdentityProvider.go.html to see an example of how to use CreateIdentityProvider API. +func (client IdentityClient) CreateIdentityProvider(ctx context.Context, request CreateIdentityProviderRequest) (response CreateIdentityProviderResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createIdentityProvider, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateIdentityProviderResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateIdentityProviderResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateIdentityProviderResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateIdentityProviderResponse") + } + return +} + +// createIdentityProvider implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createIdentityProvider(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/identityProviders", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateIdentityProviderResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponseWithPolymorphicBody(httpResponse, &response, &identityprovider{}) + return response, err +} + +// CreateIdpGroupMapping **Deprecated.** For more information, see Deprecated IAM Service APIs (https://docs.cloud.oracle.com/Content/Identity/Reference/deprecatediamapis.htm). +// Creates a single mapping between an IdP group and an IAM Service +// Group. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateIdpGroupMapping.go.html to see an example of how to use CreateIdpGroupMapping API. +func (client IdentityClient) CreateIdpGroupMapping(ctx context.Context, request CreateIdpGroupMappingRequest) (response CreateIdpGroupMappingResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createIdpGroupMapping, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateIdpGroupMappingResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateIdpGroupMappingResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateIdpGroupMappingResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateIdpGroupMappingResponse") + } + return +} + +// createIdpGroupMapping implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createIdpGroupMapping(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/identityProviders/{identityProviderId}/groupMappings", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateIdpGroupMappingResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateMfaTotpDevice Creates a new MFA TOTP device for the user. A user can have one MFA TOTP device. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateMfaTotpDevice.go.html to see an example of how to use CreateMfaTotpDevice API. +func (client IdentityClient) CreateMfaTotpDevice(ctx context.Context, request CreateMfaTotpDeviceRequest) (response CreateMfaTotpDeviceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createMfaTotpDevice, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateMfaTotpDeviceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateMfaTotpDeviceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateMfaTotpDeviceResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateMfaTotpDeviceResponse") + } + return +} + +// createMfaTotpDevice implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createMfaTotpDevice(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/users/{userId}/mfaTotpDevices", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateMfaTotpDeviceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateNetworkSource Creates a new network source in your tenancy. +// You must specify your tenancy's OCID as the compartment ID in the request object (remember that the tenancy +// is simply the root compartment). Notice that IAM resources (users, groups, compartments, and some policies) +// reside within the tenancy itself, unlike cloud resources such as compute instances, which typically +// reside within compartments inside the tenancy. For information about OCIDs, see +// Resource Identifiers (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm). +// You must also specify a *name* for the network source, which must be unique across all network sources in your +// tenancy, and cannot be changed. +// You can use this name or the OCID when writing policies that apply to the network source. For more information +// about policies, see How Policies Work (https://docs.cloud.oracle.com/Content/Identity/Concepts/policies.htm). +// You must also specify a *description* for the network source (although it can be an empty string). It does not +// have to be unique, and you can change it anytime with UpdateNetworkSource. +// After you send your request, the new object's `lifecycleState` will temporarily be CREATING. Before using the +// object, first make sure its `lifecycleState` has changed to ACTIVE. +// After your network resource is created, you can use it in policy to restrict access to only requests made from an allowed +// IP address specified in your network source. For more information, see Managing Network Sources (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingnetworksources.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateNetworkSource.go.html to see an example of how to use CreateNetworkSource API. +func (client IdentityClient) CreateNetworkSource(ctx context.Context, request CreateNetworkSourceRequest) (response CreateNetworkSourceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createNetworkSource, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateNetworkSourceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateNetworkSourceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateNetworkSourceResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateNetworkSourceResponse") + } + return +} + +// createNetworkSource implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createNetworkSource(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/networkSources", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateNetworkSourceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateOAuthClientCredential Creates Oauth token for the user +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateOAuthClientCredential.go.html to see an example of how to use CreateOAuthClientCredential API. +func (client IdentityClient) CreateOAuthClientCredential(ctx context.Context, request CreateOAuthClientCredentialRequest) (response CreateOAuthClientCredentialResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createOAuthClientCredential, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateOAuthClientCredentialResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateOAuthClientCredentialResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateOAuthClientCredentialResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateOAuthClientCredentialResponse") + } + return +} + +// createOAuthClientCredential implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createOAuthClientCredential(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/users/{userId}/oauth2ClientCredentials", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateOAuthClientCredentialResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateOrResetUIPassword Creates a new Console one-time password for the specified user. For more information about user +// credentials, see User Credentials (https://docs.cloud.oracle.com/Content/Identity/Concepts/usercredentials.htm). +// Use this operation after creating a new user, or if a user forgets their password. The new one-time +// password is returned to you in the response, and you must securely deliver it to the user. They'll +// be prompted to change this password the next time they sign in to the Console. If they don't change +// it within 7 days, the password will expire and you'll need to create a new one-time password for the +// user. +// **Note:** The user's Console login is the unique name you specified when you created the user +// (see CreateUser). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateOrResetUIPassword.go.html to see an example of how to use CreateOrResetUIPassword API. +func (client IdentityClient) CreateOrResetUIPassword(ctx context.Context, request CreateOrResetUIPasswordRequest) (response CreateOrResetUIPasswordResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createOrResetUIPassword, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateOrResetUIPasswordResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateOrResetUIPasswordResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateOrResetUIPasswordResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateOrResetUIPasswordResponse") + } + return +} + +// createOrResetUIPassword implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createOrResetUIPassword(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/users/{userId}/uiPassword", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateOrResetUIPasswordResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreatePolicy Creates a new policy in the specified compartment (either the tenancy or another of your compartments). +// If you're new to policies, see Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +// You must specify a *name* for the policy, which must be unique across all policies in your tenancy +// and cannot be changed. +// You must also specify a *description* for the policy (although it can be an empty string). It does not +// have to be unique, and you can change it anytime with UpdatePolicy. +// You must specify one or more policy statements in the statements array. For information about writing +// policies, see How Policies Work (https://docs.cloud.oracle.com/Content/Identity/Concepts/policies.htm) and +// Common Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/commonpolicies.htm). +// After you send your request, the new object's `lifecycleState` will temporarily be CREATING. Before using the +// object, first make sure its `lifecycleState` has changed to ACTIVE. +// New policies take effect typically within 10 seconds. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreatePolicy.go.html to see an example of how to use CreatePolicy API. +func (client IdentityClient) CreatePolicy(ctx context.Context, request CreatePolicyRequest) (response CreatePolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createPolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreatePolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreatePolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreatePolicyResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreatePolicyResponse") + } + return +} + +// createPolicy implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createPolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/policies", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreatePolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateRegionSubscription Creates a subscription to a region for a tenancy. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateRegionSubscription.go.html to see an example of how to use CreateRegionSubscription API. +func (client IdentityClient) CreateRegionSubscription(ctx context.Context, request CreateRegionSubscriptionRequest) (response CreateRegionSubscriptionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createRegionSubscription, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateRegionSubscriptionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateRegionSubscriptionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateRegionSubscriptionResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateRegionSubscriptionResponse") + } + return +} + +// createRegionSubscription implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createRegionSubscription(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/tenancies/{tenancyId}/regionSubscriptions", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateRegionSubscriptionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateSmtpCredential Creates a new SMTP credential for the specified user. An SMTP credential has an SMTP user name and an SMTP password. +// You must specify a *description* for the SMTP credential (although it can be an empty string). It does not +// have to be unique, and you can change it anytime with +// UpdateSmtpCredential. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateSmtpCredential.go.html to see an example of how to use CreateSmtpCredential API. +func (client IdentityClient) CreateSmtpCredential(ctx context.Context, request CreateSmtpCredentialRequest) (response CreateSmtpCredentialResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createSmtpCredential, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateSmtpCredentialResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateSmtpCredentialResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateSmtpCredentialResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateSmtpCredentialResponse") + } + return +} + +// createSmtpCredential implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createSmtpCredential(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/users/{userId}/smtpCredentials", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateSmtpCredentialResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateSwiftPassword **Deprecated. Use CreateAuthToken instead.** +// Creates a new Swift password for the specified user. For information about what Swift passwords are for, see +// Managing User Credentials (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingcredentials.htm). +// You must specify a *description* for the Swift password (although it can be an empty string). It does not +// have to be unique, and you can change it anytime with +// UpdateSwiftPassword. +// Every user has permission to create a Swift password for *their own user ID*. An administrator in your organization +// does not need to write a policy to give users this ability. To compare, administrators who have permission to the +// tenancy can use this operation to create a Swift password for any user, including themselves. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateSwiftPassword.go.html to see an example of how to use CreateSwiftPassword API. +func (client IdentityClient) CreateSwiftPassword(ctx context.Context, request CreateSwiftPasswordRequest) (response CreateSwiftPasswordResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createSwiftPassword, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateSwiftPasswordResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateSwiftPasswordResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateSwiftPasswordResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateSwiftPasswordResponse") + } + return +} + +// createSwiftPassword implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createSwiftPassword(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/users/{userId}/swiftPasswords", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateSwiftPasswordResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateTag Creates a new tag in the specified tag namespace. +// The tag requires either the OCID or the name of the tag namespace that will contain this +// tag definition. +// You must specify a *name* for the tag, which must be unique across all tags in the tag namespace +// and cannot be changed. The name can contain any ASCII character except the space (_) or period (.) characters. +// Names are case insensitive. That means, for example, "myTag" and "mytag" are not allowed in the same namespace. +// If you specify a name that's already in use in the tag namespace, a 409 error is returned. +// The tag must have a *description*. It does not have to be unique, and you can change it with +// UpdateTag. +// The tag must have a value type, which is specified with a validator. Tags can use either a +// static value or a list of possible values. Static values are entered by a user applying the tag +// to a resource. Lists are created by you and the user must apply a value from the list. Lists +// are validiated. +// * If no `validator` is set, the user applying the tag to a resource can type in a static +// value or leave the tag value empty. +// * If a `validator` is set, the user applying the tag to a resource must select from a list +// of values that you supply with EnumTagDefinitionValidator. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateTag.go.html to see an example of how to use CreateTag API. +func (client IdentityClient) CreateTag(ctx context.Context, request CreateTagRequest) (response CreateTagResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createTag, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateTagResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateTagResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateTagResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateTagResponse") + } + return +} + +// createTag implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createTag(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/tagNamespaces/{tagNamespaceId}/tags", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateTagResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateTagDefault Creates a new tag default in the specified compartment for the specified tag definition. +// If you specify that a value is required, a value is set during resource creation (either by +// the user creating the resource or another tag defualt). If no value is set, resource creation +// is blocked. +// * If the `isRequired` flag is set to "true", the value is set during resource creation. +// * If the `isRequired` flag is set to "false", the value you enter is set during resource creation. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateTagDefault.go.html to see an example of how to use CreateTagDefault API. +func (client IdentityClient) CreateTagDefault(ctx context.Context, request CreateTagDefaultRequest) (response CreateTagDefaultResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createTagDefault, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateTagDefaultResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateTagDefaultResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateTagDefaultResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateTagDefaultResponse") + } + return +} + +// createTagDefault implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createTagDefault(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/tagDefaults", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateTagDefaultResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateTagNamespace Creates a new tag namespace in the specified compartment. +// You must specify the compartment ID in the request object (remember that the tenancy is simply the root +// compartment). +// You must also specify a *name* for the namespace, which must be unique across all namespaces in your tenancy +// and cannot be changed. The name can contain any ASCII character except the space (_) or period (.). +// Names are case insensitive. That means, for example, "myNamespace" and "mynamespace" are not allowed +// in the same tenancy. Once you created a namespace, you cannot change the name. +// If you specify a name that's already in use in the tenancy, a 409 error is returned. +// You must also specify a *description* for the namespace. +// It does not have to be unique, and you can change it with +// UpdateTagNamespace. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateTagNamespace.go.html to see an example of how to use CreateTagNamespace API. +func (client IdentityClient) CreateTagNamespace(ctx context.Context, request CreateTagNamespaceRequest) (response CreateTagNamespaceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createTagNamespace, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateTagNamespaceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateTagNamespaceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateTagNamespaceResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateTagNamespaceResponse") + } + return +} + +// createTagNamespace implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createTagNamespace(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/tagNamespaces", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateTagNamespaceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateUser Creates a new user in your tenancy. For conceptual information about users, your tenancy, and other +// IAM Service components, see Overview of the IAM Service (https://docs.cloud.oracle.com/Content/Identity/Concepts/overview.htm). +// You must specify your tenancy's OCID as the compartment ID in the request object (remember that the +// tenancy is simply the root compartment). Notice that IAM resources (users, groups, compartments, and +// some policies) reside within the tenancy itself, unlike cloud resources such as compute instances, +// which typically reside within compartments inside the tenancy. For information about OCIDs, see +// Resource Identifiers (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm). +// You must also specify a *name* for the user, which must be unique across all users in your tenancy +// and cannot be changed. Allowed characters: No spaces. Only letters, numerals, hyphens, periods, +// underscores, +, and @. If you specify a name that's already in use, you'll get a 409 error. +// This name will be the user's login to the Console. You might want to pick a +// name that your company's own identity system (e.g., Active Directory, LDAP, etc.) already uses. +// If you delete a user and then create a new user with the same name, they'll be considered different +// users because they have different OCIDs. +// You must also specify a *description* for the user (although it can be an empty string). +// It does not have to be unique, and you can change it anytime with +// UpdateUser. You can use the field to provide the user's +// full name, a description, a nickname, or other information to generally identify the user. +// After you send your request, the new object's `lifecycleState` will temporarily be CREATING. Before +// using the object, first make sure its `lifecycleState` has changed to ACTIVE. +// A new user has no permissions until you place the user in one or more groups (see +// AddUserToGroup). If the user needs to +// access the Console, you need to provide the user a password (see +// CreateOrResetUIPassword). +// If the user needs to access the Oracle Cloud Infrastructure REST API, you need to upload a +// public API signing key for that user (see +// Required Keys and OCIDs (https://docs.cloud.oracle.com/Content/API/Concepts/apisigningkey.htm) and also +// UploadApiKey). +// **Important:** Make sure to inform the new user which compartment(s) they have access to. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/CreateUser.go.html to see an example of how to use CreateUser API. +func (client IdentityClient) CreateUser(ctx context.Context, request CreateUserRequest) (response CreateUserResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.createUser, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateUserResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateUserResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateUserResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateUserResponse") + } + return +} + +// createUser implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) createUser(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/users", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateUserResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeactivateDomain If the domain's {@code lifecycleState} is ACTIVE and no active Apps are present in domain, +// 1. Set the {@code lifecycleDetails} to DEACTIVATING and asynchronously starts disabling +// the domain and return 202 ACCEPTED. +// 1.1 Sets the domain status to DISABLED and set specified domain's +// {@code lifecycleState} to INACTIVE and set the {@code lifecycleDetails} to null. +// To track progress, HTTP GET on /iamWorkRequests/{iamWorkRequestsId} endpoint will provide +// the async operation's status. Activate a domain can be done using HTTP POST +// /domains/{domainId}/actions/activate. +// - If the domain's {@code lifecycleState} is INACTIVE, returns 202 ACCEPTED with no action +// taken on service side. +// - If domain is of {@code type} DEFAULT or DEFAULT_LIGHTWEIGHT or domain's {@code lifecycleState} +// is not ACTIVE, returns 400 BAD REQUEST. +// - If the domain doesn't exists, returns 404 NOT FOUND. +// - If any active Apps in domain, returns 400 BAD REQUEST. +// - If the authenticated user is part of the domain to be activated, returns 400 BAD REQUEST +// - If error occurs while deactivating domain, returns 500 INTERNAL SERVER ERROR. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeactivateDomain.go.html to see an example of how to use DeactivateDomain API. +func (client IdentityClient) DeactivateDomain(ctx context.Context, request DeactivateDomainRequest) (response DeactivateDomainResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.deactivateDomain, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeactivateDomainResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeactivateDomainResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeactivateDomainResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeactivateDomainResponse") + } + return +} + +// deactivateDomain implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deactivateDomain(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/domains/{domainId}/actions/deactivate", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeactivateDomainResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteApiKey Deletes the specified API signing key for the specified user. +// Every user has permission to use this operation to delete a key for *their own user ID*. An +// administrator in your organization does not need to write a policy to give users this ability. +// To compare, administrators who have permission to the tenancy can use this operation to delete +// a key for any user, including themselves. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteApiKey.go.html to see an example of how to use DeleteApiKey API. +func (client IdentityClient) DeleteApiKey(ctx context.Context, request DeleteApiKeyRequest) (response DeleteApiKeyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteApiKey, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteApiKeyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteApiKeyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteApiKeyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteApiKeyResponse") + } + return +} + +// deleteApiKey implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteApiKey(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/users/{userId}/apiKeys/{fingerprint}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteApiKeyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteAuthToken Deletes the specified auth token for the specified user. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteAuthToken.go.html to see an example of how to use DeleteAuthToken API. +func (client IdentityClient) DeleteAuthToken(ctx context.Context, request DeleteAuthTokenRequest) (response DeleteAuthTokenResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteAuthToken, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteAuthTokenResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteAuthTokenResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteAuthTokenResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteAuthTokenResponse") + } + return +} + +// deleteAuthToken implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteAuthToken(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/users/{userId}/authTokens/{authTokenId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteAuthTokenResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteCompartment Deletes the specified compartment. The compartment must be empty. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteCompartment.go.html to see an example of how to use DeleteCompartment API. +func (client IdentityClient) DeleteCompartment(ctx context.Context, request DeleteCompartmentRequest) (response DeleteCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteCompartmentResponse") + } + return +} + +// deleteCompartment implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/compartments/{compartmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteCustomerSecretKey Deletes the specified secret key for the specified user. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteCustomerSecretKey.go.html to see an example of how to use DeleteCustomerSecretKey API. +func (client IdentityClient) DeleteCustomerSecretKey(ctx context.Context, request DeleteCustomerSecretKeyRequest) (response DeleteCustomerSecretKeyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteCustomerSecretKey, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteCustomerSecretKeyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteCustomerSecretKeyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteCustomerSecretKeyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteCustomerSecretKeyResponse") + } + return +} + +// deleteCustomerSecretKey implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteCustomerSecretKey(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/users/{userId}/customerSecretKeys/{customerSecretKeyId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteCustomerSecretKeyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteDbCredential Deletes the specified DB credential for the specified user. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteDbCredential.go.html to see an example of how to use DeleteDbCredential API. +func (client IdentityClient) DeleteDbCredential(ctx context.Context, request DeleteDbCredentialRequest) (response DeleteDbCredentialResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteDbCredential, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteDbCredentialResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteDbCredentialResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteDbCredentialResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteDbCredentialResponse") + } + return +} + +// deleteDbCredential implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteDbCredential(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/users/{userId}/dbCredentials/{dbCredentialId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteDbCredentialResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteDomain Soft Deletes a domain. +// This is an asynchronous API, where, if the domain's {@code lifecycleState} is INACTIVE and +// no active Apps are present in underlying stripe, +// 1. Sets the specified domain's {@code lifecycleState} to DELETING. +// 2. Domains marked as DELETING will be cleaned up by a periodic task unless customer request it to be undo via ticket. +// 3. Work request is created and returned as opc-work-request-id along with 202 ACCEPTED. +// To track progress, HTTP GET on /iamWorkRequests/{iamWorkRequestsId} endpoint will provide +// the async operation's status. +// - If the domain's {@code lifecycleState} is DELETING, returns 202 Accepted as a deletion +// is already in progress for this domain. +// - If the domain doesn't exists, returns 404 NOT FOUND. +// - If domain is of {@code type} DEFAULT or DEFAULT_LIGHTWEIGHT, returns 400 BAD REQUEST. +// - If any active Apps in domain, returns 400 BAD REQUEST. +// - If the authenticated user is part of the domain to be deleted, returns 400 BAD REQUEST. +// - If any internal error occurs, return 500 INTERNAL SERVER ERROR. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteDomain.go.html to see an example of how to use DeleteDomain API. +func (client IdentityClient) DeleteDomain(ctx context.Context, request DeleteDomainRequest) (response DeleteDomainResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteDomain, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteDomainResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteDomainResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteDomainResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteDomainResponse") + } + return +} + +// deleteDomain implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteDomain(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/domains/{domainId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteDomainResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteDynamicGroup Deletes the specified dynamic group. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteDynamicGroup.go.html to see an example of how to use DeleteDynamicGroup API. +func (client IdentityClient) DeleteDynamicGroup(ctx context.Context, request DeleteDynamicGroupRequest) (response DeleteDynamicGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteDynamicGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteDynamicGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteDynamicGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteDynamicGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteDynamicGroupResponse") + } + return +} + +// deleteDynamicGroup implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteDynamicGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/dynamicGroups/{dynamicGroupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteDynamicGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteGroup Deletes the specified group. The group must be empty. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteGroup.go.html to see an example of how to use DeleteGroup API. +func (client IdentityClient) DeleteGroup(ctx context.Context, request DeleteGroupRequest) (response DeleteGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteGroupResponse") + } + return +} + +// deleteGroup implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/groups/{groupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteIdentityProvider **Deprecated.** For more information, see Deprecated IAM Service APIs (https://docs.cloud.oracle.com/Content/Identity/Reference/deprecatediamapis.htm). +// Deletes the specified identity provider. The identity provider must not have +// any group mappings (see IdpGroupMapping). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteIdentityProvider.go.html to see an example of how to use DeleteIdentityProvider API. +func (client IdentityClient) DeleteIdentityProvider(ctx context.Context, request DeleteIdentityProviderRequest) (response DeleteIdentityProviderResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteIdentityProvider, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteIdentityProviderResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteIdentityProviderResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteIdentityProviderResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteIdentityProviderResponse") + } + return +} + +// deleteIdentityProvider implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteIdentityProvider(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/identityProviders/{identityProviderId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteIdentityProviderResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteIdpGroupMapping **Deprecated.** For more information, see Deprecated IAM Service APIs (https://docs.cloud.oracle.com/Content/Identity/Reference/deprecatediamapis.htm). +// Deletes the specified group mapping. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteIdpGroupMapping.go.html to see an example of how to use DeleteIdpGroupMapping API. +func (client IdentityClient) DeleteIdpGroupMapping(ctx context.Context, request DeleteIdpGroupMappingRequest) (response DeleteIdpGroupMappingResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteIdpGroupMapping, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteIdpGroupMappingResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteIdpGroupMappingResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteIdpGroupMappingResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteIdpGroupMappingResponse") + } + return +} + +// deleteIdpGroupMapping implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteIdpGroupMapping(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/identityProviders/{identityProviderId}/groupMappings/{mappingId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteIdpGroupMappingResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteMfaTotpDevice Deletes the specified MFA TOTP device for the specified user. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteMfaTotpDevice.go.html to see an example of how to use DeleteMfaTotpDevice API. +func (client IdentityClient) DeleteMfaTotpDevice(ctx context.Context, request DeleteMfaTotpDeviceRequest) (response DeleteMfaTotpDeviceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteMfaTotpDevice, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteMfaTotpDeviceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteMfaTotpDeviceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteMfaTotpDeviceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteMfaTotpDeviceResponse") + } + return +} + +// deleteMfaTotpDevice implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteMfaTotpDevice(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/users/{userId}/mfaTotpDevices/{mfaTotpDeviceId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteMfaTotpDeviceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteNetworkSource Deletes the specified network source +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteNetworkSource.go.html to see an example of how to use DeleteNetworkSource API. +func (client IdentityClient) DeleteNetworkSource(ctx context.Context, request DeleteNetworkSourceRequest) (response DeleteNetworkSourceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteNetworkSource, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteNetworkSourceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteNetworkSourceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteNetworkSourceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteNetworkSourceResponse") + } + return +} + +// deleteNetworkSource implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteNetworkSource(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/networkSources/{networkSourceId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteNetworkSourceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteOAuthClientCredential Delete Oauth token for the user +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteOAuthClientCredential.go.html to see an example of how to use DeleteOAuthClientCredential API. +func (client IdentityClient) DeleteOAuthClientCredential(ctx context.Context, request DeleteOAuthClientCredentialRequest) (response DeleteOAuthClientCredentialResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteOAuthClientCredential, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteOAuthClientCredentialResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteOAuthClientCredentialResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteOAuthClientCredentialResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteOAuthClientCredentialResponse") + } + return +} + +// deleteOAuthClientCredential implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteOAuthClientCredential(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/users/{userId}/oauth2ClientCredentials/{oauth2ClientCredentialId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteOAuthClientCredentialResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeletePolicy Deletes the specified policy. The deletion takes effect typically within 10 seconds. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeletePolicy.go.html to see an example of how to use DeletePolicy API. +func (client IdentityClient) DeletePolicy(ctx context.Context, request DeletePolicyRequest) (response DeletePolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deletePolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeletePolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeletePolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeletePolicyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeletePolicyResponse") + } + return +} + +// deletePolicy implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deletePolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/policies/{policyId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeletePolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteSmtpCredential Deletes the specified SMTP credential for the specified user. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteSmtpCredential.go.html to see an example of how to use DeleteSmtpCredential API. +func (client IdentityClient) DeleteSmtpCredential(ctx context.Context, request DeleteSmtpCredentialRequest) (response DeleteSmtpCredentialResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteSmtpCredential, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteSmtpCredentialResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteSmtpCredentialResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteSmtpCredentialResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteSmtpCredentialResponse") + } + return +} + +// deleteSmtpCredential implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteSmtpCredential(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/users/{userId}/smtpCredentials/{smtpCredentialId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteSmtpCredentialResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteSwiftPassword **Deprecated. Use DeleteAuthToken instead.** +// Deletes the specified Swift password for the specified user. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteSwiftPassword.go.html to see an example of how to use DeleteSwiftPassword API. +func (client IdentityClient) DeleteSwiftPassword(ctx context.Context, request DeleteSwiftPasswordRequest) (response DeleteSwiftPasswordResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteSwiftPassword, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteSwiftPasswordResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteSwiftPasswordResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteSwiftPasswordResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteSwiftPasswordResponse") + } + return +} + +// deleteSwiftPassword implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteSwiftPassword(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/users/{userId}/swiftPasswords/{swiftPasswordId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteSwiftPasswordResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteTag Deletes the specified tag definition. This operation triggers a process that removes the +// tag from all resources in your tenancy. +// These things happen immediately: +// +// * If the tag was a cost-tracking tag, it no longer counts against your 10 cost-tracking +// tags limit, whether you first disabled it or not. +// * If the tag was used with dynamic groups, none of the rules that contain the tag will +// be evaluated against the tag. +// When you start the delete operation, the state of the tag changes to DELETING and tag removal +// from resources begins. This can take up to 48 hours depending on the number of resources that +// were tagged as well as the regions in which those resources reside. +// When all tags have been removed, the state changes to DELETED. You cannot restore a deleted tag. Once the deleted tag +// changes its state to DELETED, you can use the same tag name again. +// After you start this operation, you cannot start either the BulkDeleteTags or the CascadeDeleteTagNamespace operation until this process completes. +// To delete a tag, you must first retire it. Use UpdateTag +// to retire a tag. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteTag.go.html to see an example of how to use DeleteTag API. +func (client IdentityClient) DeleteTag(ctx context.Context, request DeleteTagRequest) (response DeleteTagResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteTag, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteTagResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteTagResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteTagResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteTagResponse") + } + return +} + +// deleteTag implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteTag(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/tagNamespaces/{tagNamespaceId}/tags/{tagName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteTagResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteTagDefault Deletes the the specified tag default. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteTagDefault.go.html to see an example of how to use DeleteTagDefault API. +func (client IdentityClient) DeleteTagDefault(ctx context.Context, request DeleteTagDefaultRequest) (response DeleteTagDefaultResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteTagDefault, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteTagDefaultResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteTagDefaultResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteTagDefaultResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteTagDefaultResponse") + } + return +} + +// deleteTagDefault implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteTagDefault(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/tagDefaults/{tagDefaultId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteTagDefaultResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteTagNamespace Deletes the specified tag namespace. Only an empty tag namespace can be deleted with this operation. To use this operation +// to delete a tag namespace that contains tag definitions, first delete all of its tag definitions. +// Use CascadeDeleteTagNamespace to delete a tag namespace along with all of +// the tag definitions contained within that namespace. +// Use DeleteTag to delete a tag definition. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteTagNamespace.go.html to see an example of how to use DeleteTagNamespace API. +func (client IdentityClient) DeleteTagNamespace(ctx context.Context, request DeleteTagNamespaceRequest) (response DeleteTagNamespaceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteTagNamespace, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteTagNamespaceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteTagNamespaceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteTagNamespaceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteTagNamespaceResponse") + } + return +} + +// deleteTagNamespace implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteTagNamespace(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/tagNamespaces/{tagNamespaceId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteTagNamespaceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteUser Deletes the specified user. The user must not be in any groups. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/DeleteUser.go.html to see an example of how to use DeleteUser API. +func (client IdentityClient) DeleteUser(ctx context.Context, request DeleteUserRequest) (response DeleteUserResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteUser, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteUserResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteUserResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteUserResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteUserResponse") + } + return +} + +// deleteUser implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) deleteUser(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/users/{userId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteUserResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// EnableReplicationToRegion Replicate domain to a new region. This is an asynchronous call - where, at start, +// {@code state} of this domain in replica region is set to ENABLING_REPLICATION. +// On domain replication completion the {@code state} will be set to REPLICATION_ENABLED. +// To track progress, HTTP GET on /iamWorkRequests/{iamWorkRequestsId} endpoint will provide +// the async operation's status. +// If the replica region's {@code state} is already ENABLING_REPLICATION or REPLICATION_ENABLED, +// returns 409 CONFLICT. +// - If the domain doesn't exists, returns 404 NOT FOUND. +// - If home region is same as replication region, return 400 BAD REQUEST. +// - If Domain is not active or being updated, returns 400 BAD REQUEST. +// - If any internal error occurs, return 500 INTERNAL SERVER ERROR. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/EnableReplicationToRegion.go.html to see an example of how to use EnableReplicationToRegion API. +func (client IdentityClient) EnableReplicationToRegion(ctx context.Context, request EnableReplicationToRegionRequest) (response EnableReplicationToRegionResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.enableReplicationToRegion, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = EnableReplicationToRegionResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = EnableReplicationToRegionResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(EnableReplicationToRegionResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into EnableReplicationToRegionResponse") + } + return +} + +// enableReplicationToRegion implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) enableReplicationToRegion(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/domains/{domainId}/actions/enableReplicationToRegion", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response EnableReplicationToRegionResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GenerateTotpSeed Generate seed for the MFA TOTP device. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GenerateTotpSeed.go.html to see an example of how to use GenerateTotpSeed API. +func (client IdentityClient) GenerateTotpSeed(ctx context.Context, request GenerateTotpSeedRequest) (response GenerateTotpSeedResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.generateTotpSeed, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GenerateTotpSeedResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GenerateTotpSeedResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GenerateTotpSeedResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GenerateTotpSeedResponse") + } + return +} + +// generateTotpSeed implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) generateTotpSeed(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/users/{userId}/mfaTotpDevices/{mfaTotpDeviceId}/actions/generateSeed", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GenerateTotpSeedResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetAuthenticationPolicy Gets the authentication policy for the given tenancy. You must specify your tenant’s OCID as the value for +// the compartment ID (remember that the tenancy is simply the root compartment). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetAuthenticationPolicy.go.html to see an example of how to use GetAuthenticationPolicy API. +func (client IdentityClient) GetAuthenticationPolicy(ctx context.Context, request GetAuthenticationPolicyRequest) (response GetAuthenticationPolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getAuthenticationPolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetAuthenticationPolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetAuthenticationPolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetAuthenticationPolicyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetAuthenticationPolicyResponse") + } + return +} + +// getAuthenticationPolicy implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getAuthenticationPolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/authenticationPolicies/{compartmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetAuthenticationPolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetCompartment Gets the specified compartment's information. +// This operation does not return a list of all the resources inside the compartment. There is no single +// API operation that does that. Compartments can contain multiple types of resources (instances, block +// storage volumes, etc.). To find out what's in a compartment, you must call the "List" operation for +// each resource type and specify the compartment's OCID as a query parameter in the request. For example, +// call the ListInstances operation in the Cloud Compute +// Service or the ListVolumes operation in Cloud Block Storage. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetCompartment.go.html to see an example of how to use GetCompartment API. +func (client IdentityClient) GetCompartment(ctx context.Context, request GetCompartmentRequest) (response GetCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetCompartmentResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetCompartmentResponse") + } + return +} + +// getCompartment implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/compartments/{compartmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetDomain Get the specified domain's information. +// - If the domain doesn't exists, returns 404 NOT FOUND. +// - If any internal error occurs, returns 500 INTERNAL SERVER ERROR. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetDomain.go.html to see an example of how to use GetDomain API. +func (client IdentityClient) GetDomain(ctx context.Context, request GetDomainRequest) (response GetDomainResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getDomain, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetDomainResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetDomainResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetDomainResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetDomainResponse") + } + return +} + +// getDomain implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getDomain(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/domains/{domainId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetDomainResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetDynamicGroup Gets the specified dynamic group's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetDynamicGroup.go.html to see an example of how to use GetDynamicGroup API. +func (client IdentityClient) GetDynamicGroup(ctx context.Context, request GetDynamicGroupRequest) (response GetDynamicGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getDynamicGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetDynamicGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetDynamicGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetDynamicGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetDynamicGroupResponse") + } + return +} + +// getDynamicGroup implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getDynamicGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/dynamicGroups/{dynamicGroupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetDynamicGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetGroup Gets the specified group's information. +// This operation does not return a list of all the users in the group. To do that, use +// ListUserGroupMemberships and +// provide the group's OCID as a query parameter in the request. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetGroup.go.html to see an example of how to use GetGroup API. +func (client IdentityClient) GetGroup(ctx context.Context, request GetGroupRequest) (response GetGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetGroupResponse") + } + return +} + +// getGroup implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/groups/{groupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetIamWorkRequest Gets details on a specified IAM work request. For asynchronous operations in Identity and Access Management service, opc-work-request-id header values contains +// iam work request id that can be provided in this API to track the current status of the operation. +// - If workrequest exists, returns 202 ACCEPTED +// - If workrequest does not exist, returns 404 NOT FOUND +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetIamWorkRequest.go.html to see an example of how to use GetIamWorkRequest API. +func (client IdentityClient) GetIamWorkRequest(ctx context.Context, request GetIamWorkRequestRequest) (response GetIamWorkRequestResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getIamWorkRequest, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetIamWorkRequestResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetIamWorkRequestResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetIamWorkRequestResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetIamWorkRequestResponse") + } + return +} + +// getIamWorkRequest implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getIamWorkRequest(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/iamWorkRequests/{iamWorkRequestId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetIamWorkRequestResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetIdentityProvider **Deprecated.** For more information, see Deprecated IAM Service APIs (https://docs.cloud.oracle.com/Content/Identity/Reference/deprecatediamapis.htm). +// Gets the specified identity provider's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetIdentityProvider.go.html to see an example of how to use GetIdentityProvider API. +func (client IdentityClient) GetIdentityProvider(ctx context.Context, request GetIdentityProviderRequest) (response GetIdentityProviderResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getIdentityProvider, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetIdentityProviderResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetIdentityProviderResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetIdentityProviderResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetIdentityProviderResponse") + } + return +} + +// getIdentityProvider implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getIdentityProvider(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/identityProviders/{identityProviderId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetIdentityProviderResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponseWithPolymorphicBody(httpResponse, &response, &identityprovider{}) + return response, err +} + +// GetIdpGroupMapping **Deprecated.** For more information, see Deprecated IAM Service APIs (https://docs.cloud.oracle.com/Content/Identity/Reference/deprecatediamapis.htm). +// Gets the specified group mapping. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetIdpGroupMapping.go.html to see an example of how to use GetIdpGroupMapping API. +func (client IdentityClient) GetIdpGroupMapping(ctx context.Context, request GetIdpGroupMappingRequest) (response GetIdpGroupMappingResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getIdpGroupMapping, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetIdpGroupMappingResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetIdpGroupMappingResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetIdpGroupMappingResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetIdpGroupMappingResponse") + } + return +} + +// getIdpGroupMapping implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getIdpGroupMapping(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/identityProviders/{identityProviderId}/groupMappings/{mappingId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetIdpGroupMappingResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetMfaTotpDevice Get the specified MFA TOTP device for the specified user. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetMfaTotpDevice.go.html to see an example of how to use GetMfaTotpDevice API. +func (client IdentityClient) GetMfaTotpDevice(ctx context.Context, request GetMfaTotpDeviceRequest) (response GetMfaTotpDeviceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getMfaTotpDevice, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetMfaTotpDeviceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetMfaTotpDeviceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetMfaTotpDeviceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetMfaTotpDeviceResponse") + } + return +} + +// getMfaTotpDevice implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getMfaTotpDevice(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/users/{userId}/mfaTotpDevices/{mfaTotpDeviceId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetMfaTotpDeviceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetNetworkSource Gets the specified network source's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetNetworkSource.go.html to see an example of how to use GetNetworkSource API. +func (client IdentityClient) GetNetworkSource(ctx context.Context, request GetNetworkSourceRequest) (response GetNetworkSourceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getNetworkSource, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetNetworkSourceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetNetworkSourceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetNetworkSourceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetNetworkSourceResponse") + } + return +} + +// getNetworkSource implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getNetworkSource(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/networkSources/{networkSourceId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetNetworkSourceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetPolicy Gets the specified policy's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetPolicy.go.html to see an example of how to use GetPolicy API. +func (client IdentityClient) GetPolicy(ctx context.Context, request GetPolicyRequest) (response GetPolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getPolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetPolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetPolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetPolicyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetPolicyResponse") + } + return +} + +// getPolicy implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getPolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/policies/{policyId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetPolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetStandardTagTemplate Retrieve the standard tag namespace template given the standard tag namespace name. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetStandardTagTemplate.go.html to see an example of how to use GetStandardTagTemplate API. +func (client IdentityClient) GetStandardTagTemplate(ctx context.Context, request GetStandardTagTemplateRequest) (response GetStandardTagTemplateResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getStandardTagTemplate, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetStandardTagTemplateResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetStandardTagTemplateResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetStandardTagTemplateResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetStandardTagTemplateResponse") + } + return +} + +// getStandardTagTemplate implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getStandardTagTemplate(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/tags/standardTagNamespaceTemplates/{standardTagNamespaceName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetStandardTagTemplateResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetTag Gets the specified tag's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetTag.go.html to see an example of how to use GetTag API. +func (client IdentityClient) GetTag(ctx context.Context, request GetTagRequest) (response GetTagResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getTag, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetTagResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetTagResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetTagResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetTagResponse") + } + return +} + +// getTag implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getTag(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/tagNamespaces/{tagNamespaceId}/tags/{tagName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetTagResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetTagDefault Retrieves the specified tag default. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetTagDefault.go.html to see an example of how to use GetTagDefault API. +func (client IdentityClient) GetTagDefault(ctx context.Context, request GetTagDefaultRequest) (response GetTagDefaultResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getTagDefault, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetTagDefaultResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetTagDefaultResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetTagDefaultResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetTagDefaultResponse") + } + return +} + +// getTagDefault implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getTagDefault(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/tagDefaults/{tagDefaultId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetTagDefaultResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetTagNamespace Gets the specified tag namespace's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetTagNamespace.go.html to see an example of how to use GetTagNamespace API. +func (client IdentityClient) GetTagNamespace(ctx context.Context, request GetTagNamespaceRequest) (response GetTagNamespaceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getTagNamespace, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetTagNamespaceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetTagNamespaceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetTagNamespaceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetTagNamespaceResponse") + } + return +} + +// getTagNamespace implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getTagNamespace(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/tagNamespaces/{tagNamespaceId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetTagNamespaceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetTaggingWorkRequest Gets details on a specified work request. The workRequestID is returned in the opc-workrequest-id header +// for any asynchronous operation in tagging service. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetTaggingWorkRequest.go.html to see an example of how to use GetTaggingWorkRequest API. +func (client IdentityClient) GetTaggingWorkRequest(ctx context.Context, request GetTaggingWorkRequestRequest) (response GetTaggingWorkRequestResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getTaggingWorkRequest, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetTaggingWorkRequestResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetTaggingWorkRequestResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetTaggingWorkRequestResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetTaggingWorkRequestResponse") + } + return +} + +// getTaggingWorkRequest implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getTaggingWorkRequest(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/taggingWorkRequests/{workRequestId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetTaggingWorkRequestResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetTenancy Get the specified tenancy's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetTenancy.go.html to see an example of how to use GetTenancy API. +func (client IdentityClient) GetTenancy(ctx context.Context, request GetTenancyRequest) (response GetTenancyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getTenancy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetTenancyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetTenancyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetTenancyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetTenancyResponse") + } + return +} + +// getTenancy implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getTenancy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/tenancies/{tenancyId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetTenancyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetUser Gets the specified user's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetUser.go.html to see an example of how to use GetUser API. +func (client IdentityClient) GetUser(ctx context.Context, request GetUserRequest) (response GetUserResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getUser, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetUserResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetUserResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetUserResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetUserResponse") + } + return +} + +// getUser implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getUser(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/users/{userId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetUserResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetUserGroupMembership Gets the specified UserGroupMembership's information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetUserGroupMembership.go.html to see an example of how to use GetUserGroupMembership API. +func (client IdentityClient) GetUserGroupMembership(ctx context.Context, request GetUserGroupMembershipRequest) (response GetUserGroupMembershipResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getUserGroupMembership, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetUserGroupMembershipResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetUserGroupMembershipResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetUserGroupMembershipResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetUserGroupMembershipResponse") + } + return +} + +// getUserGroupMembership implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getUserGroupMembership(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/userGroupMemberships/{userGroupMembershipId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetUserGroupMembershipResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetUserUIPasswordInformation Gets the specified user's console password information. The returned object contains the user's OCID, +// but not the password itself. The actual password is returned only when created or reset. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetUserUIPasswordInformation.go.html to see an example of how to use GetUserUIPasswordInformation API. +func (client IdentityClient) GetUserUIPasswordInformation(ctx context.Context, request GetUserUIPasswordInformationRequest) (response GetUserUIPasswordInformationResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getUserUIPasswordInformation, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetUserUIPasswordInformationResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetUserUIPasswordInformationResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetUserUIPasswordInformationResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetUserUIPasswordInformationResponse") + } + return +} + +// getUserUIPasswordInformation implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getUserUIPasswordInformation(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/users/{userId}/uiPassword", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetUserUIPasswordInformationResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetWorkRequest Gets details on a specified work request. The workRequestID is returned in the opc-workrequest-id header +// for any asynchronous operation in the compartment service. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/GetWorkRequest.go.html to see an example of how to use GetWorkRequest API. +func (client IdentityClient) GetWorkRequest(ctx context.Context, request GetWorkRequestRequest) (response GetWorkRequestResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getWorkRequest, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetWorkRequestResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetWorkRequestResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetWorkRequestResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetWorkRequestResponse") + } + return +} + +// getWorkRequest implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) getWorkRequest(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/workRequests/{workRequestId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetWorkRequestResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ImportStandardTags OCI will release Tag Namespaces that our customers can import. +// These Tag Namespaces will provide Tags for our customers and Partners to provide consistency and enable data reporting. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ImportStandardTags.go.html to see an example of how to use ImportStandardTags API. +func (client IdentityClient) ImportStandardTags(ctx context.Context, request ImportStandardTagsRequest) (response ImportStandardTagsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.importStandardTags, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ImportStandardTagsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ImportStandardTagsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ImportStandardTagsResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ImportStandardTagsResponse") + } + return +} + +// importStandardTags implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) importStandardTags(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/tags/actions/importStandardTags", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ImportStandardTagsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListAllowedDomainLicenseTypes List the allowed domain license types supported by OCI +// If {@code currentLicenseTypeName} provided, returns allowed license types a domain with the specified license type name can migrate to. +// If {@code name} is provided, it filters and returns resources that match the given license type name. +// Otherwise, returns all valid license types that are currently supported. +// - If license type details are retrieved sucessfully, return 202 ACCEPTED. +// - If any internal error occurs, return 500 INTERNAL SERVER ERROR. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListAllowedDomainLicenseTypes.go.html to see an example of how to use ListAllowedDomainLicenseTypes API. +func (client IdentityClient) ListAllowedDomainLicenseTypes(ctx context.Context, request ListAllowedDomainLicenseTypesRequest) (response ListAllowedDomainLicenseTypesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listAllowedDomainLicenseTypes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListAllowedDomainLicenseTypesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListAllowedDomainLicenseTypesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListAllowedDomainLicenseTypesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListAllowedDomainLicenseTypesResponse") + } + return +} + +// listAllowedDomainLicenseTypes implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listAllowedDomainLicenseTypes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/allowedDomainLicenseTypes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListAllowedDomainLicenseTypesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListApiKeys Lists the API signing keys for the specified user. A user can have a maximum of three keys. +// Every user has permission to use this API call for *their own user ID*. An administrator in your +// organization does not need to write a policy to give users this ability. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListApiKeys.go.html to see an example of how to use ListApiKeys API. +func (client IdentityClient) ListApiKeys(ctx context.Context, request ListApiKeysRequest) (response ListApiKeysResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listApiKeys, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListApiKeysResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListApiKeysResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListApiKeysResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListApiKeysResponse") + } + return +} + +// listApiKeys implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listApiKeys(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/users/{userId}/apiKeys", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListApiKeysResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListAuthTokens Lists the auth tokens for the specified user. The returned object contains the token's OCID, but not +// the token itself. The actual token is returned only upon creation. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListAuthTokens.go.html to see an example of how to use ListAuthTokens API. +func (client IdentityClient) ListAuthTokens(ctx context.Context, request ListAuthTokensRequest) (response ListAuthTokensResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listAuthTokens, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListAuthTokensResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListAuthTokensResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListAuthTokensResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListAuthTokensResponse") + } + return +} + +// listAuthTokens implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listAuthTokens(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/users/{userId}/authTokens", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListAuthTokensResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListAvailabilityDomains Lists the availability domains in your tenancy. Specify the OCID of either the tenancy or another +// of your compartments as the value for the compartment ID (remember that the tenancy is simply the root compartment). +// See Where to Get the Tenancy's OCID and User's OCID (https://docs.cloud.oracle.com/Content/API/Concepts/apisigningkey.htm#five). +// Note that the order of the results returned can change if availability domains are added or removed; therefore, do not +// create a dependency on the list order. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListAvailabilityDomains.go.html to see an example of how to use ListAvailabilityDomains API. +func (client IdentityClient) ListAvailabilityDomains(ctx context.Context, request ListAvailabilityDomainsRequest) (response ListAvailabilityDomainsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listAvailabilityDomains, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListAvailabilityDomainsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListAvailabilityDomainsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListAvailabilityDomainsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListAvailabilityDomainsResponse") + } + return +} + +// listAvailabilityDomains implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listAvailabilityDomains(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/availabilityDomains", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListAvailabilityDomainsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListBulkActionResourceTypes Lists the resource-types supported by compartment bulk actions. Use this API to help you provide the correct +// resource-type information to the BulkDeleteResources +// and BulkMoveResources operations. The returned list of +// resource-types provides the appropriate resource-type names to use with the bulk action operations along with +// the type of identifying information you'll need to provide for each resource-type. Most resource-types just +// require an OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) to identify a specific resource, but some resource-types, +// such as buckets, require you to provide other identifying information. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListBulkActionResourceTypes.go.html to see an example of how to use ListBulkActionResourceTypes API. +func (client IdentityClient) ListBulkActionResourceTypes(ctx context.Context, request ListBulkActionResourceTypesRequest) (response ListBulkActionResourceTypesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listBulkActionResourceTypes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListBulkActionResourceTypesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListBulkActionResourceTypesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListBulkActionResourceTypesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListBulkActionResourceTypesResponse") + } + return +} + +// listBulkActionResourceTypes implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listBulkActionResourceTypes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/compartments/bulkActionResourceTypes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListBulkActionResourceTypesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListBulkEditTagsResourceTypes Lists the resource types that support bulk tag editing. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListBulkEditTagsResourceTypes.go.html to see an example of how to use ListBulkEditTagsResourceTypes API. +func (client IdentityClient) ListBulkEditTagsResourceTypes(ctx context.Context, request ListBulkEditTagsResourceTypesRequest) (response ListBulkEditTagsResourceTypesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listBulkEditTagsResourceTypes, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListBulkEditTagsResourceTypesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListBulkEditTagsResourceTypesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListBulkEditTagsResourceTypesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListBulkEditTagsResourceTypesResponse") + } + return +} + +// listBulkEditTagsResourceTypes implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listBulkEditTagsResourceTypes(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/tags/bulkEditResourceTypes", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListBulkEditTagsResourceTypesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListCompartments Lists the compartments in a specified compartment. The members of the list +// returned depends on the values set for several parameters. +// With the exception of the tenancy (root compartment), the ListCompartments operation +// returns only the first-level child compartments in the parent compartment specified in +// `compartmentId`. The list does not include any subcompartments of the child +// compartments (grandchildren). +// The parameter `accessLevel` specifies whether to return only those compartments for which the +// requestor has INSPECT permissions on at least one resource directly +// or indirectly (the resource can be in a subcompartment). +// The parameter `compartmentIdInSubtree` applies only when you perform ListCompartments on the +// tenancy (root compartment). When set to true, the entire hierarchy of compartments can be returned. +// To get a full list of all compartments and subcompartments in the tenancy (root compartment), +// set the parameter `compartmentIdInSubtree` to true and `accessLevel` to ANY. +// See Where to Get the Tenancy's OCID and User's OCID (https://docs.cloud.oracle.com/Content/API/Concepts/apisigningkey.htm#five). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListCompartments.go.html to see an example of how to use ListCompartments API. +func (client IdentityClient) ListCompartments(ctx context.Context, request ListCompartmentsRequest) (response ListCompartmentsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listCompartments, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListCompartmentsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListCompartmentsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListCompartmentsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListCompartmentsResponse") + } + return +} + +// listCompartments implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listCompartments(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/compartments", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListCompartmentsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListCostTrackingTags Lists all the tags enabled for cost-tracking in the specified tenancy. For information about +// cost-tracking tags, see Using Cost-tracking Tags (https://docs.cloud.oracle.com/Content/Identity/Concepts/taggingoverview.htm#costs). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListCostTrackingTags.go.html to see an example of how to use ListCostTrackingTags API. +func (client IdentityClient) ListCostTrackingTags(ctx context.Context, request ListCostTrackingTagsRequest) (response ListCostTrackingTagsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listCostTrackingTags, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListCostTrackingTagsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListCostTrackingTagsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListCostTrackingTagsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListCostTrackingTagsResponse") + } + return +} + +// listCostTrackingTags implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listCostTrackingTags(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/tagNamespaces/actions/listCostTrackingTags", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListCostTrackingTagsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListCustomerSecretKeys Lists the secret keys for the specified user. The returned object contains the secret key's OCID, but not +// the secret key itself. The actual secret key is returned only upon creation. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListCustomerSecretKeys.go.html to see an example of how to use ListCustomerSecretKeys API. +func (client IdentityClient) ListCustomerSecretKeys(ctx context.Context, request ListCustomerSecretKeysRequest) (response ListCustomerSecretKeysResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listCustomerSecretKeys, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListCustomerSecretKeysResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListCustomerSecretKeysResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListCustomerSecretKeysResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListCustomerSecretKeysResponse") + } + return +} + +// listCustomerSecretKeys implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listCustomerSecretKeys(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/users/{userId}/customerSecretKeys", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListCustomerSecretKeysResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListDbCredentials Lists the DB credentials for the specified user. The returned object contains the credential's OCID +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListDbCredentials.go.html to see an example of how to use ListDbCredentials API. +func (client IdentityClient) ListDbCredentials(ctx context.Context, request ListDbCredentialsRequest) (response ListDbCredentialsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listDbCredentials, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListDbCredentialsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListDbCredentialsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListDbCredentialsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListDbCredentialsResponse") + } + return +} + +// listDbCredentials implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listDbCredentials(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/users/{userId}/dbCredentials", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListDbCredentialsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListDomains List all domains that are homed or have a replica region in current region. +// - If any internal error occurs, return 500 INTERNAL SERVER ERROR. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListDomains.go.html to see an example of how to use ListDomains API. +func (client IdentityClient) ListDomains(ctx context.Context, request ListDomainsRequest) (response ListDomainsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listDomains, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListDomainsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListDomainsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListDomainsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListDomainsResponse") + } + return +} + +// listDomains implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listDomains(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/domains", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListDomainsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListDynamicGroups Lists the dynamic groups in your tenancy. You must specify your tenancy's OCID as the value for +// the compartment ID (remember that the tenancy is simply the root compartment). +// See Where to Get the Tenancy's OCID and User's OCID (https://docs.cloud.oracle.com/Content/API/Concepts/apisigningkey.htm#five). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListDynamicGroups.go.html to see an example of how to use ListDynamicGroups API. +func (client IdentityClient) ListDynamicGroups(ctx context.Context, request ListDynamicGroupsRequest) (response ListDynamicGroupsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listDynamicGroups, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListDynamicGroupsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListDynamicGroupsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListDynamicGroupsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListDynamicGroupsResponse") + } + return +} + +// listDynamicGroups implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listDynamicGroups(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/dynamicGroups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListDynamicGroupsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListFaultDomains Lists the Fault Domains in your tenancy. Specify the OCID of either the tenancy or another +// of your compartments as the value for the compartment ID (remember that the tenancy is simply the root compartment). +// See Where to Get the Tenancy's OCID and User's OCID (https://docs.cloud.oracle.com/Content/API/Concepts/apisigningkey.htm#five). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListFaultDomains.go.html to see an example of how to use ListFaultDomains API. +func (client IdentityClient) ListFaultDomains(ctx context.Context, request ListFaultDomainsRequest) (response ListFaultDomainsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listFaultDomains, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListFaultDomainsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListFaultDomainsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListFaultDomainsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListFaultDomainsResponse") + } + return +} + +// listFaultDomains implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listFaultDomains(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/faultDomains", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListFaultDomainsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListGroups Lists the groups in your tenancy. You must specify your tenancy's OCID as the value for +// the compartment ID (remember that the tenancy is simply the root compartment). +// See Where to Get the Tenancy's OCID and User's OCID (https://docs.cloud.oracle.com/Content/API/Concepts/apisigningkey.htm#five). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListGroups.go.html to see an example of how to use ListGroups API. +func (client IdentityClient) ListGroups(ctx context.Context, request ListGroupsRequest) (response ListGroupsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listGroups, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListGroupsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListGroupsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListGroupsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListGroupsResponse") + } + return +} + +// listGroups implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listGroups(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/groups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListGroupsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListIamWorkRequestErrors Gets error details for a specified IAM work request. For asynchronous operations in Identity and Access Management service, opc-work-request-id header values contains +// iam work request id that can be provided in this API to track the current status of the operation. +// - If workrequest exists, returns 202 ACCEPTED +// - If workrequest does not exist, returns 404 NOT FOUND +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListIamWorkRequestErrors.go.html to see an example of how to use ListIamWorkRequestErrors API. +func (client IdentityClient) ListIamWorkRequestErrors(ctx context.Context, request ListIamWorkRequestErrorsRequest) (response ListIamWorkRequestErrorsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listIamWorkRequestErrors, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListIamWorkRequestErrorsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListIamWorkRequestErrorsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListIamWorkRequestErrorsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListIamWorkRequestErrorsResponse") + } + return +} + +// listIamWorkRequestErrors implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listIamWorkRequestErrors(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/iamWorkRequests/{iamWorkRequestId}/errors", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListIamWorkRequestErrorsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListIamWorkRequestLogs Gets logs for a specified IAM work request. For asynchronous operations in Identity and Access Management service, opc-work-request-id header values contains +// iam work request id that can be provided in this API to track the current status of the operation. +// - If workrequest exists, returns 202 ACCEPTED +// - If workrequest does not exist, returns 404 NOT FOUND +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListIamWorkRequestLogs.go.html to see an example of how to use ListIamWorkRequestLogs API. +func (client IdentityClient) ListIamWorkRequestLogs(ctx context.Context, request ListIamWorkRequestLogsRequest) (response ListIamWorkRequestLogsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listIamWorkRequestLogs, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListIamWorkRequestLogsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListIamWorkRequestLogsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListIamWorkRequestLogsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListIamWorkRequestLogsResponse") + } + return +} + +// listIamWorkRequestLogs implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listIamWorkRequestLogs(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/iamWorkRequests/{iamWorkRequestId}/logs", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListIamWorkRequestLogsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListIamWorkRequests List the IAM work requests in compartment +// - If IAM workrequest details are retrieved sucessfully, return 202 ACCEPTED. +// - If any internal error occurs, return 500 INTERNAL SERVER ERROR. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListIamWorkRequests.go.html to see an example of how to use ListIamWorkRequests API. +func (client IdentityClient) ListIamWorkRequests(ctx context.Context, request ListIamWorkRequestsRequest) (response ListIamWorkRequestsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listIamWorkRequests, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListIamWorkRequestsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListIamWorkRequestsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListIamWorkRequestsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListIamWorkRequestsResponse") + } + return +} + +// listIamWorkRequests implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listIamWorkRequests(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/iamWorkRequests", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListIamWorkRequestsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListIdentityProviderGroups **Deprecated.** For more information, see Deprecated IAM Service APIs (https://docs.cloud.oracle.com/Content/Identity/Reference/deprecatediamapis.htm). +// Lists the identity provider groups. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListIdentityProviderGroups.go.html to see an example of how to use ListIdentityProviderGroups API. +func (client IdentityClient) ListIdentityProviderGroups(ctx context.Context, request ListIdentityProviderGroupsRequest) (response ListIdentityProviderGroupsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listIdentityProviderGroups, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListIdentityProviderGroupsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListIdentityProviderGroupsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListIdentityProviderGroupsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListIdentityProviderGroupsResponse") + } + return +} + +// listIdentityProviderGroups implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listIdentityProviderGroups(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/identityProviders/{identityProviderId}/groups", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListIdentityProviderGroupsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +//listidentityprovider allows to unmarshal list of polymorphic IdentityProvider +type listidentityprovider []identityprovider + +//UnmarshalPolymorphicJSON unmarshals polymorphic json list of items +func (m *listidentityprovider) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + res := make([]IdentityProvider, len(*m)) + for i, v := range *m { + nn, err := v.UnmarshalPolymorphicJSON(v.JsonData) + if err != nil { + return nil, err + } + res[i] = nn.(IdentityProvider) + } + return res, nil +} + +// ListIdentityProviders **Deprecated.** For more information, see Deprecated IAM Service APIs (https://docs.cloud.oracle.com/Content/Identity/Reference/deprecatediamapis.htm). +// Lists all the identity providers in your tenancy. You must specify the identity provider type (e.g., `SAML2` for +// identity providers using the SAML2.0 protocol). You must specify your tenancy's OCID as the value for the +// compartment ID (remember that the tenancy is simply the root compartment). +// See Where to Get the Tenancy's OCID and User's OCID (https://docs.cloud.oracle.com/Content/API/Concepts/apisigningkey.htm#five). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListIdentityProviders.go.html to see an example of how to use ListIdentityProviders API. +func (client IdentityClient) ListIdentityProviders(ctx context.Context, request ListIdentityProvidersRequest) (response ListIdentityProvidersResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listIdentityProviders, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListIdentityProvidersResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListIdentityProvidersResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListIdentityProvidersResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListIdentityProvidersResponse") + } + return +} + +// listIdentityProviders implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listIdentityProviders(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/identityProviders", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListIdentityProvidersResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponseWithPolymorphicBody(httpResponse, &response, &listidentityprovider{}) + return response, err +} + +// ListIdpGroupMappings **Deprecated.** For more information, see Deprecated IAM Service APIs (https://docs.cloud.oracle.com/Content/Identity/Reference/deprecatediamapis.htm). +// Lists the group mappings for the specified identity provider. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListIdpGroupMappings.go.html to see an example of how to use ListIdpGroupMappings API. +func (client IdentityClient) ListIdpGroupMappings(ctx context.Context, request ListIdpGroupMappingsRequest) (response ListIdpGroupMappingsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listIdpGroupMappings, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListIdpGroupMappingsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListIdpGroupMappingsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListIdpGroupMappingsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListIdpGroupMappingsResponse") + } + return +} + +// listIdpGroupMappings implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listIdpGroupMappings(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/identityProviders/{identityProviderId}/groupMappings", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListIdpGroupMappingsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListMfaTotpDevices Lists the MFA TOTP devices for the specified user. The returned object contains the device's OCID, but not +// the seed. The seed is returned only upon creation or when the IAM service regenerates the MFA seed for the device. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListMfaTotpDevices.go.html to see an example of how to use ListMfaTotpDevices API. +func (client IdentityClient) ListMfaTotpDevices(ctx context.Context, request ListMfaTotpDevicesRequest) (response ListMfaTotpDevicesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listMfaTotpDevices, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListMfaTotpDevicesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListMfaTotpDevicesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListMfaTotpDevicesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListMfaTotpDevicesResponse") + } + return +} + +// listMfaTotpDevices implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listMfaTotpDevices(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/users/{userId}/mfaTotpDevices", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListMfaTotpDevicesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListNetworkSources Lists the network sources in your tenancy. You must specify your tenancy's OCID as the value for +// the compartment ID (remember that the tenancy is simply the root compartment). +// See Where to Get the Tenancy's OCID and User's OCID (https://docs.cloud.oracle.com/Content/API/Concepts/apisigningkey.htm#five). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListNetworkSources.go.html to see an example of how to use ListNetworkSources API. +func (client IdentityClient) ListNetworkSources(ctx context.Context, request ListNetworkSourcesRequest) (response ListNetworkSourcesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listNetworkSources, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListNetworkSourcesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListNetworkSourcesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListNetworkSourcesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListNetworkSourcesResponse") + } + return +} + +// listNetworkSources implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listNetworkSources(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/networkSources", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListNetworkSourcesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListOAuthClientCredentials List of Oauth tokens for the user +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListOAuthClientCredentials.go.html to see an example of how to use ListOAuthClientCredentials API. +func (client IdentityClient) ListOAuthClientCredentials(ctx context.Context, request ListOAuthClientCredentialsRequest) (response ListOAuthClientCredentialsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listOAuthClientCredentials, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListOAuthClientCredentialsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListOAuthClientCredentialsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListOAuthClientCredentialsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListOAuthClientCredentialsResponse") + } + return +} + +// listOAuthClientCredentials implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listOAuthClientCredentials(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/users/{userId}/oauth2ClientCredentials", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListOAuthClientCredentialsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListPolicies Lists the policies in the specified compartment (either the tenancy or another of your compartments). +// See Where to Get the Tenancy's OCID and User's OCID (https://docs.cloud.oracle.com/Content/API/Concepts/apisigningkey.htm#five). +// To determine which policies apply to a particular group or compartment, you must view the individual +// statements inside all your policies. There isn't a way to automatically obtain that information via the API. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListPolicies.go.html to see an example of how to use ListPolicies API. +func (client IdentityClient) ListPolicies(ctx context.Context, request ListPoliciesRequest) (response ListPoliciesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listPolicies, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListPoliciesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListPoliciesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListPoliciesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListPoliciesResponse") + } + return +} + +// listPolicies implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listPolicies(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/policies", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListPoliciesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListRegionSubscriptions Lists the region subscriptions for the specified tenancy. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListRegionSubscriptions.go.html to see an example of how to use ListRegionSubscriptions API. +func (client IdentityClient) ListRegionSubscriptions(ctx context.Context, request ListRegionSubscriptionsRequest) (response ListRegionSubscriptionsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listRegionSubscriptions, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListRegionSubscriptionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListRegionSubscriptionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListRegionSubscriptionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListRegionSubscriptionsResponse") + } + return +} + +// listRegionSubscriptions implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listRegionSubscriptions(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/tenancies/{tenancyId}/regionSubscriptions", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListRegionSubscriptionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListRegions Lists all the regions offered by Oracle Cloud Infrastructure. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListRegions.go.html to see an example of how to use ListRegions API. +func (client IdentityClient) ListRegions(ctx context.Context) (response ListRegionsResponse, err error) { + var ociResponse common.OCIResponse + ociResponse, err = client.listRegions(ctx) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListRegionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListRegionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListRegionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListRegionsResponse") + } + return +} + +// listRegions performs the request (retry policy is not enabled without a request object) +func (client IdentityClient) listRegions(ctx context.Context) (common.OCIResponse, error) { + httpRequest := common.MakeDefaultHTTPRequest(http.MethodGet, "/regions") + var err error + + var response ListRegionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListSmtpCredentials Lists the SMTP credentials for the specified user. The returned object contains the credential's OCID, +// the SMTP user name but not the SMTP password. The SMTP password is returned only upon creation. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListSmtpCredentials.go.html to see an example of how to use ListSmtpCredentials API. +func (client IdentityClient) ListSmtpCredentials(ctx context.Context, request ListSmtpCredentialsRequest) (response ListSmtpCredentialsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listSmtpCredentials, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListSmtpCredentialsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListSmtpCredentialsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListSmtpCredentialsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListSmtpCredentialsResponse") + } + return +} + +// listSmtpCredentials implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listSmtpCredentials(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/users/{userId}/smtpCredentials", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListSmtpCredentialsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListStandardTagNamespaces Lists available standard tag namespaces that users can create. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListStandardTagNamespaces.go.html to see an example of how to use ListStandardTagNamespaces API. +func (client IdentityClient) ListStandardTagNamespaces(ctx context.Context, request ListStandardTagNamespacesRequest) (response ListStandardTagNamespacesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listStandardTagNamespaces, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListStandardTagNamespacesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListStandardTagNamespacesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListStandardTagNamespacesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListStandardTagNamespacesResponse") + } + return +} + +// listStandardTagNamespaces implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listStandardTagNamespaces(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/tags/standardTagNamespaceTemplates", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListStandardTagNamespacesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListSwiftPasswords **Deprecated. Use ListAuthTokens instead.** +// Lists the Swift passwords for the specified user. The returned object contains the password's OCID, but not +// the password itself. The actual password is returned only upon creation. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListSwiftPasswords.go.html to see an example of how to use ListSwiftPasswords API. +func (client IdentityClient) ListSwiftPasswords(ctx context.Context, request ListSwiftPasswordsRequest) (response ListSwiftPasswordsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listSwiftPasswords, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListSwiftPasswordsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListSwiftPasswordsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListSwiftPasswordsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListSwiftPasswordsResponse") + } + return +} + +// listSwiftPasswords implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listSwiftPasswords(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/users/{userId}/swiftPasswords", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListSwiftPasswordsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListTagDefaults Lists the tag defaults for tag definitions in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListTagDefaults.go.html to see an example of how to use ListTagDefaults API. +func (client IdentityClient) ListTagDefaults(ctx context.Context, request ListTagDefaultsRequest) (response ListTagDefaultsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listTagDefaults, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListTagDefaultsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListTagDefaultsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListTagDefaultsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListTagDefaultsResponse") + } + return +} + +// listTagDefaults implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listTagDefaults(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/tagDefaults", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListTagDefaultsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListTagNamespaces Lists the tag namespaces in the specified compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListTagNamespaces.go.html to see an example of how to use ListTagNamespaces API. +func (client IdentityClient) ListTagNamespaces(ctx context.Context, request ListTagNamespacesRequest) (response ListTagNamespacesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listTagNamespaces, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListTagNamespacesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListTagNamespacesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListTagNamespacesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListTagNamespacesResponse") + } + return +} + +// listTagNamespaces implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listTagNamespaces(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/tagNamespaces", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListTagNamespacesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListTaggingWorkRequestErrors Gets the errors for a work request. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListTaggingWorkRequestErrors.go.html to see an example of how to use ListTaggingWorkRequestErrors API. +func (client IdentityClient) ListTaggingWorkRequestErrors(ctx context.Context, request ListTaggingWorkRequestErrorsRequest) (response ListTaggingWorkRequestErrorsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listTaggingWorkRequestErrors, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListTaggingWorkRequestErrorsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListTaggingWorkRequestErrorsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListTaggingWorkRequestErrorsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListTaggingWorkRequestErrorsResponse") + } + return +} + +// listTaggingWorkRequestErrors implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listTaggingWorkRequestErrors(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/taggingWorkRequests/{workRequestId}/errors", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListTaggingWorkRequestErrorsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListTaggingWorkRequestLogs Gets the logs for a work request. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListTaggingWorkRequestLogs.go.html to see an example of how to use ListTaggingWorkRequestLogs API. +func (client IdentityClient) ListTaggingWorkRequestLogs(ctx context.Context, request ListTaggingWorkRequestLogsRequest) (response ListTaggingWorkRequestLogsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listTaggingWorkRequestLogs, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListTaggingWorkRequestLogsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListTaggingWorkRequestLogsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListTaggingWorkRequestLogsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListTaggingWorkRequestLogsResponse") + } + return +} + +// listTaggingWorkRequestLogs implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listTaggingWorkRequestLogs(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/taggingWorkRequests/{workRequestId}/logs", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListTaggingWorkRequestLogsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListTaggingWorkRequests Lists the tagging work requests in compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListTaggingWorkRequests.go.html to see an example of how to use ListTaggingWorkRequests API. +func (client IdentityClient) ListTaggingWorkRequests(ctx context.Context, request ListTaggingWorkRequestsRequest) (response ListTaggingWorkRequestsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listTaggingWorkRequests, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListTaggingWorkRequestsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListTaggingWorkRequestsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListTaggingWorkRequestsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListTaggingWorkRequestsResponse") + } + return +} + +// listTaggingWorkRequests implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listTaggingWorkRequests(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/taggingWorkRequests", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListTaggingWorkRequestsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListTags Lists the tag definitions in the specified tag namespace. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListTags.go.html to see an example of how to use ListTags API. +func (client IdentityClient) ListTags(ctx context.Context, request ListTagsRequest) (response ListTagsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listTags, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListTagsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListTagsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListTagsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListTagsResponse") + } + return +} + +// listTags implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listTags(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/tagNamespaces/{tagNamespaceId}/tags", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListTagsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListUserGroupMemberships Lists the `UserGroupMembership` objects in your tenancy. You must specify your tenancy's OCID +// as the value for the compartment ID +// (see Where to Get the Tenancy's OCID and User's OCID (https://docs.cloud.oracle.com/Content/API/Concepts/apisigningkey.htm#five)). +// You must also then filter the list in one of these ways: +// - You can limit the results to just the memberships for a given user by specifying a `userId`. +// - Similarly, you can limit the results to just the memberships for a given group by specifying a `groupId`. +// - You can set both the `userId` and `groupId` to determine if the specified user is in the specified group. +// If the answer is no, the response is an empty list. +// - Although`userId` and `groupId` are not individually required, you must set one of them. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListUserGroupMemberships.go.html to see an example of how to use ListUserGroupMemberships API. +func (client IdentityClient) ListUserGroupMemberships(ctx context.Context, request ListUserGroupMembershipsRequest) (response ListUserGroupMembershipsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listUserGroupMemberships, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListUserGroupMembershipsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListUserGroupMembershipsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListUserGroupMembershipsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListUserGroupMembershipsResponse") + } + return +} + +// listUserGroupMemberships implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listUserGroupMemberships(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/userGroupMemberships", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListUserGroupMembershipsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListUsers Lists the users in your tenancy. You must specify your tenancy's OCID as the value for the +// compartment ID (remember that the tenancy is simply the root compartment). +// See Where to Get the Tenancy's OCID and User's OCID (https://docs.cloud.oracle.com/Content/API/Concepts/apisigningkey.htm#five). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListUsers.go.html to see an example of how to use ListUsers API. +func (client IdentityClient) ListUsers(ctx context.Context, request ListUsersRequest) (response ListUsersResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listUsers, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListUsersResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListUsersResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListUsersResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListUsersResponse") + } + return +} + +// listUsers implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listUsers(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/users", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListUsersResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListWorkRequests Lists the work requests in compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListWorkRequests.go.html to see an example of how to use ListWorkRequests API. +func (client IdentityClient) ListWorkRequests(ctx context.Context, request ListWorkRequestsRequest) (response ListWorkRequestsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listWorkRequests, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListWorkRequestsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListWorkRequestsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListWorkRequestsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListWorkRequestsResponse") + } + return +} + +// listWorkRequests implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) listWorkRequests(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/workRequests", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListWorkRequestsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// MoveCompartment Move the compartment to a different parent compartment in the same tenancy. When you move a +// compartment, all its contents (subcompartments and resources) are moved with it. Note that +// the `CompartmentId` that you specify in the path is the compartment that you want to move. +// **IMPORTANT**: After you move a compartment to a new parent compartment, the access policies of +// the new parent take effect and the policies of the previous parent no longer apply. Ensure that you +// are aware of the implications for the compartment contents before you move it. For more +// information, see Moving a Compartment (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingcompartments.htm#MoveCompartment). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/MoveCompartment.go.html to see an example of how to use MoveCompartment API. +func (client IdentityClient) MoveCompartment(ctx context.Context, request MoveCompartmentRequest) (response MoveCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.moveCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = MoveCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = MoveCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(MoveCompartmentResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into MoveCompartmentResponse") + } + return +} + +// moveCompartment implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) moveCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/compartments/{compartmentId}/actions/moveCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response MoveCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// RecoverCompartment Recover the compartment from DELETED state to ACTIVE state. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/RecoverCompartment.go.html to see an example of how to use RecoverCompartment API. +func (client IdentityClient) RecoverCompartment(ctx context.Context, request RecoverCompartmentRequest) (response RecoverCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.recoverCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = RecoverCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = RecoverCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(RecoverCompartmentResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into RecoverCompartmentResponse") + } + return +} + +// recoverCompartment implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) recoverCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/compartments/{compartmentId}/actions/recoverCompartment", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response RecoverCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// RemoveUserFromGroup Removes a user from a group by deleting the corresponding `UserGroupMembership`. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/RemoveUserFromGroup.go.html to see an example of how to use RemoveUserFromGroup API. +func (client IdentityClient) RemoveUserFromGroup(ctx context.Context, request RemoveUserFromGroupRequest) (response RemoveUserFromGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.removeUserFromGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = RemoveUserFromGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = RemoveUserFromGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(RemoveUserFromGroupResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into RemoveUserFromGroupResponse") + } + return +} + +// removeUserFromGroup implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) removeUserFromGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/userGroupMemberships/{userGroupMembershipId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response RemoveUserFromGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ResetIdpScimClient Resets the OAuth2 client credentials for the SCIM client associated with this identity provider. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ResetIdpScimClient.go.html to see an example of how to use ResetIdpScimClient API. +func (client IdentityClient) ResetIdpScimClient(ctx context.Context, request ResetIdpScimClientRequest) (response ResetIdpScimClientResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.resetIdpScimClient, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ResetIdpScimClientResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ResetIdpScimClientResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ResetIdpScimClientResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ResetIdpScimClientResponse") + } + return +} + +// resetIdpScimClient implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) resetIdpScimClient(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/identityProviders/{identityProviderId}/actions/resetScimClient", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ResetIdpScimClientResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateAuthToken Updates the specified auth token's description. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateAuthToken.go.html to see an example of how to use UpdateAuthToken API. +func (client IdentityClient) UpdateAuthToken(ctx context.Context, request UpdateAuthTokenRequest) (response UpdateAuthTokenResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateAuthToken, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateAuthTokenResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateAuthTokenResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateAuthTokenResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateAuthTokenResponse") + } + return +} + +// updateAuthToken implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateAuthToken(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/users/{userId}/authTokens/{authTokenId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateAuthTokenResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateAuthenticationPolicy Updates authentication policy for the specified tenancy +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateAuthenticationPolicy.go.html to see an example of how to use UpdateAuthenticationPolicy API. +func (client IdentityClient) UpdateAuthenticationPolicy(ctx context.Context, request UpdateAuthenticationPolicyRequest) (response UpdateAuthenticationPolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateAuthenticationPolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateAuthenticationPolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateAuthenticationPolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateAuthenticationPolicyResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateAuthenticationPolicyResponse") + } + return +} + +// updateAuthenticationPolicy implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateAuthenticationPolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/authenticationPolicies/{compartmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateAuthenticationPolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateCompartment Updates the specified compartment's description or name. You can't update the root compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateCompartment.go.html to see an example of how to use UpdateCompartment API. +func (client IdentityClient) UpdateCompartment(ctx context.Context, request UpdateCompartmentRequest) (response UpdateCompartmentResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateCompartment, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateCompartmentResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateCompartmentResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateCompartmentResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateCompartmentResponse") + } + return +} + +// updateCompartment implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateCompartment(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/compartments/{compartmentId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateCompartmentResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateCustomerSecretKey Updates the specified secret key's description. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateCustomerSecretKey.go.html to see an example of how to use UpdateCustomerSecretKey API. +func (client IdentityClient) UpdateCustomerSecretKey(ctx context.Context, request UpdateCustomerSecretKeyRequest) (response UpdateCustomerSecretKeyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateCustomerSecretKey, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateCustomerSecretKeyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateCustomerSecretKeyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateCustomerSecretKeyResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateCustomerSecretKeyResponse") + } + return +} + +// updateCustomerSecretKey implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateCustomerSecretKey(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/users/{userId}/customerSecretKeys/{customerSecretKeyId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateCustomerSecretKeyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateDomain Updates domain information and associated stripe. This is an asynchronous call where +// the associated stripe and domain are updated. +// To track progress, HTTP GET on /iamWorkRequests/{iamWorkRequestsId} endpoint will provide +// the async operation's status. +// - If the {@code displayName} is not unique within the tenancy, returns 400 BAD REQUEST. +// - If any field other than {@code description} is requested to be updated for DEFAULT domain, +// returns 400 BAD REQUEST. +// - If Domain is not active or being updated, returns 400 BAD REQUEST. +// - If Domain {@code type} is DEFAULT or DEFAULT_LIGHTWEIGHT, return 400 BAD Request +// - If the domain doesn't exists, returns 404 NOT FOUND. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateDomain.go.html to see an example of how to use UpdateDomain API. +func (client IdentityClient) UpdateDomain(ctx context.Context, request UpdateDomainRequest) (response UpdateDomainResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateDomain, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateDomainResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateDomainResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateDomainResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateDomainResponse") + } + return +} + +// updateDomain implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateDomain(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/domains/{domainId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateDomainResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateDynamicGroup Updates the specified dynamic group. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateDynamicGroup.go.html to see an example of how to use UpdateDynamicGroup API. +func (client IdentityClient) UpdateDynamicGroup(ctx context.Context, request UpdateDynamicGroupRequest) (response UpdateDynamicGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateDynamicGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateDynamicGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateDynamicGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateDynamicGroupResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateDynamicGroupResponse") + } + return +} + +// updateDynamicGroup implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateDynamicGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/dynamicGroups/{dynamicGroupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateDynamicGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateGroup Updates the specified group. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateGroup.go.html to see an example of how to use UpdateGroup API. +func (client IdentityClient) UpdateGroup(ctx context.Context, request UpdateGroupRequest) (response UpdateGroupResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateGroup, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateGroupResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateGroupResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateGroupResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateGroupResponse") + } + return +} + +// updateGroup implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateGroup(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/groups/{groupId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateGroupResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateIdentityProvider **Deprecated.** For more information, see Deprecated IAM Service APIs (https://docs.cloud.oracle.com/Content/Identity/Reference/deprecatediamapis.htm). +// Updates the specified identity provider. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateIdentityProvider.go.html to see an example of how to use UpdateIdentityProvider API. +func (client IdentityClient) UpdateIdentityProvider(ctx context.Context, request UpdateIdentityProviderRequest) (response UpdateIdentityProviderResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateIdentityProvider, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateIdentityProviderResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateIdentityProviderResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateIdentityProviderResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateIdentityProviderResponse") + } + return +} + +// updateIdentityProvider implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateIdentityProvider(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/identityProviders/{identityProviderId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateIdentityProviderResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponseWithPolymorphicBody(httpResponse, &response, &identityprovider{}) + return response, err +} + +// UpdateIdpGroupMapping **Deprecated.** For more information, see Deprecated IAM Service APIs (https://docs.cloud.oracle.com/Content/Identity/Reference/deprecatediamapis.htm). +// Updates the specified group mapping. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateIdpGroupMapping.go.html to see an example of how to use UpdateIdpGroupMapping API. +func (client IdentityClient) UpdateIdpGroupMapping(ctx context.Context, request UpdateIdpGroupMappingRequest) (response UpdateIdpGroupMappingResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateIdpGroupMapping, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateIdpGroupMappingResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateIdpGroupMappingResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateIdpGroupMappingResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateIdpGroupMappingResponse") + } + return +} + +// updateIdpGroupMapping implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateIdpGroupMapping(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/identityProviders/{identityProviderId}/groupMappings/{mappingId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateIdpGroupMappingResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateNetworkSource Updates the specified network source. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateNetworkSource.go.html to see an example of how to use UpdateNetworkSource API. +func (client IdentityClient) UpdateNetworkSource(ctx context.Context, request UpdateNetworkSourceRequest) (response UpdateNetworkSourceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateNetworkSource, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateNetworkSourceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateNetworkSourceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateNetworkSourceResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateNetworkSourceResponse") + } + return +} + +// updateNetworkSource implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateNetworkSource(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/networkSources/{networkSourceId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateNetworkSourceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateOAuthClientCredential Updates Oauth token for the user +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateOAuthClientCredential.go.html to see an example of how to use UpdateOAuthClientCredential API. +func (client IdentityClient) UpdateOAuthClientCredential(ctx context.Context, request UpdateOAuthClientCredentialRequest) (response UpdateOAuthClientCredentialResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateOAuthClientCredential, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateOAuthClientCredentialResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateOAuthClientCredentialResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateOAuthClientCredentialResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateOAuthClientCredentialResponse") + } + return +} + +// updateOAuthClientCredential implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateOAuthClientCredential(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/users/{userId}/oauth2ClientCredentials/{oauth2ClientCredentialId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateOAuthClientCredentialResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdatePolicy Updates the specified policy. You can update the description or the policy statements themselves. +// Policy changes take effect typically within 10 seconds. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdatePolicy.go.html to see an example of how to use UpdatePolicy API. +func (client IdentityClient) UpdatePolicy(ctx context.Context, request UpdatePolicyRequest) (response UpdatePolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updatePolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdatePolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdatePolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdatePolicyResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdatePolicyResponse") + } + return +} + +// updatePolicy implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updatePolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/policies/{policyId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdatePolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateSmtpCredential Updates the specified SMTP credential's description. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateSmtpCredential.go.html to see an example of how to use UpdateSmtpCredential API. +func (client IdentityClient) UpdateSmtpCredential(ctx context.Context, request UpdateSmtpCredentialRequest) (response UpdateSmtpCredentialResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateSmtpCredential, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateSmtpCredentialResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateSmtpCredentialResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateSmtpCredentialResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateSmtpCredentialResponse") + } + return +} + +// updateSmtpCredential implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateSmtpCredential(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/users/{userId}/smtpCredentials/{smtpCredentialId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateSmtpCredentialResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateSwiftPassword **Deprecated. Use UpdateAuthToken instead.** +// Updates the specified Swift password's description. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateSwiftPassword.go.html to see an example of how to use UpdateSwiftPassword API. +func (client IdentityClient) UpdateSwiftPassword(ctx context.Context, request UpdateSwiftPasswordRequest) (response UpdateSwiftPasswordResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateSwiftPassword, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateSwiftPasswordResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateSwiftPasswordResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateSwiftPasswordResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateSwiftPasswordResponse") + } + return +} + +// updateSwiftPassword implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateSwiftPassword(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/users/{userId}/swiftPasswords/{swiftPasswordId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateSwiftPasswordResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateTag Updates the specified tag definition. +// Setting `validator` determines the value type. Tags can use either a static value or a +// list of possible values. Static values are entered by a user applying the tag to a resource. +// Lists are created by you and the user must apply a value from the list. On update, any values +// in a list that were previously set do not change, but new values must pass validation. Values +// already applied to a resource do not change. +// You cannot remove list values that appear in a TagDefault. To remove a list value that +// appears in a TagDefault, first update the TagDefault to use a different value. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateTag.go.html to see an example of how to use UpdateTag API. +func (client IdentityClient) UpdateTag(ctx context.Context, request UpdateTagRequest) (response UpdateTagResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateTag, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateTagResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateTagResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateTagResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateTagResponse") + } + return +} + +// updateTag implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateTag(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/tagNamespaces/{tagNamespaceId}/tags/{tagName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateTagResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateTagDefault Updates the specified tag default. If you specify that a value is required, a value is set +// during resource creation (either by the user creating the resource or another tag defualt). +// If no value is set, resource creation is blocked. +// * If the `isRequired` flag is set to "true", the value is set during resource creation. +// * If the `isRequired` flag is set to "false", the value you enter is set during resource creation. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateTagDefault.go.html to see an example of how to use UpdateTagDefault API. +func (client IdentityClient) UpdateTagDefault(ctx context.Context, request UpdateTagDefaultRequest) (response UpdateTagDefaultResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateTagDefault, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateTagDefaultResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateTagDefaultResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateTagDefaultResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateTagDefaultResponse") + } + return +} + +// updateTagDefault implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateTagDefault(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/tagDefaults/{tagDefaultId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateTagDefaultResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateTagNamespace Updates the the specified tag namespace. You can't update the namespace name. +// Updating `isRetired` to 'true' retires the namespace and all the tag definitions in the namespace. Reactivating a +// namespace (changing `isRetired` from 'true' to 'false') does not reactivate tag definitions. +// To reactivate the tag definitions, you must reactivate each one individually *after* you reactivate the namespace, +// using UpdateTag. For more information about retiring tag namespaces, see +// Retiring Key Definitions and Namespace Definitions (https://docs.cloud.oracle.com/Content/Identity/Concepts/taggingoverview.htm#Retiring). +// You can't add a namespace with the same name as a retired namespace in the same tenancy. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateTagNamespace.go.html to see an example of how to use UpdateTagNamespace API. +func (client IdentityClient) UpdateTagNamespace(ctx context.Context, request UpdateTagNamespaceRequest) (response UpdateTagNamespaceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateTagNamespace, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateTagNamespaceResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateTagNamespaceResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateTagNamespaceResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateTagNamespaceResponse") + } + return +} + +// updateTagNamespace implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateTagNamespace(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/tagNamespaces/{tagNamespaceId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateTagNamespaceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateUser Updates the description of the specified user. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateUser.go.html to see an example of how to use UpdateUser API. +func (client IdentityClient) UpdateUser(ctx context.Context, request UpdateUserRequest) (response UpdateUserResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateUser, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateUserResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateUserResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateUserResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateUserResponse") + } + return +} + +// updateUser implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateUser(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/users/{userId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateUserResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateUserCapabilities Updates the capabilities of the specified user. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateUserCapabilities.go.html to see an example of how to use UpdateUserCapabilities API. +func (client IdentityClient) UpdateUserCapabilities(ctx context.Context, request UpdateUserCapabilitiesRequest) (response UpdateUserCapabilitiesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateUserCapabilities, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateUserCapabilitiesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateUserCapabilitiesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateUserCapabilitiesResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateUserCapabilitiesResponse") + } + return +} + +// updateUserCapabilities implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateUserCapabilities(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/users/{userId}/capabilities", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateUserCapabilitiesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateUserState Updates the state of the specified user. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateUserState.go.html to see an example of how to use UpdateUserState API. +func (client IdentityClient) UpdateUserState(ctx context.Context, request UpdateUserStateRequest) (response UpdateUserStateResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateUserState, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateUserStateResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateUserStateResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateUserStateResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateUserStateResponse") + } + return +} + +// updateUserState implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) updateUserState(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/users/{userId}/state", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateUserStateResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UploadApiKey Uploads an API signing key for the specified user. +// Every user has permission to use this operation to upload a key for *their own user ID*. An +// administrator in your organization does not need to write a policy to give users this ability. +// To compare, administrators who have permission to the tenancy can use this operation to upload a +// key for any user, including themselves. +// **Important:** Even though you have permission to upload an API key, you might not yet +// have permission to do much else. If you try calling an operation unrelated to your own credential +// management (e.g., `ListUsers`, `LaunchInstance`) and receive an "unauthorized" error, +// check with an administrator to confirm which IAM Service group(s) you're in and what access +// you have. Also confirm you're working in the correct compartment. +// After you send your request, the new object's `lifecycleState` will temporarily be CREATING. Before using +// the object, first make sure its `lifecycleState` has changed to ACTIVE. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UploadApiKey.go.html to see an example of how to use UploadApiKey API. +func (client IdentityClient) UploadApiKey(ctx context.Context, request UploadApiKeyRequest) (response UploadApiKeyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + + if !(request.OpcRetryToken != nil && *request.OpcRetryToken != "") { + request.OpcRetryToken = common.String(common.RetryToken()) + } + + ociResponse, err = common.Retry(ctx, request, client.uploadApiKey, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UploadApiKeyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UploadApiKeyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UploadApiKeyResponse); ok { + common.EcContext.UpdateEndOfWindow(time.Duration(240 * time.Second)) + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UploadApiKeyResponse") + } + return +} + +// uploadApiKey implements the OCIOperation interface (enables retrying operations) +func (client IdentityClient) uploadApiKey(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/users/{userId}/apiKeys", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UploadApiKeyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/identity_provider.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/identity_provider.go new file mode 100644 index 000000000..10e5ebef9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/identity_provider.go @@ -0,0 +1,217 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IdentityProvider The resulting base object when you add an identity provider to your tenancy. A +// Saml2IdentityProvider +// is a specific type of `IdentityProvider` that supports the SAML 2.0 protocol. Each +// `IdentityProvider` object has its own OCID. For more information, see +// Identity Providers and Federation (https://docs.cloud.oracle.com/Content/Identity/Concepts/federation.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, +// see Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you supply string +// values using the API. +type IdentityProvider interface { + + // The OCID of the `IdentityProvider`. + GetId() *string + + // The OCID of the tenancy containing the `IdentityProvider`. + GetCompartmentId() *string + + // The name you assign to the `IdentityProvider` during creation. The name + // must be unique across all `IdentityProvider` objects in the tenancy and + // cannot be changed. This is the name federated users see when choosing + // which identity provider to use when signing in to the Oracle Cloud Infrastructure + // Console. + GetName() *string + + // The description you assign to the `IdentityProvider` during creation. Does + // not have to be unique, and it's changeable. + GetDescription() *string + + // The identity provider service or product. + // Supported identity providers are Oracle Identity Cloud Service (IDCS) and Microsoft + // Active Directory Federation Services (ADFS). + // Allowed values are: + // - `ADFS` + // - `IDCS` + // Example: `IDCS` + GetProductType() *string + + // Date and time the `IdentityProvider` was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + GetTimeCreated() *common.SDKTime + + // The current state. After creating an `IdentityProvider`, make sure its + // `lifecycleState` changes from CREATING to ACTIVE before using it. + GetLifecycleState() IdentityProviderLifecycleStateEnum + + // The detailed status of INACTIVE lifecycleState. + GetInactiveStatus() *int64 + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + GetFreeformTags() map[string]string + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + GetDefinedTags() map[string]map[string]interface{} +} + +type identityprovider struct { + JsonData []byte + Id *string `mandatory:"true" json:"id"` + CompartmentId *string `mandatory:"true" json:"compartmentId"` + Name *string `mandatory:"true" json:"name"` + Description *string `mandatory:"true" json:"description"` + ProductType *string `mandatory:"true" json:"productType"` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + LifecycleState IdentityProviderLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + Protocol string `json:"protocol"` +} + +// UnmarshalJSON unmarshals json +func (m *identityprovider) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshaleridentityprovider identityprovider + s := struct { + Model Unmarshaleridentityprovider + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.Id = s.Model.Id + m.CompartmentId = s.Model.CompartmentId + m.Name = s.Model.Name + m.Description = s.Model.Description + m.ProductType = s.Model.ProductType + m.TimeCreated = s.Model.TimeCreated + m.LifecycleState = s.Model.LifecycleState + m.InactiveStatus = s.Model.InactiveStatus + m.FreeformTags = s.Model.FreeformTags + m.DefinedTags = s.Model.DefinedTags + m.Protocol = s.Model.Protocol + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *identityprovider) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Protocol { + case "SAML2": + mm := Saml2IdentityProvider{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetId returns Id +func (m identityprovider) GetId() *string { + return m.Id +} + +//GetCompartmentId returns CompartmentId +func (m identityprovider) GetCompartmentId() *string { + return m.CompartmentId +} + +//GetName returns Name +func (m identityprovider) GetName() *string { + return m.Name +} + +//GetDescription returns Description +func (m identityprovider) GetDescription() *string { + return m.Description +} + +//GetProductType returns ProductType +func (m identityprovider) GetProductType() *string { + return m.ProductType +} + +//GetTimeCreated returns TimeCreated +func (m identityprovider) GetTimeCreated() *common.SDKTime { + return m.TimeCreated +} + +//GetLifecycleState returns LifecycleState +func (m identityprovider) GetLifecycleState() IdentityProviderLifecycleStateEnum { + return m.LifecycleState +} + +//GetInactiveStatus returns InactiveStatus +func (m identityprovider) GetInactiveStatus() *int64 { + return m.InactiveStatus +} + +//GetFreeformTags returns FreeformTags +func (m identityprovider) GetFreeformTags() map[string]string { + return m.FreeformTags +} + +//GetDefinedTags returns DefinedTags +func (m identityprovider) GetDefinedTags() map[string]map[string]interface{} { + return m.DefinedTags +} + +func (m identityprovider) String() string { + return common.PointerString(m) +} + +// IdentityProviderLifecycleStateEnum Enum with underlying type: string +type IdentityProviderLifecycleStateEnum string + +// Set of constants representing the allowable values for IdentityProviderLifecycleStateEnum +const ( + IdentityProviderLifecycleStateCreating IdentityProviderLifecycleStateEnum = "CREATING" + IdentityProviderLifecycleStateActive IdentityProviderLifecycleStateEnum = "ACTIVE" + IdentityProviderLifecycleStateInactive IdentityProviderLifecycleStateEnum = "INACTIVE" + IdentityProviderLifecycleStateDeleting IdentityProviderLifecycleStateEnum = "DELETING" + IdentityProviderLifecycleStateDeleted IdentityProviderLifecycleStateEnum = "DELETED" +) + +var mappingIdentityProviderLifecycleState = map[string]IdentityProviderLifecycleStateEnum{ + "CREATING": IdentityProviderLifecycleStateCreating, + "ACTIVE": IdentityProviderLifecycleStateActive, + "INACTIVE": IdentityProviderLifecycleStateInactive, + "DELETING": IdentityProviderLifecycleStateDeleting, + "DELETED": IdentityProviderLifecycleStateDeleted, +} + +// GetIdentityProviderLifecycleStateEnumValues Enumerates the set of values for IdentityProviderLifecycleStateEnum +func GetIdentityProviderLifecycleStateEnumValues() []IdentityProviderLifecycleStateEnum { + values := make([]IdentityProviderLifecycleStateEnum, 0) + for _, v := range mappingIdentityProviderLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/identity_provider_group_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/identity_provider_group_summary.go new file mode 100644 index 000000000..5f390e3c7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/identity_provider_group_summary.go @@ -0,0 +1,45 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IdentityProviderGroupSummary A group created in an identity provider that can be mapped to a group in OCI +type IdentityProviderGroupSummary struct { + + // The OCID of the `IdentityProviderGroup`. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the `IdentityProvider` this group belongs to. + IdentityProviderId *string `mandatory:"false" json:"identityProviderId"` + + // Display name of the group + DisplayName *string `mandatory:"false" json:"displayName"` + + // Display name of the group + Name *string `mandatory:"false" json:"name"` + + // Identifier of the group in the identity provider + ExternalIdentifier *string `mandatory:"false" json:"externalIdentifier"` + + // Date and time the `IdentityProviderGroup` was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // Date and time the `IdentityProviderGroup` was last modified, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeModified *common.SDKTime `mandatory:"false" json:"timeModified"` +} + +func (m IdentityProviderGroupSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/idp_group_mapping.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/idp_group_mapping.go new file mode 100644 index 000000000..aba656a8a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/idp_group_mapping.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// IdpGroupMapping A mapping between a single group defined by the identity provider (IdP) you're federating with +// and a single IAM Service Group in Oracle Cloud Infrastructure. +// For more information about group mappings and what they're for, see +// Identity Providers and Federation (https://docs.cloud.oracle.com/Content/Identity/Concepts/federation.htm). +// A given IdP group can be mapped to zero, one, or multiple IAM Service groups, and vice versa. +// But each `IdPGroupMapping` object is between only a single IdP group and IAM Service group. +// Each `IdPGroupMapping` object has its own OCID. +// **Note:** Any users who are in more than 50 IdP groups cannot be authenticated to use the Oracle +// Cloud Infrastructure Console. +type IdpGroupMapping struct { + + // The OCID of the `IdpGroupMapping`. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the `IdentityProvider` this mapping belongs to. + IdpId *string `mandatory:"true" json:"idpId"` + + // The name of the IdP group that is mapped to the IAM Service group. + IdpGroupName *string `mandatory:"true" json:"idpGroupName"` + + // The OCID of the IAM Service group that is mapped to the IdP group. + GroupId *string `mandatory:"true" json:"groupId"` + + // The OCID of the tenancy containing the `IdentityProvider`. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // Date and time the mapping was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The mapping's current state. After creating a mapping object, make sure its `lifecycleState` changes + // from CREATING to ACTIVE before using it. + LifecycleState IdpGroupMappingLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` +} + +func (m IdpGroupMapping) String() string { + return common.PointerString(m) +} + +// IdpGroupMappingLifecycleStateEnum Enum with underlying type: string +type IdpGroupMappingLifecycleStateEnum string + +// Set of constants representing the allowable values for IdpGroupMappingLifecycleStateEnum +const ( + IdpGroupMappingLifecycleStateCreating IdpGroupMappingLifecycleStateEnum = "CREATING" + IdpGroupMappingLifecycleStateActive IdpGroupMappingLifecycleStateEnum = "ACTIVE" + IdpGroupMappingLifecycleStateInactive IdpGroupMappingLifecycleStateEnum = "INACTIVE" + IdpGroupMappingLifecycleStateDeleting IdpGroupMappingLifecycleStateEnum = "DELETING" + IdpGroupMappingLifecycleStateDeleted IdpGroupMappingLifecycleStateEnum = "DELETED" +) + +var mappingIdpGroupMappingLifecycleState = map[string]IdpGroupMappingLifecycleStateEnum{ + "CREATING": IdpGroupMappingLifecycleStateCreating, + "ACTIVE": IdpGroupMappingLifecycleStateActive, + "INACTIVE": IdpGroupMappingLifecycleStateInactive, + "DELETING": IdpGroupMappingLifecycleStateDeleting, + "DELETED": IdpGroupMappingLifecycleStateDeleted, +} + +// GetIdpGroupMappingLifecycleStateEnumValues Enumerates the set of values for IdpGroupMappingLifecycleStateEnum +func GetIdpGroupMappingLifecycleStateEnumValues() []IdpGroupMappingLifecycleStateEnum { + values := make([]IdpGroupMappingLifecycleStateEnum, 0) + for _, v := range mappingIdpGroupMappingLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/import_standard_tags_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/import_standard_tags_details.go new file mode 100644 index 000000000..8f9bad3d9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/import_standard_tags_details.go @@ -0,0 +1,28 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ImportStandardTagsDetails The representation of ImportStandardTagsDetails +type ImportStandardTagsDetails struct { + + // The OCID of the compartment where the bulk create request is submitted and where the tag namespaces will be created. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name of standard tag namespace that will be imported in bulk + StandardTagNamespaceName *string `mandatory:"true" json:"standardTagNamespaceName"` +} + +func (m ImportStandardTagsDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/import_standard_tags_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/import_standard_tags_request_response.go new file mode 100644 index 000000000..56c110fdc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/import_standard_tags_request_response.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ImportStandardTagsRequest wrapper for the ImportStandardTags operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ImportStandardTags.go.html to see an example of how to use ImportStandardTagsRequest. +type ImportStandardTagsRequest struct { + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // The request object for creating or updating standard tag namespace. + ImportStandardTagsDetails `contributesTo:"body"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ImportStandardTagsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ImportStandardTagsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ImportStandardTagsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ImportStandardTagsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ImportStandardTagsResponse wrapper for the ImportStandardTags operation +type ImportStandardTagsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response ImportStandardTagsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ImportStandardTagsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_allowed_domain_license_types_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_allowed_domain_license_types_request_response.go new file mode 100644 index 000000000..06e149266 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_allowed_domain_license_types_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListAllowedDomainLicenseTypesRequest wrapper for the ListAllowedDomainLicenseTypes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListAllowedDomainLicenseTypes.go.html to see an example of how to use ListAllowedDomainLicenseTypesRequest. +type ListAllowedDomainLicenseTypesRequest struct { + + // The domain license type + CurrentLicenseTypeName *string `mandatory:"false" contributesTo:"query" name:"currentLicenseTypeName"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListAllowedDomainLicenseTypesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListAllowedDomainLicenseTypesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListAllowedDomainLicenseTypesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListAllowedDomainLicenseTypesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListAllowedDomainLicenseTypesResponse wrapper for the ListAllowedDomainLicenseTypes operation +type ListAllowedDomainLicenseTypesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []AllowedDomainLicenseTypeSummary instance + Items []AllowedDomainLicenseTypeSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListAllowedDomainLicenseTypesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListAllowedDomainLicenseTypesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_api_keys_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_api_keys_request_response.go new file mode 100644 index 000000000..e19d512ac --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_api_keys_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListApiKeysRequest wrapper for the ListApiKeys operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListApiKeys.go.html to see an example of how to use ListApiKeysRequest. +type ListApiKeysRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListApiKeysRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListApiKeysRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListApiKeysRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListApiKeysRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListApiKeysResponse wrapper for the ListApiKeys operation +type ListApiKeysResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []ApiKey instance + Items []ApiKey `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListApiKeysResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListApiKeysResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_auth_tokens_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_auth_tokens_request_response.go new file mode 100644 index 000000000..144d9ae30 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_auth_tokens_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListAuthTokensRequest wrapper for the ListAuthTokens operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListAuthTokens.go.html to see an example of how to use ListAuthTokensRequest. +type ListAuthTokensRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListAuthTokensRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListAuthTokensRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListAuthTokensRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListAuthTokensRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListAuthTokensResponse wrapper for the ListAuthTokens operation +type ListAuthTokensResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []AuthToken instance + Items []AuthToken `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListAuthTokensResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListAuthTokensResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_availability_domains_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_availability_domains_request_response.go new file mode 100644 index 000000000..8ace00e29 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_availability_domains_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListAvailabilityDomainsRequest wrapper for the ListAvailabilityDomains operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListAvailabilityDomains.go.html to see an example of how to use ListAvailabilityDomainsRequest. +type ListAvailabilityDomainsRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListAvailabilityDomainsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListAvailabilityDomainsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListAvailabilityDomainsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListAvailabilityDomainsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListAvailabilityDomainsResponse wrapper for the ListAvailabilityDomains operation +type ListAvailabilityDomainsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []AvailabilityDomain instance + Items []AvailabilityDomain `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListAvailabilityDomainsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListAvailabilityDomainsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_bulk_action_resource_types_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_bulk_action_resource_types_request_response.go new file mode 100644 index 000000000..a069bf1bb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_bulk_action_resource_types_request_response.go @@ -0,0 +1,108 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListBulkActionResourceTypesRequest wrapper for the ListBulkActionResourceTypes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListBulkActionResourceTypes.go.html to see an example of how to use ListBulkActionResourceTypesRequest. +type ListBulkActionResourceTypesRequest struct { + + // The type of bulk action. + BulkActionType ListBulkActionResourceTypesBulkActionTypeEnum `mandatory:"true" contributesTo:"query" name:"bulkActionType" omitEmpty:"true"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListBulkActionResourceTypesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListBulkActionResourceTypesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListBulkActionResourceTypesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListBulkActionResourceTypesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListBulkActionResourceTypesResponse wrapper for the ListBulkActionResourceTypes operation +type ListBulkActionResourceTypesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of BulkActionResourceTypeCollection instances + BulkActionResourceTypeCollection `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListBulkActionResourceTypesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListBulkActionResourceTypesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListBulkActionResourceTypesBulkActionTypeEnum Enum with underlying type: string +type ListBulkActionResourceTypesBulkActionTypeEnum string + +// Set of constants representing the allowable values for ListBulkActionResourceTypesBulkActionTypeEnum +const ( + ListBulkActionResourceTypesBulkActionTypeMoveResources ListBulkActionResourceTypesBulkActionTypeEnum = "BULK_MOVE_RESOURCES" + ListBulkActionResourceTypesBulkActionTypeDeleteResources ListBulkActionResourceTypesBulkActionTypeEnum = "BULK_DELETE_RESOURCES" +) + +var mappingListBulkActionResourceTypesBulkActionType = map[string]ListBulkActionResourceTypesBulkActionTypeEnum{ + "BULK_MOVE_RESOURCES": ListBulkActionResourceTypesBulkActionTypeMoveResources, + "BULK_DELETE_RESOURCES": ListBulkActionResourceTypesBulkActionTypeDeleteResources, +} + +// GetListBulkActionResourceTypesBulkActionTypeEnumValues Enumerates the set of values for ListBulkActionResourceTypesBulkActionTypeEnum +func GetListBulkActionResourceTypesBulkActionTypeEnumValues() []ListBulkActionResourceTypesBulkActionTypeEnum { + values := make([]ListBulkActionResourceTypesBulkActionTypeEnum, 0) + for _, v := range mappingListBulkActionResourceTypesBulkActionType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_bulk_edit_tags_resource_types_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_bulk_edit_tags_resource_types_request_response.go new file mode 100644 index 000000000..f876d4189 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_bulk_edit_tags_resource_types_request_response.go @@ -0,0 +1,82 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListBulkEditTagsResourceTypesRequest wrapper for the ListBulkEditTagsResourceTypes operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListBulkEditTagsResourceTypes.go.html to see an example of how to use ListBulkEditTagsResourceTypesRequest. +type ListBulkEditTagsResourceTypesRequest struct { + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListBulkEditTagsResourceTypesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListBulkEditTagsResourceTypesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListBulkEditTagsResourceTypesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListBulkEditTagsResourceTypesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListBulkEditTagsResourceTypesResponse wrapper for the ListBulkEditTagsResourceTypes operation +type ListBulkEditTagsResourceTypesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of BulkEditTagsResourceTypeCollection instances + BulkEditTagsResourceTypeCollection `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListBulkEditTagsResourceTypesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListBulkEditTagsResourceTypesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_compartments_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_compartments_request_response.go new file mode 100644 index 000000000..fa6675983 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_compartments_request_response.go @@ -0,0 +1,188 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListCompartmentsRequest wrapper for the ListCompartments operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListCompartments.go.html to see an example of how to use ListCompartmentsRequest. +type ListCompartmentsRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // Valid values are `ANY` and `ACCESSIBLE`. Default is `ANY`. + // Setting this to `ACCESSIBLE` returns only those compartments for which the + // user has INSPECT permissions directly or indirectly (permissions can be on a + // resource in a subcompartment). For the compartments on which the user indirectly has + // INSPECT permissions, a restricted set of fields is returned. + // When set to `ANY` permissions are not checked. + AccessLevel ListCompartmentsAccessLevelEnum `mandatory:"false" contributesTo:"query" name:"accessLevel" omitEmpty:"true"` + + // Default is false. Can only be set to true when performing + // ListCompartments on the tenancy (root compartment). + // When set to true, the hierarchy of compartments is traversed + // and all compartments and subcompartments in the tenancy are + // returned depending on the the setting of `accessLevel`. + CompartmentIdInSubtree *bool `mandatory:"false" contributesTo:"query" name:"compartmentIdInSubtree"` + + // A filter to only return resources that match the given name exactly. + Name *string `mandatory:"false" contributesTo:"query" name:"name"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for NAME is ascending. The NAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by Availability Domain if the scope of the resource type is within a + // single Availability Domain. If you call one of these "List" operations without specifying + // an Availability Domain, the resources are grouped by Availability Domain, then sorted. + SortBy ListCompartmentsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The NAME sort order + // is case sensitive. + SortOrder ListCompartmentsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState CompartmentLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListCompartmentsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListCompartmentsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListCompartmentsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListCompartmentsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListCompartmentsResponse wrapper for the ListCompartments operation +type ListCompartmentsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Compartment instances + Items []Compartment `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListCompartmentsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListCompartmentsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListCompartmentsAccessLevelEnum Enum with underlying type: string +type ListCompartmentsAccessLevelEnum string + +// Set of constants representing the allowable values for ListCompartmentsAccessLevelEnum +const ( + ListCompartmentsAccessLevelAny ListCompartmentsAccessLevelEnum = "ANY" + ListCompartmentsAccessLevelAccessible ListCompartmentsAccessLevelEnum = "ACCESSIBLE" +) + +var mappingListCompartmentsAccessLevel = map[string]ListCompartmentsAccessLevelEnum{ + "ANY": ListCompartmentsAccessLevelAny, + "ACCESSIBLE": ListCompartmentsAccessLevelAccessible, +} + +// GetListCompartmentsAccessLevelEnumValues Enumerates the set of values for ListCompartmentsAccessLevelEnum +func GetListCompartmentsAccessLevelEnumValues() []ListCompartmentsAccessLevelEnum { + values := make([]ListCompartmentsAccessLevelEnum, 0) + for _, v := range mappingListCompartmentsAccessLevel { + values = append(values, v) + } + return values +} + +// ListCompartmentsSortByEnum Enum with underlying type: string +type ListCompartmentsSortByEnum string + +// Set of constants representing the allowable values for ListCompartmentsSortByEnum +const ( + ListCompartmentsSortByTimecreated ListCompartmentsSortByEnum = "TIMECREATED" + ListCompartmentsSortByName ListCompartmentsSortByEnum = "NAME" +) + +var mappingListCompartmentsSortBy = map[string]ListCompartmentsSortByEnum{ + "TIMECREATED": ListCompartmentsSortByTimecreated, + "NAME": ListCompartmentsSortByName, +} + +// GetListCompartmentsSortByEnumValues Enumerates the set of values for ListCompartmentsSortByEnum +func GetListCompartmentsSortByEnumValues() []ListCompartmentsSortByEnum { + values := make([]ListCompartmentsSortByEnum, 0) + for _, v := range mappingListCompartmentsSortBy { + values = append(values, v) + } + return values +} + +// ListCompartmentsSortOrderEnum Enum with underlying type: string +type ListCompartmentsSortOrderEnum string + +// Set of constants representing the allowable values for ListCompartmentsSortOrderEnum +const ( + ListCompartmentsSortOrderAsc ListCompartmentsSortOrderEnum = "ASC" + ListCompartmentsSortOrderDesc ListCompartmentsSortOrderEnum = "DESC" +) + +var mappingListCompartmentsSortOrder = map[string]ListCompartmentsSortOrderEnum{ + "ASC": ListCompartmentsSortOrderAsc, + "DESC": ListCompartmentsSortOrderDesc, +} + +// GetListCompartmentsSortOrderEnumValues Enumerates the set of values for ListCompartmentsSortOrderEnum +func GetListCompartmentsSortOrderEnumValues() []ListCompartmentsSortOrderEnum { + values := make([]ListCompartmentsSortOrderEnum, 0) + for _, v := range mappingListCompartmentsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_cost_tracking_tags_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_cost_tracking_tags_request_response.go new file mode 100644 index 000000000..4be21d092 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_cost_tracking_tags_request_response.go @@ -0,0 +1,86 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListCostTrackingTagsRequest wrapper for the ListCostTrackingTags operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListCostTrackingTags.go.html to see an example of how to use ListCostTrackingTagsRequest. +type ListCostTrackingTagsRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListCostTrackingTagsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListCostTrackingTagsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListCostTrackingTagsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListCostTrackingTagsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListCostTrackingTagsResponse wrapper for the ListCostTrackingTags operation +type ListCostTrackingTagsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Tag instances + Items []Tag `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of cost tracking tag. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. For important details about how pagination works, + // see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListCostTrackingTagsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListCostTrackingTagsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_customer_secret_keys_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_customer_secret_keys_request_response.go new file mode 100644 index 000000000..87ccba838 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_customer_secret_keys_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListCustomerSecretKeysRequest wrapper for the ListCustomerSecretKeys operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListCustomerSecretKeys.go.html to see an example of how to use ListCustomerSecretKeysRequest. +type ListCustomerSecretKeysRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListCustomerSecretKeysRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListCustomerSecretKeysRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListCustomerSecretKeysRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListCustomerSecretKeysRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListCustomerSecretKeysResponse wrapper for the ListCustomerSecretKeys operation +type ListCustomerSecretKeysResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []CustomerSecretKeySummary instance + Items []CustomerSecretKeySummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListCustomerSecretKeysResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListCustomerSecretKeysResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_db_credentials_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_db_credentials_request_response.go new file mode 100644 index 000000000..b630d339a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_db_credentials_request_response.go @@ -0,0 +1,150 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListDbCredentialsRequest wrapper for the ListDbCredentials operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListDbCredentials.go.html to see an example of how to use ListDbCredentialsRequest. +type ListDbCredentialsRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // A filter to only return resources that match the given name exactly. + Name *string `mandatory:"false" contributesTo:"query" name:"name"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for NAME is ascending. The NAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by Availability Domain if the scope of the resource type is within a + // single Availability Domain. If you call one of these "List" operations without specifying + // an Availability Domain, the resources are grouped by Availability Domain, then sorted. + SortBy ListDbCredentialsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The NAME sort order + // is case sensitive. + SortOrder ListDbCredentialsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState DbCredentialLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListDbCredentialsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListDbCredentialsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListDbCredentialsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListDbCredentialsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListDbCredentialsResponse wrapper for the ListDbCredentials operation +type ListDbCredentialsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []DbCredentialSummary instances + Items []DbCredentialSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListDbCredentialsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListDbCredentialsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListDbCredentialsSortByEnum Enum with underlying type: string +type ListDbCredentialsSortByEnum string + +// Set of constants representing the allowable values for ListDbCredentialsSortByEnum +const ( + ListDbCredentialsSortByTimecreated ListDbCredentialsSortByEnum = "TIMECREATED" + ListDbCredentialsSortByName ListDbCredentialsSortByEnum = "NAME" +) + +var mappingListDbCredentialsSortBy = map[string]ListDbCredentialsSortByEnum{ + "TIMECREATED": ListDbCredentialsSortByTimecreated, + "NAME": ListDbCredentialsSortByName, +} + +// GetListDbCredentialsSortByEnumValues Enumerates the set of values for ListDbCredentialsSortByEnum +func GetListDbCredentialsSortByEnumValues() []ListDbCredentialsSortByEnum { + values := make([]ListDbCredentialsSortByEnum, 0) + for _, v := range mappingListDbCredentialsSortBy { + values = append(values, v) + } + return values +} + +// ListDbCredentialsSortOrderEnum Enum with underlying type: string +type ListDbCredentialsSortOrderEnum string + +// Set of constants representing the allowable values for ListDbCredentialsSortOrderEnum +const ( + ListDbCredentialsSortOrderAsc ListDbCredentialsSortOrderEnum = "ASC" + ListDbCredentialsSortOrderDesc ListDbCredentialsSortOrderEnum = "DESC" +) + +var mappingListDbCredentialsSortOrder = map[string]ListDbCredentialsSortOrderEnum{ + "ASC": ListDbCredentialsSortOrderAsc, + "DESC": ListDbCredentialsSortOrderDesc, +} + +// GetListDbCredentialsSortOrderEnumValues Enumerates the set of values for ListDbCredentialsSortOrderEnum +func GetListDbCredentialsSortOrderEnumValues() []ListDbCredentialsSortOrderEnum { + values := make([]ListDbCredentialsSortOrderEnum, 0) + for _, v := range mappingListDbCredentialsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_domains_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_domains_request_response.go new file mode 100644 index 000000000..1c4b15590 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_domains_request_response.go @@ -0,0 +1,168 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListDomainsRequest wrapper for the ListDomains operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListDomains.go.html to see an example of how to use ListDomainsRequest. +type ListDomainsRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The mutable display name of the domain + DisplayName *string `mandatory:"false" contributesTo:"query" name:"displayName"` + + // The region agnostic domain URL + Url *string `mandatory:"false" contributesTo:"query" name:"url"` + + // The region specific domain URL + HomeRegionUrl *string `mandatory:"false" contributesTo:"query" name:"homeRegionUrl"` + + // The domain type + Type *string `mandatory:"false" contributesTo:"query" name:"type"` + + // The domain license type + LicenseType *string `mandatory:"false" contributesTo:"query" name:"licenseType"` + + // Indicate if the domain is visible at login screen or not + IsHiddenOnLogin *bool `mandatory:"false" contributesTo:"query" name:"isHiddenOnLogin"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // A filter to only return resources that match the given name exactly. + Name *string `mandatory:"false" contributesTo:"query" name:"name"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for NAME is ascending. The NAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by Availability Domain if the scope of the resource type is within a + // single Availability Domain. If you call one of these "List" operations without specifying + // an Availability Domain, the resources are grouped by Availability Domain, then sorted. + SortBy ListDomainsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The NAME sort order + // is case sensitive. + SortOrder ListDomainsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState DomainLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListDomainsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListDomainsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListDomainsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListDomainsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListDomainsResponse wrapper for the ListDomains operation +type ListDomainsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []DomainSummary instances + Items []DomainSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListDomainsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListDomainsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListDomainsSortByEnum Enum with underlying type: string +type ListDomainsSortByEnum string + +// Set of constants representing the allowable values for ListDomainsSortByEnum +const ( + ListDomainsSortByTimecreated ListDomainsSortByEnum = "TIMECREATED" + ListDomainsSortByName ListDomainsSortByEnum = "NAME" +) + +var mappingListDomainsSortBy = map[string]ListDomainsSortByEnum{ + "TIMECREATED": ListDomainsSortByTimecreated, + "NAME": ListDomainsSortByName, +} + +// GetListDomainsSortByEnumValues Enumerates the set of values for ListDomainsSortByEnum +func GetListDomainsSortByEnumValues() []ListDomainsSortByEnum { + values := make([]ListDomainsSortByEnum, 0) + for _, v := range mappingListDomainsSortBy { + values = append(values, v) + } + return values +} + +// ListDomainsSortOrderEnum Enum with underlying type: string +type ListDomainsSortOrderEnum string + +// Set of constants representing the allowable values for ListDomainsSortOrderEnum +const ( + ListDomainsSortOrderAsc ListDomainsSortOrderEnum = "ASC" + ListDomainsSortOrderDesc ListDomainsSortOrderEnum = "DESC" +) + +var mappingListDomainsSortOrder = map[string]ListDomainsSortOrderEnum{ + "ASC": ListDomainsSortOrderAsc, + "DESC": ListDomainsSortOrderDesc, +} + +// GetListDomainsSortOrderEnumValues Enumerates the set of values for ListDomainsSortOrderEnum +func GetListDomainsSortOrderEnumValues() []ListDomainsSortOrderEnum { + values := make([]ListDomainsSortOrderEnum, 0) + for _, v := range mappingListDomainsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_dynamic_groups_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_dynamic_groups_request_response.go new file mode 100644 index 000000000..8590a9f84 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_dynamic_groups_request_response.go @@ -0,0 +1,150 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListDynamicGroupsRequest wrapper for the ListDynamicGroups operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListDynamicGroups.go.html to see an example of how to use ListDynamicGroupsRequest. +type ListDynamicGroupsRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // A filter to only return resources that match the given name exactly. + Name *string `mandatory:"false" contributesTo:"query" name:"name"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for NAME is ascending. The NAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by Availability Domain if the scope of the resource type is within a + // single Availability Domain. If you call one of these "List" operations without specifying + // an Availability Domain, the resources are grouped by Availability Domain, then sorted. + SortBy ListDynamicGroupsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The NAME sort order + // is case sensitive. + SortOrder ListDynamicGroupsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState DynamicGroupLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListDynamicGroupsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListDynamicGroupsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListDynamicGroupsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListDynamicGroupsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListDynamicGroupsResponse wrapper for the ListDynamicGroups operation +type ListDynamicGroupsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []DynamicGroup instances + Items []DynamicGroup `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListDynamicGroupsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListDynamicGroupsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListDynamicGroupsSortByEnum Enum with underlying type: string +type ListDynamicGroupsSortByEnum string + +// Set of constants representing the allowable values for ListDynamicGroupsSortByEnum +const ( + ListDynamicGroupsSortByTimecreated ListDynamicGroupsSortByEnum = "TIMECREATED" + ListDynamicGroupsSortByName ListDynamicGroupsSortByEnum = "NAME" +) + +var mappingListDynamicGroupsSortBy = map[string]ListDynamicGroupsSortByEnum{ + "TIMECREATED": ListDynamicGroupsSortByTimecreated, + "NAME": ListDynamicGroupsSortByName, +} + +// GetListDynamicGroupsSortByEnumValues Enumerates the set of values for ListDynamicGroupsSortByEnum +func GetListDynamicGroupsSortByEnumValues() []ListDynamicGroupsSortByEnum { + values := make([]ListDynamicGroupsSortByEnum, 0) + for _, v := range mappingListDynamicGroupsSortBy { + values = append(values, v) + } + return values +} + +// ListDynamicGroupsSortOrderEnum Enum with underlying type: string +type ListDynamicGroupsSortOrderEnum string + +// Set of constants representing the allowable values for ListDynamicGroupsSortOrderEnum +const ( + ListDynamicGroupsSortOrderAsc ListDynamicGroupsSortOrderEnum = "ASC" + ListDynamicGroupsSortOrderDesc ListDynamicGroupsSortOrderEnum = "DESC" +) + +var mappingListDynamicGroupsSortOrder = map[string]ListDynamicGroupsSortOrderEnum{ + "ASC": ListDynamicGroupsSortOrderAsc, + "DESC": ListDynamicGroupsSortOrderDesc, +} + +// GetListDynamicGroupsSortOrderEnumValues Enumerates the set of values for ListDynamicGroupsSortOrderEnum +func GetListDynamicGroupsSortOrderEnumValues() []ListDynamicGroupsSortOrderEnum { + values := make([]ListDynamicGroupsSortOrderEnum, 0) + for _, v := range mappingListDynamicGroupsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_fault_domains_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_fault_domains_request_response.go new file mode 100644 index 000000000..40ded7819 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_fault_domains_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListFaultDomainsRequest wrapper for the ListFaultDomains operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListFaultDomains.go.html to see an example of how to use ListFaultDomainsRequest. +type ListFaultDomainsRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The name of the availibilityDomain. + AvailabilityDomain *string `mandatory:"true" contributesTo:"query" name:"availabilityDomain"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListFaultDomainsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListFaultDomainsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListFaultDomainsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListFaultDomainsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListFaultDomainsResponse wrapper for the ListFaultDomains operation +type ListFaultDomainsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []FaultDomain instance + Items []FaultDomain `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListFaultDomainsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListFaultDomainsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_groups_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_groups_request_response.go new file mode 100644 index 000000000..0ca2df542 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_groups_request_response.go @@ -0,0 +1,150 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListGroupsRequest wrapper for the ListGroups operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListGroups.go.html to see an example of how to use ListGroupsRequest. +type ListGroupsRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // A filter to only return resources that match the given name exactly. + Name *string `mandatory:"false" contributesTo:"query" name:"name"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for NAME is ascending. The NAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by Availability Domain if the scope of the resource type is within a + // single Availability Domain. If you call one of these "List" operations without specifying + // an Availability Domain, the resources are grouped by Availability Domain, then sorted. + SortBy ListGroupsSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The NAME sort order + // is case sensitive. + SortOrder ListGroupsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState GroupLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListGroupsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListGroupsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListGroupsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListGroupsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListGroupsResponse wrapper for the ListGroups operation +type ListGroupsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Group instances + Items []Group `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListGroupsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListGroupsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListGroupsSortByEnum Enum with underlying type: string +type ListGroupsSortByEnum string + +// Set of constants representing the allowable values for ListGroupsSortByEnum +const ( + ListGroupsSortByTimecreated ListGroupsSortByEnum = "TIMECREATED" + ListGroupsSortByName ListGroupsSortByEnum = "NAME" +) + +var mappingListGroupsSortBy = map[string]ListGroupsSortByEnum{ + "TIMECREATED": ListGroupsSortByTimecreated, + "NAME": ListGroupsSortByName, +} + +// GetListGroupsSortByEnumValues Enumerates the set of values for ListGroupsSortByEnum +func GetListGroupsSortByEnumValues() []ListGroupsSortByEnum { + values := make([]ListGroupsSortByEnum, 0) + for _, v := range mappingListGroupsSortBy { + values = append(values, v) + } + return values +} + +// ListGroupsSortOrderEnum Enum with underlying type: string +type ListGroupsSortOrderEnum string + +// Set of constants representing the allowable values for ListGroupsSortOrderEnum +const ( + ListGroupsSortOrderAsc ListGroupsSortOrderEnum = "ASC" + ListGroupsSortOrderDesc ListGroupsSortOrderEnum = "DESC" +) + +var mappingListGroupsSortOrder = map[string]ListGroupsSortOrderEnum{ + "ASC": ListGroupsSortOrderAsc, + "DESC": ListGroupsSortOrderDesc, +} + +// GetListGroupsSortOrderEnumValues Enumerates the set of values for ListGroupsSortOrderEnum +func GetListGroupsSortOrderEnumValues() []ListGroupsSortOrderEnum { + values := make([]ListGroupsSortOrderEnum, 0) + for _, v := range mappingListGroupsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_iam_work_request_errors_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_iam_work_request_errors_request_response.go new file mode 100644 index 000000000..bde03b607 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_iam_work_request_errors_request_response.go @@ -0,0 +1,112 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListIamWorkRequestErrorsRequest wrapper for the ListIamWorkRequestErrors operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListIamWorkRequestErrors.go.html to see an example of how to use ListIamWorkRequestErrorsRequest. +type ListIamWorkRequestErrorsRequest struct { + + // The OCID of the IAM work request. + IamWorkRequestId *string `mandatory:"true" contributesTo:"path" name:"iamWorkRequestId"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The NAME sort order + // is case sensitive. + SortOrder ListIamWorkRequestErrorsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListIamWorkRequestErrorsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListIamWorkRequestErrorsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListIamWorkRequestErrorsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListIamWorkRequestErrorsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListIamWorkRequestErrorsResponse wrapper for the ListIamWorkRequestErrors operation +type ListIamWorkRequestErrorsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []IamWorkRequestErrorSummary instances + Items []IamWorkRequestErrorSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages of + // results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListIamWorkRequestErrorsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListIamWorkRequestErrorsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListIamWorkRequestErrorsSortOrderEnum Enum with underlying type: string +type ListIamWorkRequestErrorsSortOrderEnum string + +// Set of constants representing the allowable values for ListIamWorkRequestErrorsSortOrderEnum +const ( + ListIamWorkRequestErrorsSortOrderAsc ListIamWorkRequestErrorsSortOrderEnum = "ASC" + ListIamWorkRequestErrorsSortOrderDesc ListIamWorkRequestErrorsSortOrderEnum = "DESC" +) + +var mappingListIamWorkRequestErrorsSortOrder = map[string]ListIamWorkRequestErrorsSortOrderEnum{ + "ASC": ListIamWorkRequestErrorsSortOrderAsc, + "DESC": ListIamWorkRequestErrorsSortOrderDesc, +} + +// GetListIamWorkRequestErrorsSortOrderEnumValues Enumerates the set of values for ListIamWorkRequestErrorsSortOrderEnum +func GetListIamWorkRequestErrorsSortOrderEnumValues() []ListIamWorkRequestErrorsSortOrderEnum { + values := make([]ListIamWorkRequestErrorsSortOrderEnum, 0) + for _, v := range mappingListIamWorkRequestErrorsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_iam_work_request_logs_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_iam_work_request_logs_request_response.go new file mode 100644 index 000000000..3d9e541b1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_iam_work_request_logs_request_response.go @@ -0,0 +1,115 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListIamWorkRequestLogsRequest wrapper for the ListIamWorkRequestLogs operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListIamWorkRequestLogs.go.html to see an example of how to use ListIamWorkRequestLogsRequest. +type ListIamWorkRequestLogsRequest struct { + + // The OCID of the IAM work request. + IamWorkRequestId *string `mandatory:"true" contributesTo:"path" name:"iamWorkRequestId"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The NAME sort order + // is case sensitive. + SortOrder ListIamWorkRequestLogsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListIamWorkRequestLogsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListIamWorkRequestLogsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListIamWorkRequestLogsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListIamWorkRequestLogsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListIamWorkRequestLogsResponse wrapper for the ListIamWorkRequestLogs operation +type ListIamWorkRequestLogsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []IamWorkRequestLogSummary instances + Items []IamWorkRequestLogSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The number of seconds that the client should wait before polling again. + RetryAfter *float32 `presentIn:"header" name:"retry-after"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListIamWorkRequestLogsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListIamWorkRequestLogsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListIamWorkRequestLogsSortOrderEnum Enum with underlying type: string +type ListIamWorkRequestLogsSortOrderEnum string + +// Set of constants representing the allowable values for ListIamWorkRequestLogsSortOrderEnum +const ( + ListIamWorkRequestLogsSortOrderAsc ListIamWorkRequestLogsSortOrderEnum = "ASC" + ListIamWorkRequestLogsSortOrderDesc ListIamWorkRequestLogsSortOrderEnum = "DESC" +) + +var mappingListIamWorkRequestLogsSortOrder = map[string]ListIamWorkRequestLogsSortOrderEnum{ + "ASC": ListIamWorkRequestLogsSortOrderAsc, + "DESC": ListIamWorkRequestLogsSortOrderDesc, +} + +// GetListIamWorkRequestLogsSortOrderEnumValues Enumerates the set of values for ListIamWorkRequestLogsSortOrderEnum +func GetListIamWorkRequestLogsSortOrderEnumValues() []ListIamWorkRequestLogsSortOrderEnum { + values := make([]ListIamWorkRequestLogsSortOrderEnum, 0) + for _, v := range mappingListIamWorkRequestLogsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_iam_work_requests_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_iam_work_requests_request_response.go new file mode 100644 index 000000000..ef9f9b1e8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_iam_work_requests_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListIamWorkRequestsRequest wrapper for the ListIamWorkRequests operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListIamWorkRequests.go.html to see an example of how to use ListIamWorkRequestsRequest. +type ListIamWorkRequestsRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // The identifier of the resource the work request affects. + ResourceIdentifier *string `mandatory:"false" contributesTo:"query" name:"resourceIdentifier"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListIamWorkRequestsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListIamWorkRequestsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListIamWorkRequestsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListIamWorkRequestsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListIamWorkRequestsResponse wrapper for the ListIamWorkRequests operation +type ListIamWorkRequestsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []IamWorkRequestSummary instances + Items []IamWorkRequestSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListIamWorkRequestsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListIamWorkRequestsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_identity_provider_groups_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_identity_provider_groups_request_response.go new file mode 100644 index 000000000..d095b9869 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_identity_provider_groups_request_response.go @@ -0,0 +1,91 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListIdentityProviderGroupsRequest wrapper for the ListIdentityProviderGroups operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListIdentityProviderGroups.go.html to see an example of how to use ListIdentityProviderGroupsRequest. +type ListIdentityProviderGroupsRequest struct { + + // The OCID of the identity provider. + IdentityProviderId *string `mandatory:"true" contributesTo:"path" name:"identityProviderId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // A filter to only return resources that match the given name exactly. + Name *string `mandatory:"false" contributesTo:"query" name:"name"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState IdentityProviderLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListIdentityProviderGroupsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListIdentityProviderGroupsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListIdentityProviderGroupsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListIdentityProviderGroupsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListIdentityProviderGroupsResponse wrapper for the ListIdentityProviderGroups operation +type ListIdentityProviderGroupsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []IdentityProviderGroupSummary instances + Items []IdentityProviderGroupSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListIdentityProviderGroupsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListIdentityProviderGroupsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_identity_providers_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_identity_providers_request_response.go new file mode 100644 index 000000000..967dfc8c1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_identity_providers_request_response.go @@ -0,0 +1,174 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListIdentityProvidersRequest wrapper for the ListIdentityProviders operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListIdentityProviders.go.html to see an example of how to use ListIdentityProvidersRequest. +type ListIdentityProvidersRequest struct { + + // The protocol used for federation. + Protocol ListIdentityProvidersProtocolEnum `mandatory:"true" contributesTo:"query" name:"protocol" omitEmpty:"true"` + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // A filter to only return resources that match the given name exactly. + Name *string `mandatory:"false" contributesTo:"query" name:"name"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for NAME is ascending. The NAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by Availability Domain if the scope of the resource type is within a + // single Availability Domain. If you call one of these "List" operations without specifying + // an Availability Domain, the resources are grouped by Availability Domain, then sorted. + SortBy ListIdentityProvidersSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The NAME sort order + // is case sensitive. + SortOrder ListIdentityProvidersSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState IdentityProviderLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListIdentityProvidersRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListIdentityProvidersRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListIdentityProvidersRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListIdentityProvidersRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListIdentityProvidersResponse wrapper for the ListIdentityProviders operation +type ListIdentityProvidersResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []IdentityProvider instances + Items []IdentityProvider `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListIdentityProvidersResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListIdentityProvidersResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListIdentityProvidersProtocolEnum Enum with underlying type: string +type ListIdentityProvidersProtocolEnum string + +// Set of constants representing the allowable values for ListIdentityProvidersProtocolEnum +const ( + ListIdentityProvidersProtocolSaml2 ListIdentityProvidersProtocolEnum = "SAML2" +) + +var mappingListIdentityProvidersProtocol = map[string]ListIdentityProvidersProtocolEnum{ + "SAML2": ListIdentityProvidersProtocolSaml2, +} + +// GetListIdentityProvidersProtocolEnumValues Enumerates the set of values for ListIdentityProvidersProtocolEnum +func GetListIdentityProvidersProtocolEnumValues() []ListIdentityProvidersProtocolEnum { + values := make([]ListIdentityProvidersProtocolEnum, 0) + for _, v := range mappingListIdentityProvidersProtocol { + values = append(values, v) + } + return values +} + +// ListIdentityProvidersSortByEnum Enum with underlying type: string +type ListIdentityProvidersSortByEnum string + +// Set of constants representing the allowable values for ListIdentityProvidersSortByEnum +const ( + ListIdentityProvidersSortByTimecreated ListIdentityProvidersSortByEnum = "TIMECREATED" + ListIdentityProvidersSortByName ListIdentityProvidersSortByEnum = "NAME" +) + +var mappingListIdentityProvidersSortBy = map[string]ListIdentityProvidersSortByEnum{ + "TIMECREATED": ListIdentityProvidersSortByTimecreated, + "NAME": ListIdentityProvidersSortByName, +} + +// GetListIdentityProvidersSortByEnumValues Enumerates the set of values for ListIdentityProvidersSortByEnum +func GetListIdentityProvidersSortByEnumValues() []ListIdentityProvidersSortByEnum { + values := make([]ListIdentityProvidersSortByEnum, 0) + for _, v := range mappingListIdentityProvidersSortBy { + values = append(values, v) + } + return values +} + +// ListIdentityProvidersSortOrderEnum Enum with underlying type: string +type ListIdentityProvidersSortOrderEnum string + +// Set of constants representing the allowable values for ListIdentityProvidersSortOrderEnum +const ( + ListIdentityProvidersSortOrderAsc ListIdentityProvidersSortOrderEnum = "ASC" + ListIdentityProvidersSortOrderDesc ListIdentityProvidersSortOrderEnum = "DESC" +) + +var mappingListIdentityProvidersSortOrder = map[string]ListIdentityProvidersSortOrderEnum{ + "ASC": ListIdentityProvidersSortOrderAsc, + "DESC": ListIdentityProvidersSortOrderDesc, +} + +// GetListIdentityProvidersSortOrderEnumValues Enumerates the set of values for ListIdentityProvidersSortOrderEnum +func GetListIdentityProvidersSortOrderEnumValues() []ListIdentityProvidersSortOrderEnum { + values := make([]ListIdentityProvidersSortOrderEnum, 0) + for _, v := range mappingListIdentityProvidersSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_idp_group_mappings_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_idp_group_mappings_request_response.go new file mode 100644 index 000000000..cdb7c91a8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_idp_group_mappings_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListIdpGroupMappingsRequest wrapper for the ListIdpGroupMappings operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListIdpGroupMappings.go.html to see an example of how to use ListIdpGroupMappingsRequest. +type ListIdpGroupMappingsRequest struct { + + // The OCID of the identity provider. + IdentityProviderId *string `mandatory:"true" contributesTo:"path" name:"identityProviderId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListIdpGroupMappingsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListIdpGroupMappingsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListIdpGroupMappingsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListIdpGroupMappingsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListIdpGroupMappingsResponse wrapper for the ListIdpGroupMappings operation +type ListIdpGroupMappingsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []IdpGroupMapping instances + Items []IdpGroupMapping `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListIdpGroupMappingsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListIdpGroupMappingsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_mfa_totp_devices_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_mfa_totp_devices_request_response.go new file mode 100644 index 000000000..257a3cbeb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_mfa_totp_devices_request_response.go @@ -0,0 +1,144 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListMfaTotpDevicesRequest wrapper for the ListMfaTotpDevices operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListMfaTotpDevices.go.html to see an example of how to use ListMfaTotpDevicesRequest. +type ListMfaTotpDevicesRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for NAME is ascending. The NAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by Availability Domain if the scope of the resource type is within a + // single Availability Domain. If you call one of these "List" operations without specifying + // an Availability Domain, the resources are grouped by Availability Domain, then sorted. + SortBy ListMfaTotpDevicesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The NAME sort order + // is case sensitive. + SortOrder ListMfaTotpDevicesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListMfaTotpDevicesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListMfaTotpDevicesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListMfaTotpDevicesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListMfaTotpDevicesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListMfaTotpDevicesResponse wrapper for the ListMfaTotpDevices operation +type ListMfaTotpDevicesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []MfaTotpDeviceSummary instances + Items []MfaTotpDeviceSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListMfaTotpDevicesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListMfaTotpDevicesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListMfaTotpDevicesSortByEnum Enum with underlying type: string +type ListMfaTotpDevicesSortByEnum string + +// Set of constants representing the allowable values for ListMfaTotpDevicesSortByEnum +const ( + ListMfaTotpDevicesSortByTimecreated ListMfaTotpDevicesSortByEnum = "TIMECREATED" + ListMfaTotpDevicesSortByName ListMfaTotpDevicesSortByEnum = "NAME" +) + +var mappingListMfaTotpDevicesSortBy = map[string]ListMfaTotpDevicesSortByEnum{ + "TIMECREATED": ListMfaTotpDevicesSortByTimecreated, + "NAME": ListMfaTotpDevicesSortByName, +} + +// GetListMfaTotpDevicesSortByEnumValues Enumerates the set of values for ListMfaTotpDevicesSortByEnum +func GetListMfaTotpDevicesSortByEnumValues() []ListMfaTotpDevicesSortByEnum { + values := make([]ListMfaTotpDevicesSortByEnum, 0) + for _, v := range mappingListMfaTotpDevicesSortBy { + values = append(values, v) + } + return values +} + +// ListMfaTotpDevicesSortOrderEnum Enum with underlying type: string +type ListMfaTotpDevicesSortOrderEnum string + +// Set of constants representing the allowable values for ListMfaTotpDevicesSortOrderEnum +const ( + ListMfaTotpDevicesSortOrderAsc ListMfaTotpDevicesSortOrderEnum = "ASC" + ListMfaTotpDevicesSortOrderDesc ListMfaTotpDevicesSortOrderEnum = "DESC" +) + +var mappingListMfaTotpDevicesSortOrder = map[string]ListMfaTotpDevicesSortOrderEnum{ + "ASC": ListMfaTotpDevicesSortOrderAsc, + "DESC": ListMfaTotpDevicesSortOrderDesc, +} + +// GetListMfaTotpDevicesSortOrderEnumValues Enumerates the set of values for ListMfaTotpDevicesSortOrderEnum +func GetListMfaTotpDevicesSortOrderEnumValues() []ListMfaTotpDevicesSortOrderEnum { + values := make([]ListMfaTotpDevicesSortOrderEnum, 0) + for _, v := range mappingListMfaTotpDevicesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_network_sources_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_network_sources_request_response.go new file mode 100644 index 000000000..d41d322f7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_network_sources_request_response.go @@ -0,0 +1,150 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListNetworkSourcesRequest wrapper for the ListNetworkSources operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListNetworkSources.go.html to see an example of how to use ListNetworkSourcesRequest. +type ListNetworkSourcesRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // A filter to only return resources that match the given name exactly. + Name *string `mandatory:"false" contributesTo:"query" name:"name"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for NAME is ascending. The NAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by Availability Domain if the scope of the resource type is within a + // single Availability Domain. If you call one of these "List" operations without specifying + // an Availability Domain, the resources are grouped by Availability Domain, then sorted. + SortBy ListNetworkSourcesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The NAME sort order + // is case sensitive. + SortOrder ListNetworkSourcesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState NetworkSourcesLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListNetworkSourcesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListNetworkSourcesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListNetworkSourcesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListNetworkSourcesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListNetworkSourcesResponse wrapper for the ListNetworkSources operation +type ListNetworkSourcesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []NetworkSourcesSummary instances + Items []NetworkSourcesSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListNetworkSourcesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListNetworkSourcesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListNetworkSourcesSortByEnum Enum with underlying type: string +type ListNetworkSourcesSortByEnum string + +// Set of constants representing the allowable values for ListNetworkSourcesSortByEnum +const ( + ListNetworkSourcesSortByTimecreated ListNetworkSourcesSortByEnum = "TIMECREATED" + ListNetworkSourcesSortByName ListNetworkSourcesSortByEnum = "NAME" +) + +var mappingListNetworkSourcesSortBy = map[string]ListNetworkSourcesSortByEnum{ + "TIMECREATED": ListNetworkSourcesSortByTimecreated, + "NAME": ListNetworkSourcesSortByName, +} + +// GetListNetworkSourcesSortByEnumValues Enumerates the set of values for ListNetworkSourcesSortByEnum +func GetListNetworkSourcesSortByEnumValues() []ListNetworkSourcesSortByEnum { + values := make([]ListNetworkSourcesSortByEnum, 0) + for _, v := range mappingListNetworkSourcesSortBy { + values = append(values, v) + } + return values +} + +// ListNetworkSourcesSortOrderEnum Enum with underlying type: string +type ListNetworkSourcesSortOrderEnum string + +// Set of constants representing the allowable values for ListNetworkSourcesSortOrderEnum +const ( + ListNetworkSourcesSortOrderAsc ListNetworkSourcesSortOrderEnum = "ASC" + ListNetworkSourcesSortOrderDesc ListNetworkSourcesSortOrderEnum = "DESC" +) + +var mappingListNetworkSourcesSortOrder = map[string]ListNetworkSourcesSortOrderEnum{ + "ASC": ListNetworkSourcesSortOrderAsc, + "DESC": ListNetworkSourcesSortOrderDesc, +} + +// GetListNetworkSourcesSortOrderEnumValues Enumerates the set of values for ListNetworkSourcesSortOrderEnum +func GetListNetworkSourcesSortOrderEnumValues() []ListNetworkSourcesSortOrderEnum { + values := make([]ListNetworkSourcesSortOrderEnum, 0) + for _, v := range mappingListNetworkSourcesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_o_auth_client_credentials_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_o_auth_client_credentials_request_response.go new file mode 100644 index 000000000..53edc9e23 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_o_auth_client_credentials_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListOAuthClientCredentialsRequest wrapper for the ListOAuthClientCredentials operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListOAuthClientCredentials.go.html to see an example of how to use ListOAuthClientCredentialsRequest. +type ListOAuthClientCredentialsRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState OAuth2ClientCredentialSummaryLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListOAuthClientCredentialsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListOAuthClientCredentialsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListOAuthClientCredentialsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListOAuthClientCredentialsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListOAuthClientCredentialsResponse wrapper for the ListOAuthClientCredentials operation +type ListOAuthClientCredentialsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []OAuth2ClientCredentialSummary instances + Items []OAuth2ClientCredentialSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListOAuthClientCredentialsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListOAuthClientCredentialsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_policies_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_policies_request_response.go new file mode 100644 index 000000000..364826f8f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_policies_request_response.go @@ -0,0 +1,150 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListPoliciesRequest wrapper for the ListPolicies operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListPolicies.go.html to see an example of how to use ListPoliciesRequest. +type ListPoliciesRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // A filter to only return resources that match the given name exactly. + Name *string `mandatory:"false" contributesTo:"query" name:"name"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for NAME is ascending. The NAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by Availability Domain if the scope of the resource type is within a + // single Availability Domain. If you call one of these "List" operations without specifying + // an Availability Domain, the resources are grouped by Availability Domain, then sorted. + SortBy ListPoliciesSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The NAME sort order + // is case sensitive. + SortOrder ListPoliciesSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState PolicyLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListPoliciesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListPoliciesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListPoliciesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListPoliciesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListPoliciesResponse wrapper for the ListPolicies operation +type ListPoliciesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []Policy instances + Items []Policy `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListPoliciesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListPoliciesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListPoliciesSortByEnum Enum with underlying type: string +type ListPoliciesSortByEnum string + +// Set of constants representing the allowable values for ListPoliciesSortByEnum +const ( + ListPoliciesSortByTimecreated ListPoliciesSortByEnum = "TIMECREATED" + ListPoliciesSortByName ListPoliciesSortByEnum = "NAME" +) + +var mappingListPoliciesSortBy = map[string]ListPoliciesSortByEnum{ + "TIMECREATED": ListPoliciesSortByTimecreated, + "NAME": ListPoliciesSortByName, +} + +// GetListPoliciesSortByEnumValues Enumerates the set of values for ListPoliciesSortByEnum +func GetListPoliciesSortByEnumValues() []ListPoliciesSortByEnum { + values := make([]ListPoliciesSortByEnum, 0) + for _, v := range mappingListPoliciesSortBy { + values = append(values, v) + } + return values +} + +// ListPoliciesSortOrderEnum Enum with underlying type: string +type ListPoliciesSortOrderEnum string + +// Set of constants representing the allowable values for ListPoliciesSortOrderEnum +const ( + ListPoliciesSortOrderAsc ListPoliciesSortOrderEnum = "ASC" + ListPoliciesSortOrderDesc ListPoliciesSortOrderEnum = "DESC" +) + +var mappingListPoliciesSortOrder = map[string]ListPoliciesSortOrderEnum{ + "ASC": ListPoliciesSortOrderAsc, + "DESC": ListPoliciesSortOrderDesc, +} + +// GetListPoliciesSortOrderEnumValues Enumerates the set of values for ListPoliciesSortOrderEnum +func GetListPoliciesSortOrderEnumValues() []ListPoliciesSortOrderEnum { + values := make([]ListPoliciesSortOrderEnum, 0) + for _, v := range mappingListPoliciesSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_region_subscriptions_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_region_subscriptions_request_response.go new file mode 100644 index 000000000..95580ca58 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_region_subscriptions_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListRegionSubscriptionsRequest wrapper for the ListRegionSubscriptions operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListRegionSubscriptions.go.html to see an example of how to use ListRegionSubscriptionsRequest. +type ListRegionSubscriptionsRequest struct { + + // The OCID of the tenancy. + TenancyId *string `mandatory:"true" contributesTo:"path" name:"tenancyId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListRegionSubscriptionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListRegionSubscriptionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListRegionSubscriptionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListRegionSubscriptionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListRegionSubscriptionsResponse wrapper for the ListRegionSubscriptions operation +type ListRegionSubscriptionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []RegionSubscription instance + Items []RegionSubscription `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListRegionSubscriptionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListRegionSubscriptionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_regions_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_regions_request_response.go new file mode 100644 index 000000000..dcb089795 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_regions_request_response.go @@ -0,0 +1,71 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListRegionsRequest wrapper for the ListRegions operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListRegions.go.html to see an example of how to use ListRegionsRequest. +type ListRegionsRequest struct { + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListRegionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListRegionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListRegionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListRegionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListRegionsResponse wrapper for the ListRegions operation +type ListRegionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []Region instance + Items []Region `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListRegionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListRegionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_smtp_credentials_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_smtp_credentials_request_response.go new file mode 100644 index 000000000..69b3860e4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_smtp_credentials_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListSmtpCredentialsRequest wrapper for the ListSmtpCredentials operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListSmtpCredentials.go.html to see an example of how to use ListSmtpCredentialsRequest. +type ListSmtpCredentialsRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListSmtpCredentialsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListSmtpCredentialsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListSmtpCredentialsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListSmtpCredentialsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListSmtpCredentialsResponse wrapper for the ListSmtpCredentials operation +type ListSmtpCredentialsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []SmtpCredentialSummary instance + Items []SmtpCredentialSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListSmtpCredentialsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListSmtpCredentialsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_standard_tag_namespaces_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_standard_tag_namespaces_request_response.go new file mode 100644 index 000000000..ff26926bc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_standard_tag_namespaces_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListStandardTagNamespacesRequest wrapper for the ListStandardTagNamespaces operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListStandardTagNamespaces.go.html to see an example of how to use ListStandardTagNamespacesRequest. +type ListStandardTagNamespacesRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListStandardTagNamespacesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListStandardTagNamespacesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListStandardTagNamespacesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListStandardTagNamespacesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListStandardTagNamespacesResponse wrapper for the ListStandardTagNamespaces operation +type ListStandardTagNamespacesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []StandardTagNamespaceTemplateSummary instances + Items []StandardTagNamespaceTemplateSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListStandardTagNamespacesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListStandardTagNamespacesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_swift_passwords_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_swift_passwords_request_response.go new file mode 100644 index 000000000..607bb9fd6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_swift_passwords_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListSwiftPasswordsRequest wrapper for the ListSwiftPasswords operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListSwiftPasswords.go.html to see an example of how to use ListSwiftPasswordsRequest. +type ListSwiftPasswordsRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListSwiftPasswordsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListSwiftPasswordsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListSwiftPasswordsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListSwiftPasswordsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListSwiftPasswordsResponse wrapper for the ListSwiftPasswords operation +type ListSwiftPasswordsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The []SwiftPassword instance + Items []SwiftPassword `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListSwiftPasswordsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListSwiftPasswordsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tag_defaults_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tag_defaults_request_response.go new file mode 100644 index 000000000..a9d487826 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tag_defaults_request_response.go @@ -0,0 +1,94 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListTagDefaultsRequest wrapper for the ListTagDefaults operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListTagDefaults.go.html to see an example of how to use ListTagDefaultsRequest. +type ListTagDefaultsRequest struct { + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // A filter to only return resources that match the specified OCID exactly. + Id *string `mandatory:"false" contributesTo:"query" name:"id"` + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"false" contributesTo:"query" name:"compartmentId"` + + // The OCID of the tag definition. + TagDefinitionId *string `mandatory:"false" contributesTo:"query" name:"tagDefinitionId"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState TagDefaultSummaryLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListTagDefaultsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListTagDefaultsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListTagDefaultsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListTagDefaultsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListTagDefaultsResponse wrapper for the ListTagDefaults operation +type ListTagDefaultsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []TagDefaultSummary instances + Items []TagDefaultSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of tag default values. When paging through a list, if this header appears in + // the response, then a partial list might have been returned. Include this value as the `page` parameter + // for the subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListTagDefaultsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListTagDefaultsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tag_namespaces_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tag_namespaces_request_response.go new file mode 100644 index 000000000..950dc5071 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tag_namespaces_request_response.go @@ -0,0 +1,92 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListTagNamespacesRequest wrapper for the ListTagNamespaces operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListTagNamespaces.go.html to see an example of how to use ListTagNamespacesRequest. +type ListTagNamespacesRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // An optional boolean parameter indicating whether to retrieve all tag namespaces in subcompartments. If this + // parameter is not specified, only the tag namespaces defined in the specified compartment are retrieved. + IncludeSubcompartments *bool `mandatory:"false" contributesTo:"query" name:"includeSubcompartments"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState TagNamespaceLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListTagNamespacesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListTagNamespacesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListTagNamespacesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListTagNamespacesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListTagNamespacesResponse wrapper for the ListTagNamespaces operation +type ListTagNamespacesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []TagNamespaceSummary instances + Items []TagNamespaceSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of tagNamespaces. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListTagNamespacesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListTagNamespacesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tagging_work_request_errors_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tagging_work_request_errors_request_response.go new file mode 100644 index 000000000..a257bbf3f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tagging_work_request_errors_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListTaggingWorkRequestErrorsRequest wrapper for the ListTaggingWorkRequestErrors operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListTaggingWorkRequestErrors.go.html to see an example of how to use ListTaggingWorkRequestErrorsRequest. +type ListTaggingWorkRequestErrorsRequest struct { + + // The OCID of the work request. + WorkRequestId *string `mandatory:"true" contributesTo:"path" name:"workRequestId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListTaggingWorkRequestErrorsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListTaggingWorkRequestErrorsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListTaggingWorkRequestErrorsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListTaggingWorkRequestErrorsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListTaggingWorkRequestErrorsResponse wrapper for the ListTaggingWorkRequestErrors operation +type ListTaggingWorkRequestErrorsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []TaggingWorkRequestErrorSummary instances + Items []TaggingWorkRequestErrorSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The number of seconds that the client should wait before polling again. + RetryAfter *float32 `presentIn:"header" name:"retry-after"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListTaggingWorkRequestErrorsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListTaggingWorkRequestErrorsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tagging_work_request_logs_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tagging_work_request_logs_request_response.go new file mode 100644 index 000000000..a0db04d8d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tagging_work_request_logs_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListTaggingWorkRequestLogsRequest wrapper for the ListTaggingWorkRequestLogs operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListTaggingWorkRequestLogs.go.html to see an example of how to use ListTaggingWorkRequestLogsRequest. +type ListTaggingWorkRequestLogsRequest struct { + + // The OCID of the work request. + WorkRequestId *string `mandatory:"true" contributesTo:"path" name:"workRequestId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListTaggingWorkRequestLogsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListTaggingWorkRequestLogsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListTaggingWorkRequestLogsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListTaggingWorkRequestLogsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListTaggingWorkRequestLogsResponse wrapper for the ListTaggingWorkRequestLogs operation +type ListTaggingWorkRequestLogsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []TaggingWorkRequestLogSummary instances + Items []TaggingWorkRequestLogSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The number of seconds that the client should wait before polling again. + RetryAfter *float32 `presentIn:"header" name:"retry-after"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListTaggingWorkRequestLogsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListTaggingWorkRequestLogsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tagging_work_requests_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tagging_work_requests_request_response.go new file mode 100644 index 000000000..f8514dcda --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tagging_work_requests_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListTaggingWorkRequestsRequest wrapper for the ListTaggingWorkRequests operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListTaggingWorkRequests.go.html to see an example of how to use ListTaggingWorkRequestsRequest. +type ListTaggingWorkRequestsRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // The identifier of the resource the work request affects. + ResourceIdentifier *string `mandatory:"false" contributesTo:"query" name:"resourceIdentifier"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListTaggingWorkRequestsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListTaggingWorkRequestsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListTaggingWorkRequestsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListTaggingWorkRequestsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListTaggingWorkRequestsResponse wrapper for the ListTaggingWorkRequests operation +type ListTaggingWorkRequestsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []TaggingWorkRequestSummary instances + Items []TaggingWorkRequestSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListTaggingWorkRequestsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListTaggingWorkRequestsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tags_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tags_request_response.go new file mode 100644 index 000000000..ed027f132 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_tags_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListTagsRequest wrapper for the ListTags operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListTags.go.html to see an example of how to use ListTagsRequest. +type ListTagsRequest struct { + + // The OCID of the tag namespace. + TagNamespaceId *string `mandatory:"true" contributesTo:"path" name:"tagNamespaceId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState TagLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListTagsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListTagsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListTagsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListTagsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListTagsResponse wrapper for the ListTags operation +type ListTagsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []TagSummary instances + Items []TagSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of tags. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListTagsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListTagsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_user_group_memberships_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_user_group_memberships_request_response.go new file mode 100644 index 000000000..a766301f0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_user_group_memberships_request_response.go @@ -0,0 +1,91 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListUserGroupMembershipsRequest wrapper for the ListUserGroupMemberships operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListUserGroupMemberships.go.html to see an example of how to use ListUserGroupMembershipsRequest. +type ListUserGroupMembershipsRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID of the user. + UserId *string `mandatory:"false" contributesTo:"query" name:"userId"` + + // The OCID of the group. + GroupId *string `mandatory:"false" contributesTo:"query" name:"groupId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListUserGroupMembershipsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListUserGroupMembershipsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListUserGroupMembershipsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListUserGroupMembershipsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListUserGroupMembershipsResponse wrapper for the ListUserGroupMemberships operation +type ListUserGroupMembershipsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []UserGroupMembership instances + Items []UserGroupMembership `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListUserGroupMembershipsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListUserGroupMembershipsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_users_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_users_request_response.go new file mode 100644 index 000000000..540dbfb41 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_users_request_response.go @@ -0,0 +1,156 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListUsersRequest wrapper for the ListUsers operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListUsers.go.html to see an example of how to use ListUsersRequest. +type ListUsersRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // The id of the identity provider. + IdentityProviderId *string `mandatory:"false" contributesTo:"query" name:"identityProviderId"` + + // The id of a user in the identity provider. + ExternalIdentifier *string `mandatory:"false" contributesTo:"query" name:"externalIdentifier"` + + // A filter to only return resources that match the given name exactly. + Name *string `mandatory:"false" contributesTo:"query" name:"name"` + + // The field to sort by. You can provide one sort order (`sortOrder`). Default order for + // TIMECREATED is descending. Default order for NAME is ascending. The NAME + // sort order is case sensitive. + // **Note:** In general, some "List" operations (for example, `ListInstances`) let you + // optionally filter by Availability Domain if the scope of the resource type is within a + // single Availability Domain. If you call one of these "List" operations without specifying + // an Availability Domain, the resources are grouped by Availability Domain, then sorted. + SortBy ListUsersSortByEnum `mandatory:"false" contributesTo:"query" name:"sortBy" omitEmpty:"true"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). The NAME sort order + // is case sensitive. + SortOrder ListUsersSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // A filter to only return resources that match the given lifecycle state. The state value is case-insensitive. + LifecycleState UserLifecycleStateEnum `mandatory:"false" contributesTo:"query" name:"lifecycleState" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListUsersRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListUsersRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListUsersRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListUsersRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListUsersResponse wrapper for the ListUsers operation +type ListUsersResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []User instances + Items []User `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListUsersResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListUsersResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListUsersSortByEnum Enum with underlying type: string +type ListUsersSortByEnum string + +// Set of constants representing the allowable values for ListUsersSortByEnum +const ( + ListUsersSortByTimecreated ListUsersSortByEnum = "TIMECREATED" + ListUsersSortByName ListUsersSortByEnum = "NAME" +) + +var mappingListUsersSortBy = map[string]ListUsersSortByEnum{ + "TIMECREATED": ListUsersSortByTimecreated, + "NAME": ListUsersSortByName, +} + +// GetListUsersSortByEnumValues Enumerates the set of values for ListUsersSortByEnum +func GetListUsersSortByEnumValues() []ListUsersSortByEnum { + values := make([]ListUsersSortByEnum, 0) + for _, v := range mappingListUsersSortBy { + values = append(values, v) + } + return values +} + +// ListUsersSortOrderEnum Enum with underlying type: string +type ListUsersSortOrderEnum string + +// Set of constants representing the allowable values for ListUsersSortOrderEnum +const ( + ListUsersSortOrderAsc ListUsersSortOrderEnum = "ASC" + ListUsersSortOrderDesc ListUsersSortOrderEnum = "DESC" +) + +var mappingListUsersSortOrder = map[string]ListUsersSortOrderEnum{ + "ASC": ListUsersSortOrderAsc, + "DESC": ListUsersSortOrderDesc, +} + +// GetListUsersSortOrderEnumValues Enumerates the set of values for ListUsersSortOrderEnum +func GetListUsersSortOrderEnumValues() []ListUsersSortOrderEnum { + values := make([]ListUsersSortOrderEnum, 0) + for _, v := range mappingListUsersSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_work_requests_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_work_requests_request_response.go new file mode 100644 index 000000000..e025d8149 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/list_work_requests_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListWorkRequestsRequest wrapper for the ListWorkRequests operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ListWorkRequests.go.html to see an example of how to use ListWorkRequestsRequest. +type ListWorkRequestsRequest struct { + + // The OCID of the compartment (remember that the tenancy is simply the root compartment). + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The value of the `opc-next-page` response header from the previous "List" call. + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The maximum number of items to return in a paginated "List" call. + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // The identifier of the resource the work request affects. + ResourceIdentifier *string `mandatory:"false" contributesTo:"query" name:"resourceIdentifier"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListWorkRequestsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListWorkRequestsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListWorkRequestsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListWorkRequestsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListWorkRequestsResponse wrapper for the ListWorkRequests operation +type ListWorkRequestsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []WorkRequestSummary instances + Items []WorkRequestSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For pagination of a list of items. When paging through a list, if this header appears in the response, + // then a partial list might have been returned. Include this value as the `page` parameter for the + // subsequent GET request to get the next batch of items. + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListWorkRequestsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListWorkRequestsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/mfa_totp_device.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/mfa_totp_device.go new file mode 100644 index 000000000..3475e93ce --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/mfa_totp_device.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// MfaTotpDevice Users can enable multi-factor authentication (MFA) for their own user accounts. After MFA is enabled, the +// user is prompted for a time-based one-time password (TOTP) to authenticate before they can sign in to the +// Console. To enable multi-factor authentication, the user must register a mobile device with a TOTP authenticator app +// installed. The registration process creates the `MfaTotpDevice` object. The registration process requires +// interaction with the Console and cannot be completed programmatically. For more information, see +// Managing Multi-Factor Authentication (https://docs.cloud.oracle.com/Content/Identity/Tasks/usingmfa.htm). +type MfaTotpDevice struct { + + // The OCID of the MFA TOTP device. + Id *string `mandatory:"true" json:"id"` + + // The seed for the MFA TOTP device (Base32 encoded). + Seed *string `mandatory:"true" json:"seed"` + + // The OCID of the user the MFA TOTP device belongs to. + UserId *string `mandatory:"true" json:"userId"` + + // Date and time the `MfaTotpDevice` object was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The MFA TOTP device's current state. After creating the MFA TOTP device, make sure its `lifecycleState` changes from + // CREATING to ACTIVE before using it. + LifecycleState MfaTotpDeviceLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // Flag to indicate if the MFA TOTP device has been activated. + IsActivated *bool `mandatory:"true" json:"isActivated"` + + // Date and time when this MFA TOTP device will expire, in the format defined by RFC3339. + // Null if it never expires. + // Example: `2016-08-25T21:10:29.600Z` + TimeExpires *common.SDKTime `mandatory:"false" json:"timeExpires"` + + // The detailed status of INACTIVE lifecycleState. + // Allowed values are: + // - 1 - SUSPENDED + // - 2 - DISABLED + // - 4 - BLOCKED + // - 8 - LOCKED + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` +} + +func (m MfaTotpDevice) String() string { + return common.PointerString(m) +} + +// MfaTotpDeviceLifecycleStateEnum Enum with underlying type: string +type MfaTotpDeviceLifecycleStateEnum string + +// Set of constants representing the allowable values for MfaTotpDeviceLifecycleStateEnum +const ( + MfaTotpDeviceLifecycleStateCreating MfaTotpDeviceLifecycleStateEnum = "CREATING" + MfaTotpDeviceLifecycleStateActive MfaTotpDeviceLifecycleStateEnum = "ACTIVE" + MfaTotpDeviceLifecycleStateInactive MfaTotpDeviceLifecycleStateEnum = "INACTIVE" + MfaTotpDeviceLifecycleStateDeleting MfaTotpDeviceLifecycleStateEnum = "DELETING" + MfaTotpDeviceLifecycleStateDeleted MfaTotpDeviceLifecycleStateEnum = "DELETED" +) + +var mappingMfaTotpDeviceLifecycleState = map[string]MfaTotpDeviceLifecycleStateEnum{ + "CREATING": MfaTotpDeviceLifecycleStateCreating, + "ACTIVE": MfaTotpDeviceLifecycleStateActive, + "INACTIVE": MfaTotpDeviceLifecycleStateInactive, + "DELETING": MfaTotpDeviceLifecycleStateDeleting, + "DELETED": MfaTotpDeviceLifecycleStateDeleted, +} + +// GetMfaTotpDeviceLifecycleStateEnumValues Enumerates the set of values for MfaTotpDeviceLifecycleStateEnum +func GetMfaTotpDeviceLifecycleStateEnumValues() []MfaTotpDeviceLifecycleStateEnum { + values := make([]MfaTotpDeviceLifecycleStateEnum, 0) + for _, v := range mappingMfaTotpDeviceLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/mfa_totp_device_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/mfa_totp_device_summary.go new file mode 100644 index 000000000..0b3b51fd7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/mfa_totp_device_summary.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// MfaTotpDeviceSummary As the name suggests, a `MfaTotpDeviceSummary` object contains information about a `MfaTotpDevice`. +type MfaTotpDeviceSummary struct { + + // The OCID of the MFA TOTP Device. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the user the MFA TOTP device belongs to. + UserId *string `mandatory:"true" json:"userId"` + + // Date and time the `MfaTotpDevice` object was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The MFA TOTP device's current state. + LifecycleState MfaTotpDeviceSummaryLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // Flag to indicate if the MFA TOTP device has been activated + IsActivated *bool `mandatory:"true" json:"isActivated"` + + // Date and time when this MFA TOTP device will expire, in the format defined by RFC3339. + // Null if it never expires. + // Example: `2016-08-25T21:10:29.600Z` + TimeExpires *common.SDKTime `mandatory:"false" json:"timeExpires"` + + // The detailed status of INACTIVE lifecycleState. + // Allowed values are: + // - 1 - SUSPENDED + // - 2 - DISABLED + // - 4 - BLOCKED + // - 8 - LOCKED + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` +} + +func (m MfaTotpDeviceSummary) String() string { + return common.PointerString(m) +} + +// MfaTotpDeviceSummaryLifecycleStateEnum Enum with underlying type: string +type MfaTotpDeviceSummaryLifecycleStateEnum string + +// Set of constants representing the allowable values for MfaTotpDeviceSummaryLifecycleStateEnum +const ( + MfaTotpDeviceSummaryLifecycleStateCreating MfaTotpDeviceSummaryLifecycleStateEnum = "CREATING" + MfaTotpDeviceSummaryLifecycleStateActive MfaTotpDeviceSummaryLifecycleStateEnum = "ACTIVE" + MfaTotpDeviceSummaryLifecycleStateInactive MfaTotpDeviceSummaryLifecycleStateEnum = "INACTIVE" + MfaTotpDeviceSummaryLifecycleStateDeleting MfaTotpDeviceSummaryLifecycleStateEnum = "DELETING" + MfaTotpDeviceSummaryLifecycleStateDeleted MfaTotpDeviceSummaryLifecycleStateEnum = "DELETED" +) + +var mappingMfaTotpDeviceSummaryLifecycleState = map[string]MfaTotpDeviceSummaryLifecycleStateEnum{ + "CREATING": MfaTotpDeviceSummaryLifecycleStateCreating, + "ACTIVE": MfaTotpDeviceSummaryLifecycleStateActive, + "INACTIVE": MfaTotpDeviceSummaryLifecycleStateInactive, + "DELETING": MfaTotpDeviceSummaryLifecycleStateDeleting, + "DELETED": MfaTotpDeviceSummaryLifecycleStateDeleted, +} + +// GetMfaTotpDeviceSummaryLifecycleStateEnumValues Enumerates the set of values for MfaTotpDeviceSummaryLifecycleStateEnum +func GetMfaTotpDeviceSummaryLifecycleStateEnumValues() []MfaTotpDeviceSummaryLifecycleStateEnum { + values := make([]MfaTotpDeviceSummaryLifecycleStateEnum, 0) + for _, v := range mappingMfaTotpDeviceSummaryLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/mfa_totp_token.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/mfa_totp_token.go new file mode 100644 index 000000000..6a42b9ccb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/mfa_totp_token.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// MfaTotpToken Totp token for MFA +type MfaTotpToken struct { + + // The Totp token for MFA. + TotpToken *string `mandatory:"false" json:"totpToken"` +} + +func (m MfaTotpToken) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/move_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/move_compartment_details.go new file mode 100644 index 000000000..277e6adc3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/move_compartment_details.go @@ -0,0 +1,26 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// MoveCompartmentDetails The representation of MoveCompartmentDetails +type MoveCompartmentDetails struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the destination compartment + // into which to move the compartment. + TargetCompartmentId *string `mandatory:"true" json:"targetCompartmentId"` +} + +func (m MoveCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/move_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/move_compartment_request_response.go new file mode 100644 index 000000000..8c3d955d4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/move_compartment_request_response.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// MoveCompartmentRequest wrapper for the MoveCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/MoveCompartment.go.html to see an example of how to use MoveCompartmentRequest. +type MoveCompartmentRequest struct { + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"path" name:"compartmentId"` + + // Request object for moving a compartment. + MoveCompartmentDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request MoveCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request MoveCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request MoveCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request MoveCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// MoveCompartmentResponse wrapper for the MoveCompartment operation +type MoveCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response MoveCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response MoveCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/network_policy.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/network_policy.go new file mode 100644 index 000000000..12e6f4e41 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/network_policy.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// NetworkPolicy Network policy, Consists of a list of Network Source ids. +type NetworkPolicy struct { + + // Network Source ids + NetworkSourceIds []string `mandatory:"false" json:"networkSourceIds"` +} + +func (m NetworkPolicy) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/network_sources.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/network_sources.go new file mode 100644 index 000000000..5a46dcc75 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/network_sources.go @@ -0,0 +1,99 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// NetworkSources A network source specifies a list of source IP addresses that are allowed to make authorization requests. +// Use the network source in policy statements to restrict access to only requests that come from the specified IPs. +// For more information, see Managing Network Sources (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingnetworksources.htm). +type NetworkSources struct { + + // The OCID of the network source. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the tenancy containing the network source. The tenancy is the root compartment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name you assign to the network source during creation. The name must be unique across + // the tenancy and cannot be changed. + Name *string `mandatory:"true" json:"name"` + + // The description you assign to the network source. Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` + + // Date and time the group was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The network source object's current state. After creating a network source, make sure its `lifecycleState` changes from CREATING to + // ACTIVE before using it. + LifecycleState NetworkSourcesLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // A list of allowed public IPs and CIDR ranges. + PublicSourceList []string `mandatory:"false" json:"publicSourceList"` + + // A list of allowed VCN OCID and IP range pairs. + // Example:`"vcnId": "ocid1.vcn.oc1.iad.aaaaaaaaexampleuniqueID", "ipRanges": [ "129.213.39.0/24" ]` + VirtualSourceList []NetworkSourcesVirtualSourceList `mandatory:"false" json:"virtualSourceList"` + + // A list of services allowed to make on-behalf-of requests. These requests can have different source IPs than + // those specified in the network source. + // Currently, only `all` and `none` are supported. The default is `all`. + Services []string `mandatory:"false" json:"services"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m NetworkSources) String() string { + return common.PointerString(m) +} + +// NetworkSourcesLifecycleStateEnum Enum with underlying type: string +type NetworkSourcesLifecycleStateEnum string + +// Set of constants representing the allowable values for NetworkSourcesLifecycleStateEnum +const ( + NetworkSourcesLifecycleStateCreating NetworkSourcesLifecycleStateEnum = "CREATING" + NetworkSourcesLifecycleStateActive NetworkSourcesLifecycleStateEnum = "ACTIVE" + NetworkSourcesLifecycleStateInactive NetworkSourcesLifecycleStateEnum = "INACTIVE" + NetworkSourcesLifecycleStateDeleting NetworkSourcesLifecycleStateEnum = "DELETING" + NetworkSourcesLifecycleStateDeleted NetworkSourcesLifecycleStateEnum = "DELETED" +) + +var mappingNetworkSourcesLifecycleState = map[string]NetworkSourcesLifecycleStateEnum{ + "CREATING": NetworkSourcesLifecycleStateCreating, + "ACTIVE": NetworkSourcesLifecycleStateActive, + "INACTIVE": NetworkSourcesLifecycleStateInactive, + "DELETING": NetworkSourcesLifecycleStateDeleting, + "DELETED": NetworkSourcesLifecycleStateDeleted, +} + +// GetNetworkSourcesLifecycleStateEnumValues Enumerates the set of values for NetworkSourcesLifecycleStateEnum +func GetNetworkSourcesLifecycleStateEnumValues() []NetworkSourcesLifecycleStateEnum { + values := make([]NetworkSourcesLifecycleStateEnum, 0) + for _, v := range mappingNetworkSourcesLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/network_sources_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/network_sources_summary.go new file mode 100644 index 000000000..e4028f53e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/network_sources_summary.go @@ -0,0 +1,62 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// NetworkSourcesSummary A network source specifies a list of source IP addresses that are allowed to make authorization requests. +// Use the network source in policy statements to restrict access to only requests that come from the specified IPs. +// For more information, see Managing Network Sources (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingnetworksources.htm). +type NetworkSourcesSummary struct { + + // The OCID of the network source. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the tenancy (root compartment) containing the network source. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The name you assign to the network source during creation. The name must be unique across + // the tenancy and cannot be changed. + Name *string `mandatory:"false" json:"name"` + + // The description you assign to the network source. Does not have to be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` + + // A list of allowed public IP addresses and CIDR ranges. + PublicSourceList []string `mandatory:"false" json:"publicSourceList"` + + // A list of allowed VCN OCID and IP range pairs. + // Example:`"vcnId": "ocid1.vcn.oc1.iad.aaaaaaaaexampleuniqueID", "ipRanges": [ "129.213.39.0/24" ]` + VirtualSourceList []NetworkSourcesVirtualSourceList `mandatory:"false" json:"virtualSourceList"` + + // A list of services allowed to make on-behalf-of requests. These requests can have different source IPs than + // those specified in the network source. Currently, only `all` and `none` are supported. The default is `all`. + Services []string `mandatory:"false" json:"services"` + + // Date and time the group was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m NetworkSourcesSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/network_sources_virtual_source_list.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/network_sources_virtual_source_list.go new file mode 100644 index 000000000..fc390e669 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/network_sources_virtual_source_list.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// NetworkSourcesVirtualSourceList The representation of NetworkSourcesVirtualSourceList +type NetworkSourcesVirtualSourceList struct { + VcnId *string `mandatory:"false" json:"vcnId"` + + IpRanges []string `mandatory:"false" json:"ipRanges"` +} + +func (m NetworkSourcesVirtualSourceList) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/o_auth2_client_credential.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/o_auth2_client_credential.go new file mode 100644 index 000000000..91ff8637a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/o_auth2_client_credential.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// OAuth2ClientCredential User can define Oauth clients in IAM, then use it to generate a token to grant access to app resources. +type OAuth2ClientCredential struct { + + // Allowed scopes for the given oauth credential. + Scopes []FullyQualifiedScope `mandatory:"false" json:"scopes"` + + // Returned during create and update with password reset requests. + Password *string `mandatory:"false" json:"password"` + + // The OCID of the user the Oauth credential belongs to. + UserId *string `mandatory:"false" json:"userId"` + + // Date and time when this credential will expire, in the format defined by RFC3339. + // Null if it never expires. + // Example: `2016-08-25T21:10:29.600Z` + ExpiresOn *common.SDKTime `mandatory:"false" json:"expiresOn"` + + // The OCID of the Oauth credential. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the compartment containing the Oauth credential. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The name of the Oauth credential. + Name *string `mandatory:"false" json:"name"` + + // The description of the Oauth credential. + Description *string `mandatory:"false" json:"description"` + + // The credential's current state. After creating a Oauth credential, make sure its `lifecycleState` changes from + // CREATING to ACTIVE before using it. + LifecycleState OAuth2ClientCredentialLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // Date and time the `OAuth2ClientCredential` object was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` +} + +func (m OAuth2ClientCredential) String() string { + return common.PointerString(m) +} + +// OAuth2ClientCredentialLifecycleStateEnum Enum with underlying type: string +type OAuth2ClientCredentialLifecycleStateEnum string + +// Set of constants representing the allowable values for OAuth2ClientCredentialLifecycleStateEnum +const ( + OAuth2ClientCredentialLifecycleStateCreating OAuth2ClientCredentialLifecycleStateEnum = "CREATING" + OAuth2ClientCredentialLifecycleStateActive OAuth2ClientCredentialLifecycleStateEnum = "ACTIVE" + OAuth2ClientCredentialLifecycleStateInactive OAuth2ClientCredentialLifecycleStateEnum = "INACTIVE" + OAuth2ClientCredentialLifecycleStateDeleting OAuth2ClientCredentialLifecycleStateEnum = "DELETING" + OAuth2ClientCredentialLifecycleStateDeleted OAuth2ClientCredentialLifecycleStateEnum = "DELETED" +) + +var mappingOAuth2ClientCredentialLifecycleState = map[string]OAuth2ClientCredentialLifecycleStateEnum{ + "CREATING": OAuth2ClientCredentialLifecycleStateCreating, + "ACTIVE": OAuth2ClientCredentialLifecycleStateActive, + "INACTIVE": OAuth2ClientCredentialLifecycleStateInactive, + "DELETING": OAuth2ClientCredentialLifecycleStateDeleting, + "DELETED": OAuth2ClientCredentialLifecycleStateDeleted, +} + +// GetOAuth2ClientCredentialLifecycleStateEnumValues Enumerates the set of values for OAuth2ClientCredentialLifecycleStateEnum +func GetOAuth2ClientCredentialLifecycleStateEnumValues() []OAuth2ClientCredentialLifecycleStateEnum { + values := make([]OAuth2ClientCredentialLifecycleStateEnum, 0) + for _, v := range mappingOAuth2ClientCredentialLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/o_auth2_client_credential_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/o_auth2_client_credential_summary.go new file mode 100644 index 000000000..7fbc8649a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/o_auth2_client_credential_summary.go @@ -0,0 +1,82 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// OAuth2ClientCredentialSummary User can define Oauth clients in IAM, then use it to generate a token to grant access to app resources. +type OAuth2ClientCredentialSummary struct { + + // Allowed scopes for the given oauth credential. + Scopes []FullyQualifiedScope `mandatory:"false" json:"scopes"` + + // The OCID of the user the Oauth credential belongs to. + UserId *string `mandatory:"false" json:"userId"` + + // Date and time when this credential will expire, in the format defined by RFC3339. + // Null if it never expires. + // Example: `2016-08-25T21:10:29.600Z` + ExpiresOn *common.SDKTime `mandatory:"false" json:"expiresOn"` + + // The OCID of the Oauth credential. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the compartment containing the Oauth credential. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The name of the Oauth credential. + Name *string `mandatory:"false" json:"name"` + + // The description of the Oauth credential. + Description *string `mandatory:"false" json:"description"` + + // The credential's current state. After creating a Oauth credential, make sure its `lifecycleState` changes from + // CREATING to ACTIVE before using it. + LifecycleState OAuth2ClientCredentialSummaryLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // Date and time the `OAuth2ClientCredential` object was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` +} + +func (m OAuth2ClientCredentialSummary) String() string { + return common.PointerString(m) +} + +// OAuth2ClientCredentialSummaryLifecycleStateEnum Enum with underlying type: string +type OAuth2ClientCredentialSummaryLifecycleStateEnum string + +// Set of constants representing the allowable values for OAuth2ClientCredentialSummaryLifecycleStateEnum +const ( + OAuth2ClientCredentialSummaryLifecycleStateCreating OAuth2ClientCredentialSummaryLifecycleStateEnum = "CREATING" + OAuth2ClientCredentialSummaryLifecycleStateActive OAuth2ClientCredentialSummaryLifecycleStateEnum = "ACTIVE" + OAuth2ClientCredentialSummaryLifecycleStateInactive OAuth2ClientCredentialSummaryLifecycleStateEnum = "INACTIVE" + OAuth2ClientCredentialSummaryLifecycleStateDeleting OAuth2ClientCredentialSummaryLifecycleStateEnum = "DELETING" + OAuth2ClientCredentialSummaryLifecycleStateDeleted OAuth2ClientCredentialSummaryLifecycleStateEnum = "DELETED" +) + +var mappingOAuth2ClientCredentialSummaryLifecycleState = map[string]OAuth2ClientCredentialSummaryLifecycleStateEnum{ + "CREATING": OAuth2ClientCredentialSummaryLifecycleStateCreating, + "ACTIVE": OAuth2ClientCredentialSummaryLifecycleStateActive, + "INACTIVE": OAuth2ClientCredentialSummaryLifecycleStateInactive, + "DELETING": OAuth2ClientCredentialSummaryLifecycleStateDeleting, + "DELETED": OAuth2ClientCredentialSummaryLifecycleStateDeleted, +} + +// GetOAuth2ClientCredentialSummaryLifecycleStateEnumValues Enumerates the set of values for OAuth2ClientCredentialSummaryLifecycleStateEnum +func GetOAuth2ClientCredentialSummaryLifecycleStateEnumValues() []OAuth2ClientCredentialSummaryLifecycleStateEnum { + values := make([]OAuth2ClientCredentialSummaryLifecycleStateEnum, 0) + for _, v := range mappingOAuth2ClientCredentialSummaryLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/password_policy.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/password_policy.go new file mode 100644 index 000000000..61aa0222b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/password_policy.go @@ -0,0 +1,40 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PasswordPolicy Password policy, currently set for the given compartment. +type PasswordPolicy struct { + + // Minimum password length required. + MinimumPasswordLength *int `mandatory:"false" json:"minimumPasswordLength"` + + // At least one uppercase character required. + IsUppercaseCharactersRequired *bool `mandatory:"false" json:"isUppercaseCharactersRequired"` + + // At least one lower case character required. + IsLowercaseCharactersRequired *bool `mandatory:"false" json:"isLowercaseCharactersRequired"` + + // At least one numeric character required. + IsNumericCharactersRequired *bool `mandatory:"false" json:"isNumericCharactersRequired"` + + // At least one special character required. + IsSpecialCharactersRequired *bool `mandatory:"false" json:"isSpecialCharactersRequired"` + + // User name is allowed to be part of the password. + IsUsernameContainmentAllowed *bool `mandatory:"false" json:"isUsernameContainmentAllowed"` +} + +func (m PasswordPolicy) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/policy.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/policy.go new file mode 100644 index 000000000..65ff0d044 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/policy.go @@ -0,0 +1,104 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Policy A document that specifies the type of access a group has to the resources in a compartment. For information about +// policies and other IAM Service components, see +// Overview of the IAM Service (https://docs.cloud.oracle.com/Content/Identity/Concepts/overview.htm). If you're new to policies, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +// The word "policy" is used by people in different ways: +// * An individual statement written in the policy language +// * A collection of statements in a single, named "policy" document (which has an Oracle Cloud ID (OCID) assigned to it) +// * The overall body of policies your organization uses to control access to resources +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. +// **Warning:** Oracle recommends that you avoid using any confidential information when you supply string values +// using the API. +type Policy struct { + + // The OCID of the policy. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the compartment containing the policy (either the tenancy or another compartment). + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name you assign to the policy during creation. The name must be unique across all policies + // in the tenancy and cannot be changed. + Name *string `mandatory:"true" json:"name"` + + // An array of one or more policy statements written in the policy language. + Statements []string `mandatory:"true" json:"statements"` + + // The description you assign to the policy. Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` + + // Date and time the policy was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The policy's current state. After creating a policy, make sure its `lifecycleState` changes from CREATING to + // ACTIVE before using it. + LifecycleState PolicyLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` + + // The version of the policy. If null or set to an empty string, when a request comes in for authorization, the + // policy will be evaluated according to the current behavior of the services at that moment. If set to a particular + // date (YYYY-MM-DD), the policy will be evaluated according to the behavior of the services on that date. + VersionDate *common.SDKDate `mandatory:"false" json:"versionDate"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m Policy) String() string { + return common.PointerString(m) +} + +// PolicyLifecycleStateEnum Enum with underlying type: string +type PolicyLifecycleStateEnum string + +// Set of constants representing the allowable values for PolicyLifecycleStateEnum +const ( + PolicyLifecycleStateCreating PolicyLifecycleStateEnum = "CREATING" + PolicyLifecycleStateActive PolicyLifecycleStateEnum = "ACTIVE" + PolicyLifecycleStateInactive PolicyLifecycleStateEnum = "INACTIVE" + PolicyLifecycleStateDeleting PolicyLifecycleStateEnum = "DELETING" + PolicyLifecycleStateDeleted PolicyLifecycleStateEnum = "DELETED" +) + +var mappingPolicyLifecycleState = map[string]PolicyLifecycleStateEnum{ + "CREATING": PolicyLifecycleStateCreating, + "ACTIVE": PolicyLifecycleStateActive, + "INACTIVE": PolicyLifecycleStateInactive, + "DELETING": PolicyLifecycleStateDeleting, + "DELETED": PolicyLifecycleStateDeleted, +} + +// GetPolicyLifecycleStateEnumValues Enumerates the set of values for PolicyLifecycleStateEnum +func GetPolicyLifecycleStateEnumValues() []PolicyLifecycleStateEnum { + values := make([]PolicyLifecycleStateEnum, 0) + for _, v := range mappingPolicyLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/recover_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/recover_compartment_request_response.go new file mode 100644 index 000000000..811dc4cb6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/recover_compartment_request_response.go @@ -0,0 +1,82 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// RecoverCompartmentRequest wrapper for the RecoverCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/RecoverCompartment.go.html to see an example of how to use RecoverCompartmentRequest. +type RecoverCompartmentRequest struct { + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"path" name:"compartmentId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request RecoverCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request RecoverCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request RecoverCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request RecoverCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// RecoverCompartmentResponse wrapper for the RecoverCompartment operation +type RecoverCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Compartment instance + Compartment `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response RecoverCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response RecoverCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/region.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/region.go new file mode 100644 index 000000000..cfbad2faa --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/region.go @@ -0,0 +1,37 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Region A localized geographic area, such as Phoenix, AZ. Oracle Cloud Infrastructure is hosted in regions and Availability +// Domains. A region is composed of several Availability Domains. An Availability Domain is one or more data centers +// located within a region. For more information, see Regions and Availability Domains (https://docs.cloud.oracle.com/Content/General/Concepts/regions.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, +// see Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type Region struct { + + // The key of the region. See Regions and Availability Domains (https://docs.cloud.oracle.com/Content/General/Concepts/regions.htm) for + // the full list of supported 3-letter region codes. + // Example: `PHX` + Key *string `mandatory:"false" json:"key"` + + // The name of the region. See Regions and Availability Domains (https://docs.cloud.oracle.com/Content/General/Concepts/regions.htm) + // for the full list of supported region names. + // Example: `us-phoenix-1` + Name *string `mandatory:"false" json:"name"` +} + +func (m Region) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/region_subscription.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/region_subscription.go new file mode 100644 index 000000000..e1fa22a71 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/region_subscription.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RegionSubscription An object that represents your tenancy's access to a particular region (i.e., a subscription), the status of that +// access, and whether that region is the home region. For more information, see Managing Regions (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingregions.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, +// see Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type RegionSubscription struct { + + // The region's key. See Regions and Availability Domains (https://docs.cloud.oracle.com/Content/General/Concepts/regions.htm) + // for the full list of supported 3-letter region codes. + // Example: `PHX` + RegionKey *string `mandatory:"true" json:"regionKey"` + + // The region's name. See Regions and Availability Domains (https://docs.cloud.oracle.com/Content/General/Concepts/regions.htm) + // for the full list of supported region names. + // Example: `us-phoenix-1` + RegionName *string `mandatory:"true" json:"regionName"` + + // The region subscription status. + Status RegionSubscriptionStatusEnum `mandatory:"true" json:"status"` + + // Indicates if the region is the home region or not. + IsHomeRegion *bool `mandatory:"true" json:"isHomeRegion"` +} + +func (m RegionSubscription) String() string { + return common.PointerString(m) +} + +// RegionSubscriptionStatusEnum Enum with underlying type: string +type RegionSubscriptionStatusEnum string + +// Set of constants representing the allowable values for RegionSubscriptionStatusEnum +const ( + RegionSubscriptionStatusReady RegionSubscriptionStatusEnum = "READY" + RegionSubscriptionStatusInProgress RegionSubscriptionStatusEnum = "IN_PROGRESS" +) + +var mappingRegionSubscriptionStatus = map[string]RegionSubscriptionStatusEnum{ + "READY": RegionSubscriptionStatusReady, + "IN_PROGRESS": RegionSubscriptionStatusInProgress, +} + +// GetRegionSubscriptionStatusEnumValues Enumerates the set of values for RegionSubscriptionStatusEnum +func GetRegionSubscriptionStatusEnumValues() []RegionSubscriptionStatusEnum { + values := make([]RegionSubscriptionStatusEnum, 0) + for _, v := range mappingRegionSubscriptionStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/remove_user_from_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/remove_user_from_group_request_response.go new file mode 100644 index 000000000..afc5c7dcf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/remove_user_from_group_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// RemoveUserFromGroupRequest wrapper for the RemoveUserFromGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/RemoveUserFromGroup.go.html to see an example of how to use RemoveUserFromGroupRequest. +type RemoveUserFromGroupRequest struct { + + // The OCID of the userGroupMembership. + UserGroupMembershipId *string `mandatory:"true" contributesTo:"path" name:"userGroupMembershipId"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request RemoveUserFromGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request RemoveUserFromGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request RemoveUserFromGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request RemoveUserFromGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// RemoveUserFromGroupResponse wrapper for the RemoveUserFromGroup operation +type RemoveUserFromGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response RemoveUserFromGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response RemoveUserFromGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/replicated_region_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/replicated_region_details.go new file mode 100644 index 000000000..0f8f3a061 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/replicated_region_details.go @@ -0,0 +1,62 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ReplicatedRegionDetails Properties for a region where a domain is replicated too. +type ReplicatedRegionDetails struct { + + // A REPLICATION_ENABLED region, e.g. us-ashburn-1. + // See Regions and Availability Domains (https://docs.cloud.oracle.com/Content/General/Concepts/regions.htm) + // for the full list of supported region names. + Region *string `mandatory:"false" json:"region"` + + // Region agnostic domain URL. + Url *string `mandatory:"false" json:"url"` + + // The IDCS replicated region state + State ReplicatedRegionDetailsStateEnum `mandatory:"false" json:"state,omitempty"` +} + +func (m ReplicatedRegionDetails) String() string { + return common.PointerString(m) +} + +// ReplicatedRegionDetailsStateEnum Enum with underlying type: string +type ReplicatedRegionDetailsStateEnum string + +// Set of constants representing the allowable values for ReplicatedRegionDetailsStateEnum +const ( + ReplicatedRegionDetailsStateEnablingReplication ReplicatedRegionDetailsStateEnum = "ENABLING_REPLICATION" + ReplicatedRegionDetailsStateReplicationEnabled ReplicatedRegionDetailsStateEnum = "REPLICATION_ENABLED" + ReplicatedRegionDetailsStateDisablingReplication ReplicatedRegionDetailsStateEnum = "DISABLING_REPLICATION" + ReplicatedRegionDetailsStateReplicationDisabled ReplicatedRegionDetailsStateEnum = "REPLICATION_DISABLED" + ReplicatedRegionDetailsStateDeleted ReplicatedRegionDetailsStateEnum = "DELETED" +) + +var mappingReplicatedRegionDetailsState = map[string]ReplicatedRegionDetailsStateEnum{ + "ENABLING_REPLICATION": ReplicatedRegionDetailsStateEnablingReplication, + "REPLICATION_ENABLED": ReplicatedRegionDetailsStateReplicationEnabled, + "DISABLING_REPLICATION": ReplicatedRegionDetailsStateDisablingReplication, + "REPLICATION_DISABLED": ReplicatedRegionDetailsStateReplicationDisabled, + "DELETED": ReplicatedRegionDetailsStateDeleted, +} + +// GetReplicatedRegionDetailsStateEnumValues Enumerates the set of values for ReplicatedRegionDetailsStateEnum +func GetReplicatedRegionDetailsStateEnumValues() []ReplicatedRegionDetailsStateEnum { + values := make([]ReplicatedRegionDetailsStateEnum, 0) + for _, v := range mappingReplicatedRegionDetailsState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/reset_idp_scim_client_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/reset_idp_scim_client_request_response.go new file mode 100644 index 000000000..db16d0ddb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/reset_idp_scim_client_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ResetIdpScimClientRequest wrapper for the ResetIdpScimClient operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/ResetIdpScimClient.go.html to see an example of how to use ResetIdpScimClientRequest. +type ResetIdpScimClientRequest struct { + + // The OCID of the identity provider. + IdentityProviderId *string `mandatory:"true" contributesTo:"path" name:"identityProviderId"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ResetIdpScimClientRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ResetIdpScimClientRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ResetIdpScimClientRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ResetIdpScimClientRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ResetIdpScimClientResponse wrapper for the ResetIdpScimClient operation +type ResetIdpScimClientResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ScimClientCredentials instance + ScimClientCredentials `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ResetIdpScimClientResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ResetIdpScimClientResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/saml2_identity_provider.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/saml2_identity_provider.go new file mode 100644 index 000000000..6ce63b907 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/saml2_identity_provider.go @@ -0,0 +1,155 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Saml2IdentityProvider A special type of IdentityProvider that +// supports the SAML 2.0 protocol. For more information, see +// Identity Providers and Federation (https://docs.cloud.oracle.com/Content/Identity/Concepts/federation.htm). +type Saml2IdentityProvider struct { + + // The OCID of the `IdentityProvider`. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the tenancy containing the `IdentityProvider`. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name you assign to the `IdentityProvider` during creation. The name + // must be unique across all `IdentityProvider` objects in the tenancy and + // cannot be changed. This is the name federated users see when choosing + // which identity provider to use when signing in to the Oracle Cloud Infrastructure + // Console. + Name *string `mandatory:"true" json:"name"` + + // The description you assign to the `IdentityProvider` during creation. Does + // not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` + + // The identity provider service or product. + // Supported identity providers are Oracle Identity Cloud Service (IDCS) and Microsoft + // Active Directory Federation Services (ADFS). + // Allowed values are: + // - `ADFS` + // - `IDCS` + // Example: `IDCS` + ProductType *string `mandatory:"true" json:"productType"` + + // Date and time the `IdentityProvider` was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The URL for retrieving the identity provider's metadata, which + // contains information required for federating. + MetadataUrl *string `mandatory:"true" json:"metadataUrl"` + + // The identity provider's signing certificate used by the IAM Service + // to validate the SAML2 token. + SigningCertificate *string `mandatory:"true" json:"signingCertificate"` + + // The URL to redirect federated users to for authentication with the + // identity provider. + RedirectUrl *string `mandatory:"true" json:"redirectUrl"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // The XML that contains the information required for federating Identity with SAML2 Identity Provider. + Metadata *string `mandatory:"false" json:"metadata"` + + // Extra name value pairs associated with this identity provider. + // Example: `{"clientId": "app_sf3kdjf3"}` + FreeformAttributes map[string]string `mandatory:"false" json:"freeformAttributes"` + + // The current state. After creating an `IdentityProvider`, make sure its + // `lifecycleState` changes from CREATING to ACTIVE before using it. + LifecycleState IdentityProviderLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` +} + +//GetId returns Id +func (m Saml2IdentityProvider) GetId() *string { + return m.Id +} + +//GetCompartmentId returns CompartmentId +func (m Saml2IdentityProvider) GetCompartmentId() *string { + return m.CompartmentId +} + +//GetName returns Name +func (m Saml2IdentityProvider) GetName() *string { + return m.Name +} + +//GetDescription returns Description +func (m Saml2IdentityProvider) GetDescription() *string { + return m.Description +} + +//GetProductType returns ProductType +func (m Saml2IdentityProvider) GetProductType() *string { + return m.ProductType +} + +//GetTimeCreated returns TimeCreated +func (m Saml2IdentityProvider) GetTimeCreated() *common.SDKTime { + return m.TimeCreated +} + +//GetLifecycleState returns LifecycleState +func (m Saml2IdentityProvider) GetLifecycleState() IdentityProviderLifecycleStateEnum { + return m.LifecycleState +} + +//GetInactiveStatus returns InactiveStatus +func (m Saml2IdentityProvider) GetInactiveStatus() *int64 { + return m.InactiveStatus +} + +//GetFreeformTags returns FreeformTags +func (m Saml2IdentityProvider) GetFreeformTags() map[string]string { + return m.FreeformTags +} + +//GetDefinedTags returns DefinedTags +func (m Saml2IdentityProvider) GetDefinedTags() map[string]map[string]interface{} { + return m.DefinedTags +} + +func (m Saml2IdentityProvider) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m Saml2IdentityProvider) MarshalJSON() (buff []byte, e error) { + type MarshalTypeSaml2IdentityProvider Saml2IdentityProvider + s := struct { + DiscriminatorParam string `json:"protocol"` + MarshalTypeSaml2IdentityProvider + }{ + "SAML2", + (MarshalTypeSaml2IdentityProvider)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/scim_client_credentials.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/scim_client_credentials.go new file mode 100644 index 000000000..574b75960 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/scim_client_credentials.go @@ -0,0 +1,28 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ScimClientCredentials The OAuth2 client credentials. +type ScimClientCredentials struct { + + // The client identifier. + ClientId *string `mandatory:"false" json:"clientId"` + + // The client secret. + ClientSecret *string `mandatory:"false" json:"clientSecret"` +} + +func (m ScimClientCredentials) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/smtp_credential.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/smtp_credential.go new file mode 100644 index 000000000..ec821858b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/smtp_credential.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// SmtpCredential Simple Mail Transfer Protocol (SMTP) credentials are needed to send email through Email Delivery. +// The SMTP credentials are used for SMTP authentication with the service. The credentials never expire. +// A user can have up to 2 SMTP credentials at a time. +// **Note:** The credential set is always an Oracle-generated SMTP user name and password pair; +// you cannot designate the SMTP user name or the SMTP password. +// For more information, see Managing User Credentials (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingcredentials.htm#SMTP). +type SmtpCredential struct { + + // The SMTP user name. + Username *string `mandatory:"false" json:"username"` + + // The SMTP password. + Password *string `mandatory:"false" json:"password"` + + // The OCID of the SMTP credential. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the user the SMTP credential belongs to. + UserId *string `mandatory:"false" json:"userId"` + + // The description you assign to the SMTP credential. Does not have to be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` + + // Date and time the `SmtpCredential` object was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // Date and time when this credential will expire, in the format defined by RFC3339. + // Null if it never expires. + // Example: `2016-08-25T21:10:29.600Z` + TimeExpires *common.SDKTime `mandatory:"false" json:"timeExpires"` + + // The credential's current state. After creating a SMTP credential, make sure its `lifecycleState` changes from + // CREATING to ACTIVE before using it. + LifecycleState SmtpCredentialLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` +} + +func (m SmtpCredential) String() string { + return common.PointerString(m) +} + +// SmtpCredentialLifecycleStateEnum Enum with underlying type: string +type SmtpCredentialLifecycleStateEnum string + +// Set of constants representing the allowable values for SmtpCredentialLifecycleStateEnum +const ( + SmtpCredentialLifecycleStateCreating SmtpCredentialLifecycleStateEnum = "CREATING" + SmtpCredentialLifecycleStateActive SmtpCredentialLifecycleStateEnum = "ACTIVE" + SmtpCredentialLifecycleStateInactive SmtpCredentialLifecycleStateEnum = "INACTIVE" + SmtpCredentialLifecycleStateDeleting SmtpCredentialLifecycleStateEnum = "DELETING" + SmtpCredentialLifecycleStateDeleted SmtpCredentialLifecycleStateEnum = "DELETED" +) + +var mappingSmtpCredentialLifecycleState = map[string]SmtpCredentialLifecycleStateEnum{ + "CREATING": SmtpCredentialLifecycleStateCreating, + "ACTIVE": SmtpCredentialLifecycleStateActive, + "INACTIVE": SmtpCredentialLifecycleStateInactive, + "DELETING": SmtpCredentialLifecycleStateDeleting, + "DELETED": SmtpCredentialLifecycleStateDeleted, +} + +// GetSmtpCredentialLifecycleStateEnumValues Enumerates the set of values for SmtpCredentialLifecycleStateEnum +func GetSmtpCredentialLifecycleStateEnumValues() []SmtpCredentialLifecycleStateEnum { + values := make([]SmtpCredentialLifecycleStateEnum, 0) + for _, v := range mappingSmtpCredentialLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/smtp_credential_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/smtp_credential_summary.go new file mode 100644 index 000000000..178229765 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/smtp_credential_summary.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// SmtpCredentialSummary As the name suggests, an `SmtpCredentialSummary` object contains information about an `SmtpCredential`. +// The SMTP credential is used for SMTP authentication with +// the Email Delivery Service (https://docs.cloud.oracle.com/Content/Email/Concepts/overview.htm). +type SmtpCredentialSummary struct { + + // The SMTP user name. + Username *string `mandatory:"false" json:"username"` + + // The OCID of the SMTP credential. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the user the SMTP credential belongs to. + UserId *string `mandatory:"false" json:"userId"` + + // The description you assign to the SMTP credential. Does not have to be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` + + // Date and time the `SmtpCredential` object was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // Date and time when this credential will expire, in the format defined by RFC3339. + // Null if it never expires. + // Example: `2016-08-25T21:10:29.600Z` + TimeExpires *common.SDKTime `mandatory:"false" json:"timeExpires"` + + // The credential's current state. After creating a SMTP credential, make sure its `lifecycleState` changes from + // CREATING to ACTIVE before using it. + LifecycleState SmtpCredentialSummaryLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` +} + +func (m SmtpCredentialSummary) String() string { + return common.PointerString(m) +} + +// SmtpCredentialSummaryLifecycleStateEnum Enum with underlying type: string +type SmtpCredentialSummaryLifecycleStateEnum string + +// Set of constants representing the allowable values for SmtpCredentialSummaryLifecycleStateEnum +const ( + SmtpCredentialSummaryLifecycleStateCreating SmtpCredentialSummaryLifecycleStateEnum = "CREATING" + SmtpCredentialSummaryLifecycleStateActive SmtpCredentialSummaryLifecycleStateEnum = "ACTIVE" + SmtpCredentialSummaryLifecycleStateInactive SmtpCredentialSummaryLifecycleStateEnum = "INACTIVE" + SmtpCredentialSummaryLifecycleStateDeleting SmtpCredentialSummaryLifecycleStateEnum = "DELETING" + SmtpCredentialSummaryLifecycleStateDeleted SmtpCredentialSummaryLifecycleStateEnum = "DELETED" +) + +var mappingSmtpCredentialSummaryLifecycleState = map[string]SmtpCredentialSummaryLifecycleStateEnum{ + "CREATING": SmtpCredentialSummaryLifecycleStateCreating, + "ACTIVE": SmtpCredentialSummaryLifecycleStateActive, + "INACTIVE": SmtpCredentialSummaryLifecycleStateInactive, + "DELETING": SmtpCredentialSummaryLifecycleStateDeleting, + "DELETED": SmtpCredentialSummaryLifecycleStateDeleted, +} + +// GetSmtpCredentialSummaryLifecycleStateEnumValues Enumerates the set of values for SmtpCredentialSummaryLifecycleStateEnum +func GetSmtpCredentialSummaryLifecycleStateEnumValues() []SmtpCredentialSummaryLifecycleStateEnum { + values := make([]SmtpCredentialSummaryLifecycleStateEnum, 0) + for _, v := range mappingSmtpCredentialSummaryLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/standard_tag_definition_template.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/standard_tag_definition_template.go new file mode 100644 index 000000000..189d95882 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/standard_tag_definition_template.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// StandardTagDefinitionTemplate The template of the tag definition. This object includes necessary details to create the provided standard tag definition. +type StandardTagDefinitionTemplate struct { + + // The default description of the tag namespace that users can use to create the tag definition + Description *string `mandatory:"true" json:"description"` + + // The name of this standard tag definition + TagDefinitionName *string `mandatory:"true" json:"tagDefinitionName"` + + // The type of tag definition. Enum or string. + Type StandardTagDefinitionTemplateTypeEnum `mandatory:"true" json:"type"` + + // Is the tag a cost tracking tag. Default will be false as cost tracking tags have been deprecated + IsCostTracking *bool `mandatory:"true" json:"isCostTracking"` + + // List of possible values. An optional parameter that will be present if the type of definition is enum. + PossibleValues []string `mandatory:"false" json:"possibleValues"` + + // The mutability of the possible values list for enum tags. This will default to IMMUTABLE for string value tags + EnumMutability StandardTagDefinitionTemplateEnumMutabilityEnum `mandatory:"false" json:"enumMutability,omitempty"` +} + +func (m StandardTagDefinitionTemplate) String() string { + return common.PointerString(m) +} + +// StandardTagDefinitionTemplateTypeEnum Enum with underlying type: string +type StandardTagDefinitionTemplateTypeEnum string + +// Set of constants representing the allowable values for StandardTagDefinitionTemplateTypeEnum +const ( + StandardTagDefinitionTemplateTypeEnumvalue StandardTagDefinitionTemplateTypeEnum = "ENUM" + StandardTagDefinitionTemplateTypeString StandardTagDefinitionTemplateTypeEnum = "STRING" +) + +var mappingStandardTagDefinitionTemplateType = map[string]StandardTagDefinitionTemplateTypeEnum{ + "ENUM": StandardTagDefinitionTemplateTypeEnumvalue, + "STRING": StandardTagDefinitionTemplateTypeString, +} + +// GetStandardTagDefinitionTemplateTypeEnumValues Enumerates the set of values for StandardTagDefinitionTemplateTypeEnum +func GetStandardTagDefinitionTemplateTypeEnumValues() []StandardTagDefinitionTemplateTypeEnum { + values := make([]StandardTagDefinitionTemplateTypeEnum, 0) + for _, v := range mappingStandardTagDefinitionTemplateType { + values = append(values, v) + } + return values +} + +// StandardTagDefinitionTemplateEnumMutabilityEnum Enum with underlying type: string +type StandardTagDefinitionTemplateEnumMutabilityEnum string + +// Set of constants representing the allowable values for StandardTagDefinitionTemplateEnumMutabilityEnum +const ( + StandardTagDefinitionTemplateEnumMutabilityImmutable StandardTagDefinitionTemplateEnumMutabilityEnum = "IMMUTABLE" + StandardTagDefinitionTemplateEnumMutabilityMutable StandardTagDefinitionTemplateEnumMutabilityEnum = "MUTABLE" + StandardTagDefinitionTemplateEnumMutabilityAppendable StandardTagDefinitionTemplateEnumMutabilityEnum = "APPENDABLE" +) + +var mappingStandardTagDefinitionTemplateEnumMutability = map[string]StandardTagDefinitionTemplateEnumMutabilityEnum{ + "IMMUTABLE": StandardTagDefinitionTemplateEnumMutabilityImmutable, + "MUTABLE": StandardTagDefinitionTemplateEnumMutabilityMutable, + "APPENDABLE": StandardTagDefinitionTemplateEnumMutabilityAppendable, +} + +// GetStandardTagDefinitionTemplateEnumMutabilityEnumValues Enumerates the set of values for StandardTagDefinitionTemplateEnumMutabilityEnum +func GetStandardTagDefinitionTemplateEnumMutabilityEnumValues() []StandardTagDefinitionTemplateEnumMutabilityEnum { + values := make([]StandardTagDefinitionTemplateEnumMutabilityEnum, 0) + for _, v := range mappingStandardTagDefinitionTemplateEnumMutability { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/standard_tag_namespace_template.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/standard_tag_namespace_template.go new file mode 100644 index 000000000..0945019df --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/standard_tag_namespace_template.go @@ -0,0 +1,34 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// StandardTagNamespaceTemplate The template of the standard tag namespace. This object includes necessary details to create the provided standard tag namespace. +type StandardTagNamespaceTemplate struct { + + // The default description of the tag namespace that users can use to create the tag namespace + Description *string `mandatory:"true" json:"description"` + + // The reserved name of this standard tag namespace + StandardTagNamespaceName *string `mandatory:"true" json:"standardTagNamespaceName"` + + // The template of the tag definition. This object includes necessary details to create the provided standard tag definition. + TagDefinitionTemplates []StandardTagDefinitionTemplate `mandatory:"true" json:"tagDefinitionTemplates"` + + // The status of the standard tag namespace + Status *string `mandatory:"true" json:"status"` +} + +func (m StandardTagNamespaceTemplate) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/standard_tag_namespace_template_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/standard_tag_namespace_template_summary.go new file mode 100644 index 000000000..d4c1c36c4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/standard_tag_namespace_template_summary.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// StandardTagNamespaceTemplateSummary The template of the standard tag namespace. This object includes necessary details to create the provided standard tag namespace. +type StandardTagNamespaceTemplateSummary struct { + + // The default description of the tag namespace that users can use to create the tag namespace + Description *string `mandatory:"true" json:"description"` + + // The reserved name of this standard tag namespace + StandardTagNamespaceName *string `mandatory:"true" json:"standardTagNamespaceName"` + + // The status of the standard tag namespace + Status *string `mandatory:"true" json:"status"` +} + +func (m StandardTagNamespaceTemplateSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/swift_password.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/swift_password.go new file mode 100644 index 000000000..aa74130f8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/swift_password.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// SwiftPassword **Deprecated. Use AuthToken instead.** +// Swift is the OpenStack object storage service. A `SwiftPassword` is an Oracle-provided password for using a +// Swift client with the Object Storage Service. This password is associated with +// the user's Console login. Swift passwords never expire. A user can have up to two Swift passwords at a time. +// **Note:** The password is always an Oracle-generated string; you can't change it to a string of your choice. +// For more information, see Managing User Credentials (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingcredentials.htm). +type SwiftPassword struct { + + // The Swift password. The value is available only in the response for `CreateSwiftPassword`, and not + // for `ListSwiftPasswords` or `UpdateSwiftPassword`. + Password *string `mandatory:"false" json:"password"` + + // The OCID of the Swift password. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the user the password belongs to. + UserId *string `mandatory:"false" json:"userId"` + + // The description you assign to the Swift password. Does not have to be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` + + // Date and time the `SwiftPassword` object was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // Date and time when this password will expire, in the format defined by RFC3339. + // Null if it never expires. + // Example: `2016-08-25T21:10:29.600Z` + ExpiresOn *common.SDKTime `mandatory:"false" json:"expiresOn"` + + // The password's current state. After creating a password, make sure its `lifecycleState` changes from + // CREATING to ACTIVE before using it. + LifecycleState SwiftPasswordLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` +} + +func (m SwiftPassword) String() string { + return common.PointerString(m) +} + +// SwiftPasswordLifecycleStateEnum Enum with underlying type: string +type SwiftPasswordLifecycleStateEnum string + +// Set of constants representing the allowable values for SwiftPasswordLifecycleStateEnum +const ( + SwiftPasswordLifecycleStateCreating SwiftPasswordLifecycleStateEnum = "CREATING" + SwiftPasswordLifecycleStateActive SwiftPasswordLifecycleStateEnum = "ACTIVE" + SwiftPasswordLifecycleStateInactive SwiftPasswordLifecycleStateEnum = "INACTIVE" + SwiftPasswordLifecycleStateDeleting SwiftPasswordLifecycleStateEnum = "DELETING" + SwiftPasswordLifecycleStateDeleted SwiftPasswordLifecycleStateEnum = "DELETED" +) + +var mappingSwiftPasswordLifecycleState = map[string]SwiftPasswordLifecycleStateEnum{ + "CREATING": SwiftPasswordLifecycleStateCreating, + "ACTIVE": SwiftPasswordLifecycleStateActive, + "INACTIVE": SwiftPasswordLifecycleStateInactive, + "DELETING": SwiftPasswordLifecycleStateDeleting, + "DELETED": SwiftPasswordLifecycleStateDeleted, +} + +// GetSwiftPasswordLifecycleStateEnumValues Enumerates the set of values for SwiftPasswordLifecycleStateEnum +func GetSwiftPasswordLifecycleStateEnumValues() []SwiftPasswordLifecycleStateEnum { + values := make([]SwiftPasswordLifecycleStateEnum, 0) + for _, v := range mappingSwiftPasswordLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag.go new file mode 100644 index 000000000..34e6878b8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag.go @@ -0,0 +1,159 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Tag A tag definition that belongs to a specific tag namespace. "Defined tags" must be set up in your tenancy before +// you can apply them to resources. +// For more information, see Managing Tags and Tag Namespaces (https://docs.cloud.oracle.com/Content/Identity/Concepts/taggingoverview.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you supply string values +// using the API. +type Tag struct { + + // The OCID of the compartment that contains the tag definition. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the namespace that contains the tag definition. + TagNamespaceId *string `mandatory:"true" json:"tagNamespaceId"` + + // The name of the tag namespace that contains the tag definition. + TagNamespaceName *string `mandatory:"true" json:"tagNamespaceName"` + + // The OCID of the tag definition. + Id *string `mandatory:"true" json:"id"` + + // The name assigned to the tag during creation. This is the tag key definition. + // The name must be unique within the tag namespace and cannot be changed. + Name *string `mandatory:"true" json:"name"` + + // The description you assign to the tag. + Description *string `mandatory:"true" json:"description"` + + // Indicates whether the tag is retired. + // See Retiring Key Definitions and Namespace Definitions (https://docs.cloud.oracle.com/Content/Identity/Concepts/taggingoverview.htm#Retiring). + IsRetired *bool `mandatory:"true" json:"isRetired"` + + // Date and time the tag was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // The tag's current state. After creating a tag, make sure its `lifecycleState` is ACTIVE before using it. After retiring a tag, make sure its `lifecycleState` is INACTIVE before using it. If you delete a tag, you cannot delete another tag until the deleted tag's `lifecycleState` changes from DELETING to DELETED. + LifecycleState TagLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // Indicates whether the tag is enabled for cost tracking. + IsCostTracking *bool `mandatory:"false" json:"isCostTracking"` + + Validator BaseTagDefinitionValidator `mandatory:"false" json:"validator"` +} + +func (m Tag) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *Tag) UnmarshalJSON(data []byte) (e error) { + model := struct { + FreeformTags map[string]string `json:"freeformTags"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + LifecycleState TagLifecycleStateEnum `json:"lifecycleState"` + IsCostTracking *bool `json:"isCostTracking"` + Validator basetagdefinitionvalidator `json:"validator"` + CompartmentId *string `json:"compartmentId"` + TagNamespaceId *string `json:"tagNamespaceId"` + TagNamespaceName *string `json:"tagNamespaceName"` + Id *string `json:"id"` + Name *string `json:"name"` + Description *string `json:"description"` + IsRetired *bool `json:"isRetired"` + TimeCreated *common.SDKTime `json:"timeCreated"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.FreeformTags = model.FreeformTags + + m.DefinedTags = model.DefinedTags + + m.LifecycleState = model.LifecycleState + + m.IsCostTracking = model.IsCostTracking + + nn, e = model.Validator.UnmarshalPolymorphicJSON(model.Validator.JsonData) + if e != nil { + return + } + if nn != nil { + m.Validator = nn.(BaseTagDefinitionValidator) + } else { + m.Validator = nil + } + + m.CompartmentId = model.CompartmentId + + m.TagNamespaceId = model.TagNamespaceId + + m.TagNamespaceName = model.TagNamespaceName + + m.Id = model.Id + + m.Name = model.Name + + m.Description = model.Description + + m.IsRetired = model.IsRetired + + m.TimeCreated = model.TimeCreated + + return +} + +// TagLifecycleStateEnum Enum with underlying type: string +type TagLifecycleStateEnum string + +// Set of constants representing the allowable values for TagLifecycleStateEnum +const ( + TagLifecycleStateActive TagLifecycleStateEnum = "ACTIVE" + TagLifecycleStateInactive TagLifecycleStateEnum = "INACTIVE" + TagLifecycleStateDeleting TagLifecycleStateEnum = "DELETING" + TagLifecycleStateDeleted TagLifecycleStateEnum = "DELETED" +) + +var mappingTagLifecycleState = map[string]TagLifecycleStateEnum{ + "ACTIVE": TagLifecycleStateActive, + "INACTIVE": TagLifecycleStateInactive, + "DELETING": TagLifecycleStateDeleting, + "DELETED": TagLifecycleStateDeleted, +} + +// GetTagLifecycleStateEnumValues Enumerates the set of values for TagLifecycleStateEnum +func GetTagLifecycleStateEnumValues() []TagLifecycleStateEnum { + values := make([]TagLifecycleStateEnum, 0) + for _, v := range mappingTagLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_default.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_default.go new file mode 100644 index 000000000..6ff17580e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_default.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TagDefault Tag defaults let you specify a default tag (tagnamespace.tag="value") to apply to all resource types +// in a specified compartment. The tag default is applied at the time the resource is created. Resources +// that exist in the compartment before you create the tag default are not tagged. The `TagDefault` object +// specifies the tag and compartment details. +// Tag defaults are inherited by child compartments. This means that if you set a tag default on the root compartment +// for a tenancy, all resources that are created in the tenancy are tagged. For more information about +// using tag defaults, see Managing Tag Defaults (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingtagdefaults.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. +type TagDefault struct { + + // The OCID of the tag default. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the compartment. The tag default applies to all new resources that get created in the + // compartment. Resources that existed before the tag default was created are not tagged. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the tag namespace that contains the tag definition. + TagNamespaceId *string `mandatory:"true" json:"tagNamespaceId"` + + // The OCID of the tag definition. The tag default will always assign a default value for this tag definition. + TagDefinitionId *string `mandatory:"true" json:"tagDefinitionId"` + + // The name used in the tag definition. This field is informational in the context of the tag default. + TagDefinitionName *string `mandatory:"true" json:"tagDefinitionName"` + + // The default value for the tag definition. This will be applied to all resources created in the compartment. + Value *string `mandatory:"true" json:"value"` + + // Date and time the `TagDefault` object was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // If you specify that a value is required, a value is set during resource creation (either by the + // user creating the resource or another tag defualt). If no value is set, resource creation is + // blocked. + // * If the `isRequired` flag is set to "true", the value is set during resource creation. + // * If the `isRequired` flag is set to "false", the value you enter is set during resource creation. + // Example: `false` + IsRequired *bool `mandatory:"true" json:"isRequired"` + + // The tag default's current state. After creating a `TagDefault`, make sure its `lifecycleState` is ACTIVE before using it. + LifecycleState TagDefaultLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` +} + +func (m TagDefault) String() string { + return common.PointerString(m) +} + +// TagDefaultLifecycleStateEnum Enum with underlying type: string +type TagDefaultLifecycleStateEnum string + +// Set of constants representing the allowable values for TagDefaultLifecycleStateEnum +const ( + TagDefaultLifecycleStateActive TagDefaultLifecycleStateEnum = "ACTIVE" +) + +var mappingTagDefaultLifecycleState = map[string]TagDefaultLifecycleStateEnum{ + "ACTIVE": TagDefaultLifecycleStateActive, +} + +// GetTagDefaultLifecycleStateEnumValues Enumerates the set of values for TagDefaultLifecycleStateEnum +func GetTagDefaultLifecycleStateEnumValues() []TagDefaultLifecycleStateEnum { + values := make([]TagDefaultLifecycleStateEnum, 0) + for _, v := range mappingTagDefaultLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_default_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_default_summary.go new file mode 100644 index 000000000..9ea4909c2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_default_summary.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TagDefaultSummary Summary information for the specified tag default. +type TagDefaultSummary struct { + + // The OCID of the tag default. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the compartment. The tag default will apply to all new resources that are created in the compartment. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the tag namespace that contains the tag definition. + TagNamespaceId *string `mandatory:"true" json:"tagNamespaceId"` + + // The OCID of the tag definition. The tag default will always assign a default value for this tag definition. + TagDefinitionId *string `mandatory:"true" json:"tagDefinitionId"` + + // The name used in the tag definition. This field is informational in the context of the tag default. + TagDefinitionName *string `mandatory:"true" json:"tagDefinitionName"` + + // The default value for the tag definition. This will be applied to all new resources created in the compartment. + Value *string `mandatory:"true" json:"value"` + + // Date and time the `TagDefault` object was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // If you specify that a value is required, a value is set during resource creation (either by + // the user creating the resource or another tag defualt). If no value is set, resource + // creation is blocked. + // * If the `isRequired` flag is set to "true", the value is set during resource creation. + // * If the `isRequired` flag is set to "false", the value you enter is set during resource creation. + // Example: `false` + IsRequired *bool `mandatory:"true" json:"isRequired"` + + // The tag default's current state. After creating a `TagDefault`, make sure its `lifecycleState` is ACTIVE before using it. + LifecycleState TagDefaultSummaryLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` +} + +func (m TagDefaultSummary) String() string { + return common.PointerString(m) +} + +// TagDefaultSummaryLifecycleStateEnum Enum with underlying type: string +type TagDefaultSummaryLifecycleStateEnum string + +// Set of constants representing the allowable values for TagDefaultSummaryLifecycleStateEnum +const ( + TagDefaultSummaryLifecycleStateActive TagDefaultSummaryLifecycleStateEnum = "ACTIVE" +) + +var mappingTagDefaultSummaryLifecycleState = map[string]TagDefaultSummaryLifecycleStateEnum{ + "ACTIVE": TagDefaultSummaryLifecycleStateActive, +} + +// GetTagDefaultSummaryLifecycleStateEnumValues Enumerates the set of values for TagDefaultSummaryLifecycleStateEnum +func GetTagDefaultSummaryLifecycleStateEnumValues() []TagDefaultSummaryLifecycleStateEnum { + values := make([]TagDefaultSummaryLifecycleStateEnum, 0) + for _, v := range mappingTagDefaultSummaryLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_namespace.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_namespace.go new file mode 100644 index 000000000..bf3205fbf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_namespace.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TagNamespace A managed container for defined tags. A tag namespace is unique in a tenancy. For more information, +// see Managing Tags and Tag Namespaces (https://docs.cloud.oracle.com/Content/Identity/Concepts/taggingoverview.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you supply string values +// using the API. +type TagNamespace struct { + + // The OCID of the tag namespace. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the compartment that contains the tag namespace. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name of the tag namespace. It must be unique across all tag namespaces in the tenancy and cannot be changed. + Name *string `mandatory:"true" json:"name"` + + // The description you assign to the tag namespace. + Description *string `mandatory:"true" json:"description"` + + // Whether the tag namespace is retired. + // See Retiring Key Definitions and Namespace Definitions (https://docs.cloud.oracle.com/Content/Identity/Concepts/taggingoverview.htm#Retiring). + IsRetired *bool `mandatory:"true" json:"isRetired"` + + // Date and time the tagNamespace was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // The tagnamespace's current state. After creating a tagnamespace, make sure its `lifecycleState` is ACTIVE before using it. After retiring a tagnamespace, make sure its `lifecycleState` is INACTIVE before using it. + LifecycleState TagNamespaceLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` +} + +func (m TagNamespace) String() string { + return common.PointerString(m) +} + +// TagNamespaceLifecycleStateEnum Enum with underlying type: string +type TagNamespaceLifecycleStateEnum string + +// Set of constants representing the allowable values for TagNamespaceLifecycleStateEnum +const ( + TagNamespaceLifecycleStateActive TagNamespaceLifecycleStateEnum = "ACTIVE" + TagNamespaceLifecycleStateInactive TagNamespaceLifecycleStateEnum = "INACTIVE" + TagNamespaceLifecycleStateDeleting TagNamespaceLifecycleStateEnum = "DELETING" + TagNamespaceLifecycleStateDeleted TagNamespaceLifecycleStateEnum = "DELETED" +) + +var mappingTagNamespaceLifecycleState = map[string]TagNamespaceLifecycleStateEnum{ + "ACTIVE": TagNamespaceLifecycleStateActive, + "INACTIVE": TagNamespaceLifecycleStateInactive, + "DELETING": TagNamespaceLifecycleStateDeleting, + "DELETED": TagNamespaceLifecycleStateDeleted, +} + +// GetTagNamespaceLifecycleStateEnumValues Enumerates the set of values for TagNamespaceLifecycleStateEnum +func GetTagNamespaceLifecycleStateEnumValues() []TagNamespaceLifecycleStateEnum { + values := make([]TagNamespaceLifecycleStateEnum, 0) + for _, v := range mappingTagNamespaceLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_namespace_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_namespace_summary.go new file mode 100644 index 000000000..5dfed5088 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_namespace_summary.go @@ -0,0 +1,55 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TagNamespaceSummary A container for defined tags. +type TagNamespaceSummary struct { + + // The OCID of the tag namespace. + Id *string `mandatory:"false" json:"id"` + + // The OCID of the compartment that contains the tag namespace. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The name of the tag namespace. It must be unique across all tag namespaces in the tenancy and cannot be changed. + Name *string `mandatory:"false" json:"name"` + + // The description you assign to the tag namespace. + Description *string `mandatory:"false" json:"description"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Whether the tag namespace is retired. + // For more information, see Retiring Key Definitions and Namespace Definitions (https://docs.cloud.oracle.com/Content/Identity/Concepts/taggingoverview.htm#Retiring). + IsRetired *bool `mandatory:"false" json:"isRetired"` + + // The tagnamespace's current state. After creating a tagnamespace, make sure its `lifecycleState` is ACTIVE before using it. After retiring a tagnamespace, make sure its `lifecycleState` is INACTIVE before using it. + LifecycleState TagNamespaceLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // Date and time the tag namespace was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` +} + +func (m TagNamespaceSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_summary.go new file mode 100644 index 000000000..c1c392feb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tag_summary.go @@ -0,0 +1,59 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TagSummary A tag definition that belongs to a specific tag namespace. +type TagSummary struct { + + // The OCID of the compartment that contains the tag definition. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The OCID of the tag definition. + Id *string `mandatory:"false" json:"id"` + + // The name assigned to the tag during creation. This is the tag key definition. + // The name must be unique within the tag namespace and cannot be changed. + Name *string `mandatory:"false" json:"name"` + + // The description you assign to the tag. + Description *string `mandatory:"false" json:"description"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Whether the tag is retired. + // See Retiring Key Definitions and Namespace Definitions (https://docs.cloud.oracle.com/Content/Identity/Concepts/taggingoverview.htm#Retiring). + IsRetired *bool `mandatory:"false" json:"isRetired"` + + // The tag's current state. After creating a tag, make sure its `lifecycleState` is ACTIVE before using it. After retiring a tag, make sure its `lifecycleState` is INACTIVE before using it. If you delete a tag, you cannot delete another tag until the deleted tag's `lifecycleState` changes from DELETING to DELETED. + LifecycleState TagLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // Date and time the tag was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // Indicates whether the tag is enabled for cost tracking. + IsCostTracking *bool `mandatory:"false" json:"isCostTracking"` +} + +func (m TagSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request.go new file mode 100644 index 000000000..1613286b6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request.go @@ -0,0 +1,115 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TaggingWorkRequest The asynchronous API request does not take effect immediately. This request spawns an asynchronous +// workflow to fulfill the request. WorkRequest objects provide visibility for in-progress workflows. +type TaggingWorkRequest struct { + + // The OCID of the work request. + Id *string `mandatory:"true" json:"id"` + + // An enum-like description of the type of work the work request is doing. + OperationType TaggingWorkRequestOperationTypeEnum `mandatory:"true" json:"operationType"` + + // The current status of the work request. + Status TaggingWorkRequestStatusEnum `mandatory:"true" json:"status"` + + // The OCID of the compartment that contains the work request. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The resources this work request affects. + Resources []WorkRequestResource `mandatory:"false" json:"resources"` + + // Date and time the work was accepted, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeAccepted *common.SDKTime `mandatory:"false" json:"timeAccepted"` + + // Date and time the work started, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeStarted *common.SDKTime `mandatory:"false" json:"timeStarted"` + + // Date and time the work completed, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeFinished *common.SDKTime `mandatory:"false" json:"timeFinished"` + + // How much progress the operation has made. + PercentComplete *float32 `mandatory:"false" json:"percentComplete"` +} + +func (m TaggingWorkRequest) String() string { + return common.PointerString(m) +} + +// TaggingWorkRequestOperationTypeEnum Enum with underlying type: string +type TaggingWorkRequestOperationTypeEnum string + +// Set of constants representing the allowable values for TaggingWorkRequestOperationTypeEnum +const ( + TaggingWorkRequestOperationTypeDeleteTagDefinition TaggingWorkRequestOperationTypeEnum = "DELETE_TAG_DEFINITION" + TaggingWorkRequestOperationTypeDeleteNonEmptyTagNamespace TaggingWorkRequestOperationTypeEnum = "DELETE_NON_EMPTY_TAG_NAMESPACE" + TaggingWorkRequestOperationTypeBulkDeleteTagDefinition TaggingWorkRequestOperationTypeEnum = "BULK_DELETE_TAG_DEFINITION" + TaggingWorkRequestOperationTypeBulkEditOfTags TaggingWorkRequestOperationTypeEnum = "BULK_EDIT_OF_TAGS" + TaggingWorkRequestOperationTypeImportStandardTags TaggingWorkRequestOperationTypeEnum = "IMPORT_STANDARD_TAGS" +) + +var mappingTaggingWorkRequestOperationType = map[string]TaggingWorkRequestOperationTypeEnum{ + "DELETE_TAG_DEFINITION": TaggingWorkRequestOperationTypeDeleteTagDefinition, + "DELETE_NON_EMPTY_TAG_NAMESPACE": TaggingWorkRequestOperationTypeDeleteNonEmptyTagNamespace, + "BULK_DELETE_TAG_DEFINITION": TaggingWorkRequestOperationTypeBulkDeleteTagDefinition, + "BULK_EDIT_OF_TAGS": TaggingWorkRequestOperationTypeBulkEditOfTags, + "IMPORT_STANDARD_TAGS": TaggingWorkRequestOperationTypeImportStandardTags, +} + +// GetTaggingWorkRequestOperationTypeEnumValues Enumerates the set of values for TaggingWorkRequestOperationTypeEnum +func GetTaggingWorkRequestOperationTypeEnumValues() []TaggingWorkRequestOperationTypeEnum { + values := make([]TaggingWorkRequestOperationTypeEnum, 0) + for _, v := range mappingTaggingWorkRequestOperationType { + values = append(values, v) + } + return values +} + +// TaggingWorkRequestStatusEnum Enum with underlying type: string +type TaggingWorkRequestStatusEnum string + +// Set of constants representing the allowable values for TaggingWorkRequestStatusEnum +const ( + TaggingWorkRequestStatusAccepted TaggingWorkRequestStatusEnum = "ACCEPTED" + TaggingWorkRequestStatusInProgress TaggingWorkRequestStatusEnum = "IN_PROGRESS" + TaggingWorkRequestStatusFailed TaggingWorkRequestStatusEnum = "FAILED" + TaggingWorkRequestStatusSucceeded TaggingWorkRequestStatusEnum = "SUCCEEDED" + TaggingWorkRequestStatusPartiallySucceeded TaggingWorkRequestStatusEnum = "PARTIALLY_SUCCEEDED" + TaggingWorkRequestStatusCanceling TaggingWorkRequestStatusEnum = "CANCELING" + TaggingWorkRequestStatusCanceled TaggingWorkRequestStatusEnum = "CANCELED" +) + +var mappingTaggingWorkRequestStatus = map[string]TaggingWorkRequestStatusEnum{ + "ACCEPTED": TaggingWorkRequestStatusAccepted, + "IN_PROGRESS": TaggingWorkRequestStatusInProgress, + "FAILED": TaggingWorkRequestStatusFailed, + "SUCCEEDED": TaggingWorkRequestStatusSucceeded, + "PARTIALLY_SUCCEEDED": TaggingWorkRequestStatusPartiallySucceeded, + "CANCELING": TaggingWorkRequestStatusCanceling, + "CANCELED": TaggingWorkRequestStatusCanceled, +} + +// GetTaggingWorkRequestStatusEnumValues Enumerates the set of values for TaggingWorkRequestStatusEnum +func GetTaggingWorkRequestStatusEnumValues() []TaggingWorkRequestStatusEnum { + values := make([]TaggingWorkRequestStatusEnum, 0) + for _, v := range mappingTaggingWorkRequestStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request_error_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request_error_summary.go new file mode 100644 index 000000000..9dfb4495f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request_error_summary.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TaggingWorkRequestErrorSummary The error entity. +type TaggingWorkRequestErrorSummary struct { + + // A machine-usable code for the error that occured. + Code *string `mandatory:"true" json:"code"` + + // A human-readable error string. + Message *string `mandatory:"true" json:"message"` + + // Date and time the error happened, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + Timestamp *common.SDKTime `mandatory:"false" json:"timestamp"` +} + +func (m TaggingWorkRequestErrorSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request_log_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request_log_summary.go new file mode 100644 index 000000000..921d175f1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request_log_summary.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TaggingWorkRequestLogSummary The log entity. +type TaggingWorkRequestLogSummary struct { + + // A human-readable error string. + Message *string `mandatory:"true" json:"message"` + + // Date and time the log was written, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + Timestamp *common.SDKTime `mandatory:"false" json:"timestamp"` +} + +func (m TaggingWorkRequestLogSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request_summary.go new file mode 100644 index 000000000..4c26be80d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tagging_work_request_summary.go @@ -0,0 +1,114 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// TaggingWorkRequestSummary The work request summary. Tracks the status of the asynchronous operation. +type TaggingWorkRequestSummary struct { + + // The OCID of the work request. + Id *string `mandatory:"true" json:"id"` + + // An enum-like description of the type of work the work request is doing. + OperationType TaggingWorkRequestSummaryOperationTypeEnum `mandatory:"true" json:"operationType"` + + // The current status of the work request. + Status TaggingWorkRequestSummaryStatusEnum `mandatory:"true" json:"status"` + + // The OCID of the compartment that contains the work request. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The resources this work request affects. + Resources []WorkRequestResource `mandatory:"false" json:"resources"` + + // Date and time the work was accepted, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeAccepted *common.SDKTime `mandatory:"false" json:"timeAccepted"` + + // Date and time the work started, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeStarted *common.SDKTime `mandatory:"false" json:"timeStarted"` + + // Date and time the work completed, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeFinished *common.SDKTime `mandatory:"false" json:"timeFinished"` + + // How much progress the operation has made. + PercentComplete *float32 `mandatory:"false" json:"percentComplete"` +} + +func (m TaggingWorkRequestSummary) String() string { + return common.PointerString(m) +} + +// TaggingWorkRequestSummaryOperationTypeEnum Enum with underlying type: string +type TaggingWorkRequestSummaryOperationTypeEnum string + +// Set of constants representing the allowable values for TaggingWorkRequestSummaryOperationTypeEnum +const ( + TaggingWorkRequestSummaryOperationTypeDeleteTagDefinition TaggingWorkRequestSummaryOperationTypeEnum = "DELETE_TAG_DEFINITION" + TaggingWorkRequestSummaryOperationTypeDeleteNonEmptyTagNamespace TaggingWorkRequestSummaryOperationTypeEnum = "DELETE_NON_EMPTY_TAG_NAMESPACE" + TaggingWorkRequestSummaryOperationTypeBulkDeleteTagDefinition TaggingWorkRequestSummaryOperationTypeEnum = "BULK_DELETE_TAG_DEFINITION" + TaggingWorkRequestSummaryOperationTypeBulkEditOfTags TaggingWorkRequestSummaryOperationTypeEnum = "BULK_EDIT_OF_TAGS" + TaggingWorkRequestSummaryOperationTypeImportStandardTags TaggingWorkRequestSummaryOperationTypeEnum = "IMPORT_STANDARD_TAGS" +) + +var mappingTaggingWorkRequestSummaryOperationType = map[string]TaggingWorkRequestSummaryOperationTypeEnum{ + "DELETE_TAG_DEFINITION": TaggingWorkRequestSummaryOperationTypeDeleteTagDefinition, + "DELETE_NON_EMPTY_TAG_NAMESPACE": TaggingWorkRequestSummaryOperationTypeDeleteNonEmptyTagNamespace, + "BULK_DELETE_TAG_DEFINITION": TaggingWorkRequestSummaryOperationTypeBulkDeleteTagDefinition, + "BULK_EDIT_OF_TAGS": TaggingWorkRequestSummaryOperationTypeBulkEditOfTags, + "IMPORT_STANDARD_TAGS": TaggingWorkRequestSummaryOperationTypeImportStandardTags, +} + +// GetTaggingWorkRequestSummaryOperationTypeEnumValues Enumerates the set of values for TaggingWorkRequestSummaryOperationTypeEnum +func GetTaggingWorkRequestSummaryOperationTypeEnumValues() []TaggingWorkRequestSummaryOperationTypeEnum { + values := make([]TaggingWorkRequestSummaryOperationTypeEnum, 0) + for _, v := range mappingTaggingWorkRequestSummaryOperationType { + values = append(values, v) + } + return values +} + +// TaggingWorkRequestSummaryStatusEnum Enum with underlying type: string +type TaggingWorkRequestSummaryStatusEnum string + +// Set of constants representing the allowable values for TaggingWorkRequestSummaryStatusEnum +const ( + TaggingWorkRequestSummaryStatusAccepted TaggingWorkRequestSummaryStatusEnum = "ACCEPTED" + TaggingWorkRequestSummaryStatusInProgress TaggingWorkRequestSummaryStatusEnum = "IN_PROGRESS" + TaggingWorkRequestSummaryStatusFailed TaggingWorkRequestSummaryStatusEnum = "FAILED" + TaggingWorkRequestSummaryStatusSucceeded TaggingWorkRequestSummaryStatusEnum = "SUCCEEDED" + TaggingWorkRequestSummaryStatusPartiallySucceeded TaggingWorkRequestSummaryStatusEnum = "PARTIALLY_SUCCEEDED" + TaggingWorkRequestSummaryStatusCanceling TaggingWorkRequestSummaryStatusEnum = "CANCELING" + TaggingWorkRequestSummaryStatusCanceled TaggingWorkRequestSummaryStatusEnum = "CANCELED" +) + +var mappingTaggingWorkRequestSummaryStatus = map[string]TaggingWorkRequestSummaryStatusEnum{ + "ACCEPTED": TaggingWorkRequestSummaryStatusAccepted, + "IN_PROGRESS": TaggingWorkRequestSummaryStatusInProgress, + "FAILED": TaggingWorkRequestSummaryStatusFailed, + "SUCCEEDED": TaggingWorkRequestSummaryStatusSucceeded, + "PARTIALLY_SUCCEEDED": TaggingWorkRequestSummaryStatusPartiallySucceeded, + "CANCELING": TaggingWorkRequestSummaryStatusCanceling, + "CANCELED": TaggingWorkRequestSummaryStatusCanceled, +} + +// GetTaggingWorkRequestSummaryStatusEnumValues Enumerates the set of values for TaggingWorkRequestSummaryStatusEnum +func GetTaggingWorkRequestSummaryStatusEnumValues() []TaggingWorkRequestSummaryStatusEnum { + values := make([]TaggingWorkRequestSummaryStatusEnum, 0) + for _, v := range mappingTaggingWorkRequestSummaryStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/tenancy.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tenancy.go new file mode 100644 index 000000000..cfe8285d2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/tenancy.go @@ -0,0 +1,55 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Tenancy The root compartment that contains all of your organization's compartments and other +// Oracle Cloud Infrastructure cloud resources. When you sign up for Oracle Cloud Infrastructure, +// Oracle creates a tenancy for your company, which is a secure and isolated partition +// where you can create, organize, and administer your cloud resources. +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, +// see Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type Tenancy struct { + + // The OCID of the tenancy. + Id *string `mandatory:"false" json:"id"` + + // The name of the tenancy. + Name *string `mandatory:"false" json:"name"` + + // The description of the tenancy. + Description *string `mandatory:"false" json:"description"` + + // The region key for the tenancy's home region. For the full list of supported regions, see + // Regions and Availability Domains (https://docs.cloud.oracle.com/Content/General/Concepts/regions.htm). + // Example: `PHX` + HomeRegionKey *string `mandatory:"false" json:"homeRegionKey"` + + // Url which refers to the UPI IDCS compatibility layer endpoint configured for this Tenant's home region. + UpiIdcsCompatibilityLayerEndpoint *string `mandatory:"false" json:"upiIdcsCompatibilityLayerEndpoint"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m Tenancy) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/ui_password.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/ui_password.go new file mode 100644 index 000000000..8d724d38e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/ui_password.go @@ -0,0 +1,70 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UiPassword A text password that enables a user to sign in to the Console, the user interface for interacting with Oracle +// Cloud Infrastructure. +// For more information about user credentials, see User Credentials (https://docs.cloud.oracle.com/Content/Identity/Concepts/usercredentials.htm). +type UiPassword struct { + + // The user's password for the Console. + Password *string `mandatory:"false" json:"password"` + + // The OCID of the user. + UserId *string `mandatory:"false" json:"userId"` + + // Date and time the password was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // The password's current state. After creating a password, make sure its `lifecycleState` changes from + // CREATING to ACTIVE before using it. + LifecycleState UiPasswordLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` +} + +func (m UiPassword) String() string { + return common.PointerString(m) +} + +// UiPasswordLifecycleStateEnum Enum with underlying type: string +type UiPasswordLifecycleStateEnum string + +// Set of constants representing the allowable values for UiPasswordLifecycleStateEnum +const ( + UiPasswordLifecycleStateCreating UiPasswordLifecycleStateEnum = "CREATING" + UiPasswordLifecycleStateActive UiPasswordLifecycleStateEnum = "ACTIVE" + UiPasswordLifecycleStateInactive UiPasswordLifecycleStateEnum = "INACTIVE" + UiPasswordLifecycleStateDeleting UiPasswordLifecycleStateEnum = "DELETING" + UiPasswordLifecycleStateDeleted UiPasswordLifecycleStateEnum = "DELETED" +) + +var mappingUiPasswordLifecycleState = map[string]UiPasswordLifecycleStateEnum{ + "CREATING": UiPasswordLifecycleStateCreating, + "ACTIVE": UiPasswordLifecycleStateActive, + "INACTIVE": UiPasswordLifecycleStateInactive, + "DELETING": UiPasswordLifecycleStateDeleting, + "DELETED": UiPasswordLifecycleStateDeleted, +} + +// GetUiPasswordLifecycleStateEnumValues Enumerates the set of values for UiPasswordLifecycleStateEnum +func GetUiPasswordLifecycleStateEnumValues() []UiPasswordLifecycleStateEnum { + values := make([]UiPasswordLifecycleStateEnum, 0) + for _, v := range mappingUiPasswordLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/ui_password_information.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/ui_password_information.go new file mode 100644 index 000000000..7988e14af --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/ui_password_information.go @@ -0,0 +1,64 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UiPasswordInformation Information about the UIPassword, which is a text password that enables a user to sign in to the Console, +// the user interface for interacting with Oracle Cloud Infrastructure. +// For more information about user credentials, see User Credentials (https://docs.cloud.oracle.com/Content/Identity/Concepts/usercredentials.htm). +type UiPasswordInformation struct { + + // The OCID of the user. + UserId *string `mandatory:"false" json:"userId"` + + // Date and time the password was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // The password's current state. After creating a password, make sure its `lifecycleState` changes from + // CREATING to ACTIVE before using it. + LifecycleState UiPasswordInformationLifecycleStateEnum `mandatory:"false" json:"lifecycleState,omitempty"` +} + +func (m UiPasswordInformation) String() string { + return common.PointerString(m) +} + +// UiPasswordInformationLifecycleStateEnum Enum with underlying type: string +type UiPasswordInformationLifecycleStateEnum string + +// Set of constants representing the allowable values for UiPasswordInformationLifecycleStateEnum +const ( + UiPasswordInformationLifecycleStateCreating UiPasswordInformationLifecycleStateEnum = "CREATING" + UiPasswordInformationLifecycleStateActive UiPasswordInformationLifecycleStateEnum = "ACTIVE" + UiPasswordInformationLifecycleStateInactive UiPasswordInformationLifecycleStateEnum = "INACTIVE" + UiPasswordInformationLifecycleStateDeleting UiPasswordInformationLifecycleStateEnum = "DELETING" + UiPasswordInformationLifecycleStateDeleted UiPasswordInformationLifecycleStateEnum = "DELETED" +) + +var mappingUiPasswordInformationLifecycleState = map[string]UiPasswordInformationLifecycleStateEnum{ + "CREATING": UiPasswordInformationLifecycleStateCreating, + "ACTIVE": UiPasswordInformationLifecycleStateActive, + "INACTIVE": UiPasswordInformationLifecycleStateInactive, + "DELETING": UiPasswordInformationLifecycleStateDeleting, + "DELETED": UiPasswordInformationLifecycleStateDeleted, +} + +// GetUiPasswordInformationLifecycleStateEnumValues Enumerates the set of values for UiPasswordInformationLifecycleStateEnum +func GetUiPasswordInformationLifecycleStateEnumValues() []UiPasswordInformationLifecycleStateEnum { + values := make([]UiPasswordInformationLifecycleStateEnum, 0) + for _, v := range mappingUiPasswordInformationLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_auth_token_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_auth_token_details.go new file mode 100644 index 000000000..e4bb9ef1b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_auth_token_details.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateAuthTokenDetails The representation of UpdateAuthTokenDetails +type UpdateAuthTokenDetails struct { + + // The description you assign to the auth token. Does not have to be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` +} + +func (m UpdateAuthTokenDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_auth_token_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_auth_token_request_response.go new file mode 100644 index 000000000..2087436f4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_auth_token_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateAuthTokenRequest wrapper for the UpdateAuthToken operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateAuthToken.go.html to see an example of how to use UpdateAuthTokenRequest. +type UpdateAuthTokenRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The OCID of the auth token. + AuthTokenId *string `mandatory:"true" contributesTo:"path" name:"authTokenId"` + + // Request object for updating an auth token. + UpdateAuthTokenDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateAuthTokenRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateAuthTokenRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateAuthTokenRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateAuthTokenRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateAuthTokenResponse wrapper for the UpdateAuthToken operation +type UpdateAuthTokenResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The AuthToken instance + AuthToken `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateAuthTokenResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateAuthTokenResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_authentication_policy_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_authentication_policy_details.go new file mode 100644 index 000000000..6d9dcc0e2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_authentication_policy_details.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateAuthenticationPolicyDetails Update request for authentication policy, describes set of validation rules and their parameters to be updated. +type UpdateAuthenticationPolicyDetails struct { + PasswordPolicy *PasswordPolicy `mandatory:"false" json:"passwordPolicy"` + + NetworkPolicy *NetworkPolicy `mandatory:"false" json:"networkPolicy"` +} + +func (m UpdateAuthenticationPolicyDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_authentication_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_authentication_policy_request_response.go new file mode 100644 index 000000000..f3c8e7832 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_authentication_policy_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateAuthenticationPolicyRequest wrapper for the UpdateAuthenticationPolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateAuthenticationPolicy.go.html to see an example of how to use UpdateAuthenticationPolicyRequest. +type UpdateAuthenticationPolicyRequest struct { + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"path" name:"compartmentId"` + + // Request object for updating the authentication policy. + UpdateAuthenticationPolicyDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateAuthenticationPolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateAuthenticationPolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateAuthenticationPolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateAuthenticationPolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateAuthenticationPolicyResponse wrapper for the UpdateAuthenticationPolicy operation +type UpdateAuthenticationPolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The AuthenticationPolicy instance + AuthenticationPolicy `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateAuthenticationPolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateAuthenticationPolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_compartment_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_compartment_details.go new file mode 100644 index 000000000..fb83bcf0f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_compartment_details.go @@ -0,0 +1,39 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateCompartmentDetails The representation of UpdateCompartmentDetails +type UpdateCompartmentDetails struct { + + // The description you assign to the compartment. Does not have to be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` + + // The new name you assign to the compartment. The name must be unique across all compartments in the parent compartment. + // Avoid entering confidential information. + Name *string `mandatory:"false" json:"name"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m UpdateCompartmentDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_compartment_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_compartment_request_response.go new file mode 100644 index 000000000..57c2aac06 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_compartment_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateCompartmentRequest wrapper for the UpdateCompartment operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateCompartment.go.html to see an example of how to use UpdateCompartmentRequest. +type UpdateCompartmentRequest struct { + + // The OCID of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"path" name:"compartmentId"` + + // Request object for updating a compartment. + UpdateCompartmentDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateCompartmentRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateCompartmentRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateCompartmentRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateCompartmentRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateCompartmentResponse wrapper for the UpdateCompartment operation +type UpdateCompartmentResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Compartment instance + Compartment `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateCompartmentResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateCompartmentResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_customer_secret_key_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_customer_secret_key_details.go new file mode 100644 index 000000000..9c632bb80 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_customer_secret_key_details.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateCustomerSecretKeyDetails The representation of UpdateCustomerSecretKeyDetails +type UpdateCustomerSecretKeyDetails struct { + + // The description you assign to the secret key. Does not have to be unique, and it's changeable. + DisplayName *string `mandatory:"false" json:"displayName"` +} + +func (m UpdateCustomerSecretKeyDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_customer_secret_key_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_customer_secret_key_request_response.go new file mode 100644 index 000000000..07b310b05 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_customer_secret_key_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateCustomerSecretKeyRequest wrapper for the UpdateCustomerSecretKey operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateCustomerSecretKey.go.html to see an example of how to use UpdateCustomerSecretKeyRequest. +type UpdateCustomerSecretKeyRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The OCID of the secret key. + CustomerSecretKeyId *string `mandatory:"true" contributesTo:"path" name:"customerSecretKeyId"` + + // Request object for updating a secret key. + UpdateCustomerSecretKeyDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateCustomerSecretKeyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateCustomerSecretKeyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateCustomerSecretKeyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateCustomerSecretKeyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateCustomerSecretKeyResponse wrapper for the UpdateCustomerSecretKey operation +type UpdateCustomerSecretKeyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The CustomerSecretKeySummary instance + CustomerSecretKeySummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateCustomerSecretKeyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateCustomerSecretKeyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_domain_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_domain_details.go new file mode 100644 index 000000000..f52dfdf01 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_domain_details.go @@ -0,0 +1,41 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateDomainDetails Update domain details +type UpdateDomainDetails struct { + + // The domain description + Description *string `mandatory:"false" json:"description"` + + // The mutable display name of the domain + DisplayName *string `mandatory:"false" json:"displayName"` + + // Indicates whether domain is hidden on login screen or not. + IsHiddenOnLogin *bool `mandatory:"false" json:"isHiddenOnLogin"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m UpdateDomainDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_domain_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_domain_request_response.go new file mode 100644 index 000000000..05cfa6f07 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_domain_request_response.go @@ -0,0 +1,82 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateDomainRequest wrapper for the UpdateDomain operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateDomain.go.html to see an example of how to use UpdateDomainRequest. +type UpdateDomainRequest struct { + + // The OCID of the domain + DomainId *string `mandatory:"true" contributesTo:"path" name:"domainId"` + + // Request object for updating the Domain. + UpdateDomainDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateDomainRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateDomainRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateDomainRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateDomainRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateDomainResponse wrapper for the UpdateDomain operation +type UpdateDomainResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the work request. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` +} + +func (response UpdateDomainResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateDomainResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_dynamic_group_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_dynamic_group_details.go new file mode 100644 index 000000000..a9e16904f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_dynamic_group_details.go @@ -0,0 +1,39 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateDynamicGroupDetails Properties for updating a dynamic group. +type UpdateDynamicGroupDetails struct { + + // The description you assign to the dynamic group. Does not have to be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` + + // The matching rule to dynamically match an instance certificate to this dynamic group. + // For rule syntax, see Managing Dynamic Groups (https://docs.cloud.oracle.com/Content/Identity/Tasks/managingdynamicgroups.htm). + MatchingRule *string `mandatory:"false" json:"matchingRule"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m UpdateDynamicGroupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_dynamic_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_dynamic_group_request_response.go new file mode 100644 index 000000000..a712cfc57 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_dynamic_group_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateDynamicGroupRequest wrapper for the UpdateDynamicGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateDynamicGroup.go.html to see an example of how to use UpdateDynamicGroupRequest. +type UpdateDynamicGroupRequest struct { + + // The OCID of the dynamic group. + DynamicGroupId *string `mandatory:"true" contributesTo:"path" name:"dynamicGroupId"` + + // Request object for updating an dynamic group. + UpdateDynamicGroupDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateDynamicGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateDynamicGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateDynamicGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateDynamicGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateDynamicGroupResponse wrapper for the UpdateDynamicGroup operation +type UpdateDynamicGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The DynamicGroup instance + DynamicGroup `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateDynamicGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateDynamicGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_group_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_group_details.go new file mode 100644 index 000000000..6adb125f6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_group_details.go @@ -0,0 +1,35 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateGroupDetails The representation of UpdateGroupDetails +type UpdateGroupDetails struct { + + // The description you assign to the group. Does not have to be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m UpdateGroupDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_group_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_group_request_response.go new file mode 100644 index 000000000..1b193f931 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_group_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateGroupRequest wrapper for the UpdateGroup operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateGroup.go.html to see an example of how to use UpdateGroupRequest. +type UpdateGroupRequest struct { + + // The OCID of the group. + GroupId *string `mandatory:"true" contributesTo:"path" name:"groupId"` + + // Request object for updating a group. + UpdateGroupDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateGroupRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateGroupRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateGroupRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateGroupRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateGroupResponse wrapper for the UpdateGroup operation +type UpdateGroupResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Group instance + Group `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateGroupResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateGroupResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_identity_provider_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_identity_provider_details.go new file mode 100644 index 000000000..0e261f489 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_identity_provider_details.go @@ -0,0 +1,118 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateIdentityProviderDetails The representation of UpdateIdentityProviderDetails +type UpdateIdentityProviderDetails interface { + + // The description you assign to the `IdentityProvider`. Does not have to + // be unique, and it's changeable. + GetDescription() *string + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + GetFreeformTags() map[string]string + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + GetDefinedTags() map[string]map[string]interface{} +} + +type updateidentityproviderdetails struct { + JsonData []byte + Description *string `mandatory:"false" json:"description"` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + Protocol string `json:"protocol"` +} + +// UnmarshalJSON unmarshals json +func (m *updateidentityproviderdetails) UnmarshalJSON(data []byte) error { + m.JsonData = data + type Unmarshalerupdateidentityproviderdetails updateidentityproviderdetails + s := struct { + Model Unmarshalerupdateidentityproviderdetails + }{} + err := json.Unmarshal(data, &s.Model) + if err != nil { + return err + } + m.Description = s.Model.Description + m.FreeformTags = s.Model.FreeformTags + m.DefinedTags = s.Model.DefinedTags + m.Protocol = s.Model.Protocol + + return err +} + +// UnmarshalPolymorphicJSON unmarshals polymorphic json +func (m *updateidentityproviderdetails) UnmarshalPolymorphicJSON(data []byte) (interface{}, error) { + + if data == nil || string(data) == "null" { + return nil, nil + } + + var err error + switch m.Protocol { + case "SAML2": + mm := UpdateSaml2IdentityProviderDetails{} + err = json.Unmarshal(data, &mm) + return mm, err + default: + return *m, nil + } +} + +//GetDescription returns Description +func (m updateidentityproviderdetails) GetDescription() *string { + return m.Description +} + +//GetFreeformTags returns FreeformTags +func (m updateidentityproviderdetails) GetFreeformTags() map[string]string { + return m.FreeformTags +} + +//GetDefinedTags returns DefinedTags +func (m updateidentityproviderdetails) GetDefinedTags() map[string]map[string]interface{} { + return m.DefinedTags +} + +func (m updateidentityproviderdetails) String() string { + return common.PointerString(m) +} + +// UpdateIdentityProviderDetailsProtocolEnum Enum with underlying type: string +type UpdateIdentityProviderDetailsProtocolEnum string + +// Set of constants representing the allowable values for UpdateIdentityProviderDetailsProtocolEnum +const ( + UpdateIdentityProviderDetailsProtocolSaml2 UpdateIdentityProviderDetailsProtocolEnum = "SAML2" +) + +var mappingUpdateIdentityProviderDetailsProtocol = map[string]UpdateIdentityProviderDetailsProtocolEnum{ + "SAML2": UpdateIdentityProviderDetailsProtocolSaml2, +} + +// GetUpdateIdentityProviderDetailsProtocolEnumValues Enumerates the set of values for UpdateIdentityProviderDetailsProtocolEnum +func GetUpdateIdentityProviderDetailsProtocolEnumValues() []UpdateIdentityProviderDetailsProtocolEnum { + values := make([]UpdateIdentityProviderDetailsProtocolEnum, 0) + for _, v := range mappingUpdateIdentityProviderDetailsProtocol { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_identity_provider_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_identity_provider_request_response.go new file mode 100644 index 000000000..9d4cf0f3a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_identity_provider_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateIdentityProviderRequest wrapper for the UpdateIdentityProvider operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateIdentityProvider.go.html to see an example of how to use UpdateIdentityProviderRequest. +type UpdateIdentityProviderRequest struct { + + // The OCID of the identity provider. + IdentityProviderId *string `mandatory:"true" contributesTo:"path" name:"identityProviderId"` + + // Request object for updating a identity provider. + UpdateIdentityProviderDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateIdentityProviderRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateIdentityProviderRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateIdentityProviderRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateIdentityProviderRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateIdentityProviderResponse wrapper for the UpdateIdentityProvider operation +type UpdateIdentityProviderResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IdentityProvider instance + IdentityProvider `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateIdentityProviderResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateIdentityProviderResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_idp_group_mapping_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_idp_group_mapping_details.go new file mode 100644 index 000000000..e205ca247 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_idp_group_mapping_details.go @@ -0,0 +1,28 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateIdpGroupMappingDetails The representation of UpdateIdpGroupMappingDetails +type UpdateIdpGroupMappingDetails struct { + + // The idp group name. + IdpGroupName *string `mandatory:"false" json:"idpGroupName"` + + // The OCID of the group. + GroupId *string `mandatory:"false" json:"groupId"` +} + +func (m UpdateIdpGroupMappingDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_idp_group_mapping_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_idp_group_mapping_request_response.go new file mode 100644 index 000000000..2213b1fcc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_idp_group_mapping_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateIdpGroupMappingRequest wrapper for the UpdateIdpGroupMapping operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateIdpGroupMapping.go.html to see an example of how to use UpdateIdpGroupMappingRequest. +type UpdateIdpGroupMappingRequest struct { + + // The OCID of the identity provider. + IdentityProviderId *string `mandatory:"true" contributesTo:"path" name:"identityProviderId"` + + // The OCID of the group mapping. + MappingId *string `mandatory:"true" contributesTo:"path" name:"mappingId"` + + // Request object for updating an identity provider group mapping + UpdateIdpGroupMappingDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateIdpGroupMappingRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateIdpGroupMappingRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateIdpGroupMappingRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateIdpGroupMappingRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateIdpGroupMappingResponse wrapper for the UpdateIdpGroupMapping operation +type UpdateIdpGroupMappingResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The IdpGroupMapping instance + IdpGroupMapping `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateIdpGroupMappingResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateIdpGroupMappingResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_network_source_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_network_source_details.go new file mode 100644 index 000000000..8a9a02383 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_network_source_details.go @@ -0,0 +1,46 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateNetworkSourceDetails The representation of UpdateNetworkSourceDetails +type UpdateNetworkSourceDetails struct { + + // The description you assign to the network source. Does not have to be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` + + // A list of allowed public IP addresses and CIDR ranges. + PublicSourceList []string `mandatory:"false" json:"publicSourceList"` + + // A list of allowed VCN OCID and IP range pairs. + // Example:`"vcnId": "ocid1.vcn.oc1.iad.aaaaaaaaexampleuniqueID", "ipRanges": [ "129.213.39.0/24" ]` + VirtualSourceList []NetworkSourcesVirtualSourceList `mandatory:"false" json:"virtualSourceList"` + + // A list of services allowed to make on-behalf-of requests. These requests can have different source IPs than + // those specified in the network source. Currently, only `all` and `none` are supported. The default is `all`. + Services []string `mandatory:"false" json:"services"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m UpdateNetworkSourceDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_network_source_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_network_source_request_response.go new file mode 100644 index 000000000..6f3fe3c44 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_network_source_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateNetworkSourceRequest wrapper for the UpdateNetworkSource operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateNetworkSource.go.html to see an example of how to use UpdateNetworkSourceRequest. +type UpdateNetworkSourceRequest struct { + + // The OCID of the network source. + NetworkSourceId *string `mandatory:"true" contributesTo:"path" name:"networkSourceId"` + + // Request object for updating a network source. + UpdateNetworkSourceDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateNetworkSourceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateNetworkSourceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateNetworkSourceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateNetworkSourceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateNetworkSourceResponse wrapper for the UpdateNetworkSource operation +type UpdateNetworkSourceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The NetworkSources instance + NetworkSources `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateNetworkSourceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateNetworkSourceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_o_auth2_client_credential_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_o_auth2_client_credential_details.go new file mode 100644 index 000000000..cb27c8f0a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_o_auth2_client_credential_details.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateOAuth2ClientCredentialDetails The representation of UpdateOAuth2ClientCredentialDetails +type UpdateOAuth2ClientCredentialDetails struct { + + // Description of the oauth credential to help user differentiate them. + Description *string `mandatory:"true" json:"description"` + + // Allowed scopes for the given oauth credential. + Scopes []FullyQualifiedScope `mandatory:"true" json:"scopes"` + + // Indicate if the password to be reset or not in the update. + IsResetPassword *bool `mandatory:"false" json:"isResetPassword"` +} + +func (m UpdateOAuth2ClientCredentialDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_o_auth_client_credential_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_o_auth_client_credential_request_response.go new file mode 100644 index 000000000..273478b0f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_o_auth_client_credential_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateOAuthClientCredentialRequest wrapper for the UpdateOAuthClientCredential operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateOAuthClientCredential.go.html to see an example of how to use UpdateOAuthClientCredentialRequest. +type UpdateOAuthClientCredentialRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The ID of the Oauth credential. + Oauth2ClientCredentialId *string `mandatory:"true" contributesTo:"path" name:"oauth2ClientCredentialId"` + + // Request object containing the information required to generate an Oauth token. + UpdateOAuth2ClientCredentialDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateOAuthClientCredentialRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateOAuthClientCredentialRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateOAuthClientCredentialRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateOAuthClientCredentialRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateOAuthClientCredentialResponse wrapper for the UpdateOAuthClientCredential operation +type UpdateOAuthClientCredentialResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The OAuth2ClientCredential instance + OAuth2ClientCredential `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateOAuthClientCredentialResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateOAuthClientCredentialResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_policy_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_policy_details.go new file mode 100644 index 000000000..19971bf87 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_policy_details.go @@ -0,0 +1,45 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdatePolicyDetails The representation of UpdatePolicyDetails +type UpdatePolicyDetails struct { + + // The description you assign to the policy. Does not have to be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` + + // An array of policy statements written in the policy language. See + // How Policies Work (https://docs.cloud.oracle.com/Content/Identity/Concepts/policies.htm) and + // Common Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/commonpolicies.htm). + Statements []string `mandatory:"false" json:"statements"` + + // The version of the policy. If null or set to an empty string, when a request comes in for authorization, the + // policy will be evaluated according to the current behavior of the services at that moment. If set to a particular + // date (YYYY-MM-DD), the policy will be evaluated according to the behavior of the services on that date. + VersionDate *common.SDKDate `mandatory:"false" json:"versionDate"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m UpdatePolicyDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_policy_request_response.go new file mode 100644 index 000000000..1e40e74cb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_policy_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdatePolicyRequest wrapper for the UpdatePolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdatePolicy.go.html to see an example of how to use UpdatePolicyRequest. +type UpdatePolicyRequest struct { + + // The OCID of the policy. + PolicyId *string `mandatory:"true" contributesTo:"path" name:"policyId"` + + // Request object for updating a policy. + UpdatePolicyDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdatePolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdatePolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdatePolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdatePolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdatePolicyResponse wrapper for the UpdatePolicy operation +type UpdatePolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Policy instance + Policy `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdatePolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdatePolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_saml2_identity_provider_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_saml2_identity_provider_details.go new file mode 100644 index 000000000..b75f74dd2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_saml2_identity_provider_details.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateSaml2IdentityProviderDetails The representation of UpdateSaml2IdentityProviderDetails +type UpdateSaml2IdentityProviderDetails struct { + + // The description you assign to the `IdentityProvider`. Does not have to + // be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // The URL for retrieving the identity provider's metadata, + // which contains information required for federating. + MetadataUrl *string `mandatory:"false" json:"metadataUrl"` + + // The XML that contains the information required for federating. + Metadata *string `mandatory:"false" json:"metadata"` + + // Extra name value pairs associated with this identity provider. + // Example: `{"clientId": "app_sf3kdjf3"}` + FreeformAttributes map[string]string `mandatory:"false" json:"freeformAttributes"` +} + +//GetDescription returns Description +func (m UpdateSaml2IdentityProviderDetails) GetDescription() *string { + return m.Description +} + +//GetFreeformTags returns FreeformTags +func (m UpdateSaml2IdentityProviderDetails) GetFreeformTags() map[string]string { + return m.FreeformTags +} + +//GetDefinedTags returns DefinedTags +func (m UpdateSaml2IdentityProviderDetails) GetDefinedTags() map[string]map[string]interface{} { + return m.DefinedTags +} + +func (m UpdateSaml2IdentityProviderDetails) String() string { + return common.PointerString(m) +} + +// MarshalJSON marshals to json representation +func (m UpdateSaml2IdentityProviderDetails) MarshalJSON() (buff []byte, e error) { + type MarshalTypeUpdateSaml2IdentityProviderDetails UpdateSaml2IdentityProviderDetails + s := struct { + DiscriminatorParam string `json:"protocol"` + MarshalTypeUpdateSaml2IdentityProviderDetails + }{ + "SAML2", + (MarshalTypeUpdateSaml2IdentityProviderDetails)(m), + } + + return json.Marshal(&s) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_smtp_credential_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_smtp_credential_details.go new file mode 100644 index 000000000..d3cd4ff09 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_smtp_credential_details.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateSmtpCredentialDetails The representation of UpdateSmtpCredentialDetails +type UpdateSmtpCredentialDetails struct { + + // The description you assign to the SMTP credential. Does not have to be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` +} + +func (m UpdateSmtpCredentialDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_smtp_credential_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_smtp_credential_request_response.go new file mode 100644 index 000000000..513c3da6c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_smtp_credential_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateSmtpCredentialRequest wrapper for the UpdateSmtpCredential operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateSmtpCredential.go.html to see an example of how to use UpdateSmtpCredentialRequest. +type UpdateSmtpCredentialRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The OCID of the SMTP credential. + SmtpCredentialId *string `mandatory:"true" contributesTo:"path" name:"smtpCredentialId"` + + // Request object for updating a SMTP credential. + UpdateSmtpCredentialDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateSmtpCredentialRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateSmtpCredentialRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateSmtpCredentialRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateSmtpCredentialRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateSmtpCredentialResponse wrapper for the UpdateSmtpCredential operation +type UpdateSmtpCredentialResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The SmtpCredentialSummary instance + SmtpCredentialSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateSmtpCredentialResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateSmtpCredentialResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_state_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_state_details.go new file mode 100644 index 000000000..3bf2646ef --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_state_details.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateStateDetails The representation of UpdateStateDetails +type UpdateStateDetails struct { + + // Update state to blocked or unblocked. Only "false" is supported (for changing the state to unblocked). + Blocked *bool `mandatory:"false" json:"blocked"` +} + +func (m UpdateStateDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_swift_password_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_swift_password_details.go new file mode 100644 index 000000000..fa8d0b129 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_swift_password_details.go @@ -0,0 +1,25 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateSwiftPasswordDetails The representation of UpdateSwiftPasswordDetails +type UpdateSwiftPasswordDetails struct { + + // The description you assign to the Swift password. Does not have to be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` +} + +func (m UpdateSwiftPasswordDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_swift_password_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_swift_password_request_response.go new file mode 100644 index 000000000..280b701ef --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_swift_password_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateSwiftPasswordRequest wrapper for the UpdateSwiftPassword operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateSwiftPassword.go.html to see an example of how to use UpdateSwiftPasswordRequest. +type UpdateSwiftPasswordRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // The OCID of the Swift password. + SwiftPasswordId *string `mandatory:"true" contributesTo:"path" name:"swiftPasswordId"` + + // Request object for updating a Swift password. + UpdateSwiftPasswordDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateSwiftPasswordRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateSwiftPasswordRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateSwiftPasswordRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateSwiftPasswordRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateSwiftPasswordResponse wrapper for the UpdateSwiftPassword operation +type UpdateSwiftPasswordResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The SwiftPassword instance + SwiftPassword `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateSwiftPasswordResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateSwiftPasswordResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_default_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_default_details.go new file mode 100644 index 000000000..ccb2aee6d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_default_details.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateTagDefaultDetails The representation of UpdateTagDefaultDetails +type UpdateTagDefaultDetails struct { + + // The default value for the tag definition. This will be applied to all resources created in the Compartment. + Value *string `mandatory:"true" json:"value"` + + // If you specify that a value is required, a value is set during resource creation (either by + // the user creating the resource or another tag defualt). If no value is set, resource + // creation is blocked. + // * If the `isRequired` flag is set to "true", the value is set during resource creation. + // * If the `isRequired` flag is set to "false", the value you enter is set during resource creation. + // Example: `false` + IsRequired *bool `mandatory:"false" json:"isRequired"` +} + +func (m UpdateTagDefaultDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_default_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_default_request_response.go new file mode 100644 index 000000000..690e61b03 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_default_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateTagDefaultRequest wrapper for the UpdateTagDefault operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateTagDefault.go.html to see an example of how to use UpdateTagDefaultRequest. +type UpdateTagDefaultRequest struct { + + // The OCID of the tag default. + TagDefaultId *string `mandatory:"true" contributesTo:"path" name:"tagDefaultId"` + + // Request object for updating a tag default. + UpdateTagDefaultDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateTagDefaultRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateTagDefaultRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateTagDefaultRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateTagDefaultRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateTagDefaultResponse wrapper for the UpdateTagDefault operation +type UpdateTagDefaultResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The TagDefault instance + TagDefault `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateTagDefaultResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateTagDefaultResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_details.go new file mode 100644 index 000000000..5481ad582 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_details.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "encoding/json" + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateTagDetails The representation of UpdateTagDetails +type UpdateTagDetails struct { + + // The description you assign to the tag during creation. + Description *string `mandatory:"false" json:"description"` + + // Whether the tag is retired. + // See Retiring Key Definitions and Namespace Definitions (https://docs.cloud.oracle.com/Content/Identity/Concepts/taggingoverview.htm#Retiring). + IsRetired *bool `mandatory:"false" json:"isRetired"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // Indicates whether the tag is enabled for cost tracking. + IsCostTracking *bool `mandatory:"false" json:"isCostTracking"` + + Validator BaseTagDefinitionValidator `mandatory:"false" json:"validator"` +} + +func (m UpdateTagDetails) String() string { + return common.PointerString(m) +} + +// UnmarshalJSON unmarshals from json +func (m *UpdateTagDetails) UnmarshalJSON(data []byte) (e error) { + model := struct { + Description *string `json:"description"` + IsRetired *bool `json:"isRetired"` + FreeformTags map[string]string `json:"freeformTags"` + DefinedTags map[string]map[string]interface{} `json:"definedTags"` + IsCostTracking *bool `json:"isCostTracking"` + Validator basetagdefinitionvalidator `json:"validator"` + }{} + + e = json.Unmarshal(data, &model) + if e != nil { + return + } + var nn interface{} + m.Description = model.Description + + m.IsRetired = model.IsRetired + + m.FreeformTags = model.FreeformTags + + m.DefinedTags = model.DefinedTags + + m.IsCostTracking = model.IsCostTracking + + nn, e = model.Validator.UnmarshalPolymorphicJSON(model.Validator.JsonData) + if e != nil { + return + } + if nn != nil { + m.Validator = nn.(BaseTagDefinitionValidator) + } else { + m.Validator = nil + } + + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_namespace_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_namespace_details.go new file mode 100644 index 000000000..938d7d3ad --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_namespace_details.go @@ -0,0 +1,39 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateTagNamespaceDetails The representation of UpdateTagNamespaceDetails +type UpdateTagNamespaceDetails struct { + + // The description you assign to the tag namespace. + Description *string `mandatory:"false" json:"description"` + + // Whether the tag namespace is retired. + // See Retiring Key Definitions and Namespace Definitions (https://docs.cloud.oracle.com/Content/Identity/Concepts/taggingoverview.htm#Retiring). + IsRetired *bool `mandatory:"false" json:"isRetired"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m UpdateTagNamespaceDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_namespace_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_namespace_request_response.go new file mode 100644 index 000000000..e9e7c9d89 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_namespace_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateTagNamespaceRequest wrapper for the UpdateTagNamespace operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateTagNamespace.go.html to see an example of how to use UpdateTagNamespaceRequest. +type UpdateTagNamespaceRequest struct { + + // The OCID of the tag namespace. + TagNamespaceId *string `mandatory:"true" contributesTo:"path" name:"tagNamespaceId"` + + // Request object for updating a namespace. + UpdateTagNamespaceDetails `contributesTo:"body"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateTagNamespaceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateTagNamespaceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateTagNamespaceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateTagNamespaceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateTagNamespaceResponse wrapper for the UpdateTagNamespace operation +type UpdateTagNamespaceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The TagNamespace instance + TagNamespace `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateTagNamespaceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateTagNamespaceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_request_response.go new file mode 100644 index 000000000..48c69df1e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_tag_request_response.go @@ -0,0 +1,88 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateTagRequest wrapper for the UpdateTag operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateTag.go.html to see an example of how to use UpdateTagRequest. +type UpdateTagRequest struct { + + // The OCID of the tag namespace. + TagNamespaceId *string `mandatory:"true" contributesTo:"path" name:"tagNamespaceId"` + + // The name of the tag. + TagName *string `mandatory:"true" contributesTo:"path" name:"tagName"` + + // Request object for updating a tag. + UpdateTagDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateTagRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateTagRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateTagRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateTagRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateTagResponse wrapper for the UpdateTag operation +type UpdateTagResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Tag instance + Tag `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateTagResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateTagResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_capabilities_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_capabilities_details.go new file mode 100644 index 000000000..3fa5e1eb9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_capabilities_details.go @@ -0,0 +1,43 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateUserCapabilitiesDetails The representation of UpdateUserCapabilitiesDetails +type UpdateUserCapabilitiesDetails struct { + + // Indicates if the user can log in to the console. + CanUseConsolePassword *bool `mandatory:"false" json:"canUseConsolePassword"` + + // Indicates if the user can use API keys. + CanUseApiKeys *bool `mandatory:"false" json:"canUseApiKeys"` + + // Indicates if the user can use SWIFT passwords / auth tokens. + CanUseAuthTokens *bool `mandatory:"false" json:"canUseAuthTokens"` + + // Indicates if the user can use SMTP passwords. + CanUseSmtpCredentials *bool `mandatory:"false" json:"canUseSmtpCredentials"` + + // Indicates if the user can use DB passwords. + CanUseDBCredentials *bool `mandatory:"false" json:"canUseDBCredentials"` + + // Indicates if the user can use SigV4 symmetric keys. + CanUseCustomerSecretKeys *bool `mandatory:"false" json:"canUseCustomerSecretKeys"` + + // Indicates if the user can use OAuth2 credentials and tokens. + CanUseOAuth2ClientCredentials *bool `mandatory:"false" json:"canUseOAuth2ClientCredentials"` +} + +func (m UpdateUserCapabilitiesDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_capabilities_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_capabilities_request_response.go new file mode 100644 index 000000000..a305ea3e8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_capabilities_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateUserCapabilitiesRequest wrapper for the UpdateUserCapabilities operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateUserCapabilities.go.html to see an example of how to use UpdateUserCapabilitiesRequest. +type UpdateUserCapabilitiesRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // Request object for updating user capabilities. + UpdateUserCapabilitiesDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateUserCapabilitiesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateUserCapabilitiesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateUserCapabilitiesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateUserCapabilitiesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateUserCapabilitiesResponse wrapper for the UpdateUserCapabilities operation +type UpdateUserCapabilitiesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The User instance + User `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateUserCapabilitiesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateUserCapabilitiesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_details.go new file mode 100644 index 000000000..08eadc760 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_details.go @@ -0,0 +1,41 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateUserDetails The representation of UpdateUserDetails +type UpdateUserDetails struct { + + // The description you assign to the user. Does not have to be unique, and it's changeable. + Description *string `mandatory:"false" json:"description"` + + // The email address you assign to the user. Has to be unique across the tenancy. + Email *string `mandatory:"false" json:"email"` + + // DB username of the DB credential. Has to be unique across the tenancy. + DbUserName *string `mandatory:"false" json:"dbUserName"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m UpdateUserDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_request_response.go new file mode 100644 index 000000000..c8dccc471 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateUserRequest wrapper for the UpdateUser operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateUser.go.html to see an example of how to use UpdateUserRequest. +type UpdateUserRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // Request object for updating a user. + UpdateUserDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateUserRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateUserRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateUserRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateUserRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateUserResponse wrapper for the UpdateUser operation +type UpdateUserResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The User instance + User `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateUserResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateUserResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_state_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_state_request_response.go new file mode 100644 index 000000000..41b759932 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/update_user_state_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateUserStateRequest wrapper for the UpdateUserState operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UpdateUserState.go.html to see an example of how to use UpdateUserStateRequest. +type UpdateUserStateRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // Request object for updating a user state. + UpdateStateDetails `contributesTo:"body"` + + // 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. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateUserStateRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateUserStateRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateUserStateRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateUserStateRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateUserStateResponse wrapper for the UpdateUserState operation +type UpdateUserStateResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The User instance + User `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateUserStateResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateUserStateResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/upload_api_key_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/upload_api_key_request_response.go new file mode 100644 index 000000000..324b4a27e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/upload_api_key_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UploadApiKeyRequest wrapper for the UploadApiKey operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/identity/UploadApiKey.go.html to see an example of how to use UploadApiKeyRequest. +type UploadApiKeyRequest struct { + + // The OCID of the user. + UserId *string `mandatory:"true" contributesTo:"path" name:"userId"` + + // Request object for uploading an API key for a user. + CreateApiKeyDetails `contributesTo:"body"` + + // 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 (e.g., if a resource + // has been deleted and purged from the system, then a retry of the original creation request + // may be rejected). + OpcRetryToken *string `mandatory:"false" contributesTo:"header" name:"opc-retry-token"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UploadApiKeyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UploadApiKeyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UploadApiKeyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UploadApiKeyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UploadApiKeyResponse wrapper for the UploadApiKey operation +type UploadApiKeyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ApiKey instance + ApiKey `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For optimistic concurrency control. See `if-match`. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UploadApiKeyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UploadApiKeyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/user.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/user.go new file mode 100644 index 000000000..7614ec5bc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/user.go @@ -0,0 +1,146 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// User An individual employee or system that needs to manage or use your company's Oracle Cloud Infrastructure +// resources. Users might need to launch instances, manage remote disks, work with your cloud network, etc. Users +// have one or more IAM Service credentials (ApiKey, +// UIPassword, SwiftPassword and +// AuthToken). +// For more information, see User Credentials (https://docs.cloud.oracle.com/Content/Identity/Concepts/usercredentials.htm)). End users of your +// application are not typically IAM Service users. For conceptual information about users and other IAM Service +// components, see Overview of the IAM Service (https://docs.cloud.oracle.com/Content/Identity/Concepts/overview.htm). +// These users are created directly within the Oracle Cloud Infrastructure system, via the IAM service. +// They are different from *federated users*, who authenticate themselves to the Oracle Cloud Infrastructure +// Console via an identity provider. For more information, see +// Identity Providers and Federation (https://docs.cloud.oracle.com/Content/Identity/Concepts/federation.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you're not authorized, +// talk to an administrator. If you're an administrator who needs to write policies to give users access, +// see Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +// **Warning:** Oracle recommends that you avoid using any confidential information when you supply string values +// using the API. +type User struct { + + // The OCID of the user. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the tenancy containing the user. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The name you assign to the user during creation. This is the user's login for the Console. + // The name must be unique across all users in the tenancy and cannot be changed. + Name *string `mandatory:"true" json:"name"` + + // The description you assign to the user. Does not have to be unique, and it's changeable. + Description *string `mandatory:"true" json:"description"` + + // Date and time the user was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The user's current state. After creating a user, make sure its `lifecycleState` changes from CREATING to + // ACTIVE before using it. + LifecycleState UserLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // Flag indicates if MFA has been activated for the user. + IsMfaActivated *bool `mandatory:"true" json:"isMfaActivated"` + + // The email address you assign to the user. + // The email address must be unique across all users in the tenancy. + Email *string `mandatory:"false" json:"email"` + + // Whether the email address has been validated. + EmailVerified *bool `mandatory:"false" json:"emailVerified"` + + // DB username of the DB credential. Has to be unique across the tenancy. + DbUserName *string `mandatory:"false" json:"dbUserName"` + + // The OCID of the `IdentityProvider` this user belongs to. + IdentityProviderId *string `mandatory:"false" json:"identityProviderId"` + + // Identifier of the user in the identity provider + ExternalIdentifier *string `mandatory:"false" json:"externalIdentifier"` + + // Returned only if the user's `lifecycleState` is INACTIVE. A 16-bit value showing the reason why the user + // is inactive: + // - bit 0: SUSPENDED (reserved for future use) + // - bit 1: DISABLED (reserved for future use) + // - bit 2: BLOCKED (the user has exceeded the maximum number of failed login attempts for the Console) + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + Capabilities *UserCapabilities `mandatory:"false" json:"capabilities"` + + // The date and time of when the user most recently logged in the + // format defined by RFC3339 (ex. `2016-08-25T21:10:29.600Z`). + // If there is no login history, this field is null. + // For illustrative purposes, suppose we have a user who has logged in + // at July 1st, 2020 at 1200 PST and logged out 30 minutes later. + // They then login again on July 2nd, 2020 at 1500 PST. + // Their previousSuccessfulLoginTime would be `2020-07-01:19:00.000Z`. + // Their lastSuccessfulLoginTime would be `2020-07-02:22:00.000Z`. + LastSuccessfulLoginTime *common.SDKTime `mandatory:"false" json:"lastSuccessfulLoginTime"` + + // The date and time of when the user most recently logged in the + // format defined by RFC3339 (ex. `2016-08-25T21:10:29.600Z`). + // If there is no login history, this field is null. + // For illustrative purposes, suppose we have a user who has logged in + // at July 1st, 2020 at 1200 PST and logged out 30 minutes later. + // They then login again on July 2nd, 2020 at 1500 PST. + // Their previousSuccessfulLoginTime would be `2020-07-01:19:00.000Z`. + // Their lastSuccessfulLoginTime would be `2020-07-02:22:00.000Z`. + PreviousSuccessfulLoginTime *common.SDKTime `mandatory:"false" json:"previousSuccessfulLoginTime"` +} + +func (m User) String() string { + return common.PointerString(m) +} + +// UserLifecycleStateEnum Enum with underlying type: string +type UserLifecycleStateEnum string + +// Set of constants representing the allowable values for UserLifecycleStateEnum +const ( + UserLifecycleStateCreating UserLifecycleStateEnum = "CREATING" + UserLifecycleStateActive UserLifecycleStateEnum = "ACTIVE" + UserLifecycleStateInactive UserLifecycleStateEnum = "INACTIVE" + UserLifecycleStateDeleting UserLifecycleStateEnum = "DELETING" + UserLifecycleStateDeleted UserLifecycleStateEnum = "DELETED" +) + +var mappingUserLifecycleState = map[string]UserLifecycleStateEnum{ + "CREATING": UserLifecycleStateCreating, + "ACTIVE": UserLifecycleStateActive, + "INACTIVE": UserLifecycleStateInactive, + "DELETING": UserLifecycleStateDeleting, + "DELETED": UserLifecycleStateDeleted, +} + +// GetUserLifecycleStateEnumValues Enumerates the set of values for UserLifecycleStateEnum +func GetUserLifecycleStateEnumValues() []UserLifecycleStateEnum { + values := make([]UserLifecycleStateEnum, 0) + for _, v := range mappingUserLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/user_capabilities.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/user_capabilities.go new file mode 100644 index 000000000..844d73da6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/user_capabilities.go @@ -0,0 +1,43 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UserCapabilities Properties indicating how the user is allowed to authenticate. +type UserCapabilities struct { + + // Indicates if the user can log in to the console. + CanUseConsolePassword *bool `mandatory:"false" json:"canUseConsolePassword"` + + // Indicates if the user can use API keys. + CanUseApiKeys *bool `mandatory:"false" json:"canUseApiKeys"` + + // Indicates if the user can use SWIFT passwords / auth tokens. + CanUseAuthTokens *bool `mandatory:"false" json:"canUseAuthTokens"` + + // Indicates if the user can use SMTP passwords. + CanUseSmtpCredentials *bool `mandatory:"false" json:"canUseSmtpCredentials"` + + // Indicates if the user can use DB passwords. + CanUseDbCredentials *bool `mandatory:"false" json:"canUseDbCredentials"` + + // Indicates if the user can use SigV4 symmetric keys. + CanUseCustomerSecretKeys *bool `mandatory:"false" json:"canUseCustomerSecretKeys"` + + // Indicates if the user can use OAuth2 credentials and tokens. + CanUseOAuth2ClientCredentials *bool `mandatory:"false" json:"canUseOAuth2ClientCredentials"` +} + +func (m UserCapabilities) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/user_group_membership.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/user_group_membership.go new file mode 100644 index 000000000..7621c08a3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/user_group_membership.go @@ -0,0 +1,75 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UserGroupMembership An object that represents the membership of a user in a group. When you add a user to a group, the result is a +// `UserGroupMembership` with its own OCID. To remove a user from a group, you delete the `UserGroupMembership` object. +type UserGroupMembership struct { + + // The OCID of the membership. + Id *string `mandatory:"true" json:"id"` + + // The OCID of the tenancy containing the user, group, and membership object. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID of the group. + GroupId *string `mandatory:"true" json:"groupId"` + + // The OCID of the user. + UserId *string `mandatory:"true" json:"userId"` + + // Date and time the membership was created, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The membership's current state. After creating a membership object, make sure its `lifecycleState` changes + // from CREATING to ACTIVE before using it. + LifecycleState UserGroupMembershipLifecycleStateEnum `mandatory:"true" json:"lifecycleState"` + + // The detailed status of INACTIVE lifecycleState. + InactiveStatus *int64 `mandatory:"false" json:"inactiveStatus"` +} + +func (m UserGroupMembership) String() string { + return common.PointerString(m) +} + +// UserGroupMembershipLifecycleStateEnum Enum with underlying type: string +type UserGroupMembershipLifecycleStateEnum string + +// Set of constants representing the allowable values for UserGroupMembershipLifecycleStateEnum +const ( + UserGroupMembershipLifecycleStateCreating UserGroupMembershipLifecycleStateEnum = "CREATING" + UserGroupMembershipLifecycleStateActive UserGroupMembershipLifecycleStateEnum = "ACTIVE" + UserGroupMembershipLifecycleStateInactive UserGroupMembershipLifecycleStateEnum = "INACTIVE" + UserGroupMembershipLifecycleStateDeleting UserGroupMembershipLifecycleStateEnum = "DELETING" + UserGroupMembershipLifecycleStateDeleted UserGroupMembershipLifecycleStateEnum = "DELETED" +) + +var mappingUserGroupMembershipLifecycleState = map[string]UserGroupMembershipLifecycleStateEnum{ + "CREATING": UserGroupMembershipLifecycleStateCreating, + "ACTIVE": UserGroupMembershipLifecycleStateActive, + "INACTIVE": UserGroupMembershipLifecycleStateInactive, + "DELETING": UserGroupMembershipLifecycleStateDeleting, + "DELETED": UserGroupMembershipLifecycleStateDeleted, +} + +// GetUserGroupMembershipLifecycleStateEnumValues Enumerates the set of values for UserGroupMembershipLifecycleStateEnum +func GetUserGroupMembershipLifecycleStateEnumValues() []UserGroupMembershipLifecycleStateEnum { + values := make([]UserGroupMembershipLifecycleStateEnum, 0) + for _, v := range mappingUserGroupMembershipLifecycleState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request.go new file mode 100644 index 000000000..4a13caa2b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request.go @@ -0,0 +1,113 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// WorkRequest The asynchronous API request does not take effect immediately. This request spawns an asynchronous +// workflow to fulfill the request. WorkRequest objects provide visibility for in-progress workflows. +type WorkRequest struct { + + // The OCID of the work request. + Id *string `mandatory:"true" json:"id"` + + // An enum-like description of the type of work the work request is doing. + OperationType WorkRequestOperationTypeEnum `mandatory:"true" json:"operationType"` + + // The current status of the work request. + Status WorkRequestStatusEnum `mandatory:"true" json:"status"` + + // The OCID of the compartment that contains the work request. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The resources this work request affects. + Resources []WorkRequestResource `mandatory:"false" json:"resources"` + + // The errors for work request. + Errors []WorkRequestError `mandatory:"false" json:"errors"` + + // The logs for work request. + Logs []WorkRequestLogEntry `mandatory:"false" json:"logs"` + + // Date and time the work was accepted, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeAccepted *common.SDKTime `mandatory:"false" json:"timeAccepted"` + + // Date and time the work started, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeStarted *common.SDKTime `mandatory:"false" json:"timeStarted"` + + // Date and time the work completed, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeFinished *common.SDKTime `mandatory:"false" json:"timeFinished"` + + // How much progress the operation has made. + PercentComplete *float32 `mandatory:"false" json:"percentComplete"` +} + +func (m WorkRequest) String() string { + return common.PointerString(m) +} + +// WorkRequestOperationTypeEnum Enum with underlying type: string +type WorkRequestOperationTypeEnum string + +// Set of constants representing the allowable values for WorkRequestOperationTypeEnum +const ( + WorkRequestOperationTypeCompartment WorkRequestOperationTypeEnum = "DELETE_COMPARTMENT" + WorkRequestOperationTypeTagDefinition WorkRequestOperationTypeEnum = "DELETE_TAG_DEFINITION" +) + +var mappingWorkRequestOperationType = map[string]WorkRequestOperationTypeEnum{ + "DELETE_COMPARTMENT": WorkRequestOperationTypeCompartment, + "DELETE_TAG_DEFINITION": WorkRequestOperationTypeTagDefinition, +} + +// GetWorkRequestOperationTypeEnumValues Enumerates the set of values for WorkRequestOperationTypeEnum +func GetWorkRequestOperationTypeEnumValues() []WorkRequestOperationTypeEnum { + values := make([]WorkRequestOperationTypeEnum, 0) + for _, v := range mappingWorkRequestOperationType { + values = append(values, v) + } + return values +} + +// WorkRequestStatusEnum Enum with underlying type: string +type WorkRequestStatusEnum string + +// Set of constants representing the allowable values for WorkRequestStatusEnum +const ( + WorkRequestStatusAccepted WorkRequestStatusEnum = "ACCEPTED" + WorkRequestStatusInProgress WorkRequestStatusEnum = "IN_PROGRESS" + WorkRequestStatusFailed WorkRequestStatusEnum = "FAILED" + WorkRequestStatusSucceeded WorkRequestStatusEnum = "SUCCEEDED" + WorkRequestStatusCanceling WorkRequestStatusEnum = "CANCELING" + WorkRequestStatusCanceled WorkRequestStatusEnum = "CANCELED" +) + +var mappingWorkRequestStatus = map[string]WorkRequestStatusEnum{ + "ACCEPTED": WorkRequestStatusAccepted, + "IN_PROGRESS": WorkRequestStatusInProgress, + "FAILED": WorkRequestStatusFailed, + "SUCCEEDED": WorkRequestStatusSucceeded, + "CANCELING": WorkRequestStatusCanceling, + "CANCELED": WorkRequestStatusCanceled, +} + +// GetWorkRequestStatusEnumValues Enumerates the set of values for WorkRequestStatusEnum +func GetWorkRequestStatusEnumValues() []WorkRequestStatusEnum { + values := make([]WorkRequestStatusEnum, 0) + for _, v := range mappingWorkRequestStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_error.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_error.go new file mode 100644 index 000000000..aba149d68 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_error.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// WorkRequestError The error entity. +type WorkRequestError struct { + + // A machine-usable code for the error that occured. + Code *string `mandatory:"true" json:"code"` + + // A human-readable error string. + Message *string `mandatory:"true" json:"message"` + + // Date and time the error happened, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + Timestamp *common.SDKTime `mandatory:"false" json:"timestamp"` +} + +func (m WorkRequestError) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_log_entry.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_log_entry.go new file mode 100644 index 000000000..ce9f78d32 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_log_entry.go @@ -0,0 +1,29 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// WorkRequestLogEntry The log entity. +type WorkRequestLogEntry struct { + + // A human-readable error string. + Message *string `mandatory:"true" json:"message"` + + // Date and time the log was written, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + Timestamp *common.SDKTime `mandatory:"false" json:"timestamp"` +} + +func (m WorkRequestLogEntry) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_resource.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_resource.go new file mode 100644 index 000000000..83a849c86 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_resource.go @@ -0,0 +1,65 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// WorkRequestResource The resource entity. +type WorkRequestResource struct { + + // The resource identifier the work request affects. + Identifier *string `mandatory:"true" json:"identifier"` + + // The resource type the work request is affects. + EntityType *string `mandatory:"true" json:"entityType"` + + // The way in which this resource was affected by the work tracked by the work request. + ActionType WorkRequestResourceActionTypeEnum `mandatory:"true" json:"actionType"` + + // The URI path that the user can do a GET on to access the resource metadata. + EntityUri *string `mandatory:"false" json:"entityUri"` +} + +func (m WorkRequestResource) String() string { + return common.PointerString(m) +} + +// WorkRequestResourceActionTypeEnum Enum with underlying type: string +type WorkRequestResourceActionTypeEnum string + +// Set of constants representing the allowable values for WorkRequestResourceActionTypeEnum +const ( + WorkRequestResourceActionTypeCreated WorkRequestResourceActionTypeEnum = "CREATED" + WorkRequestResourceActionTypeUpdated WorkRequestResourceActionTypeEnum = "UPDATED" + WorkRequestResourceActionTypeDeleted WorkRequestResourceActionTypeEnum = "DELETED" + WorkRequestResourceActionTypeRelated WorkRequestResourceActionTypeEnum = "RELATED" + WorkRequestResourceActionTypeInProgress WorkRequestResourceActionTypeEnum = "IN_PROGRESS" + WorkRequestResourceActionTypeFailed WorkRequestResourceActionTypeEnum = "FAILED" +) + +var mappingWorkRequestResourceActionType = map[string]WorkRequestResourceActionTypeEnum{ + "CREATED": WorkRequestResourceActionTypeCreated, + "UPDATED": WorkRequestResourceActionTypeUpdated, + "DELETED": WorkRequestResourceActionTypeDeleted, + "RELATED": WorkRequestResourceActionTypeRelated, + "IN_PROGRESS": WorkRequestResourceActionTypeInProgress, + "FAILED": WorkRequestResourceActionTypeFailed, +} + +// GetWorkRequestResourceActionTypeEnumValues Enumerates the set of values for WorkRequestResourceActionTypeEnum +func GetWorkRequestResourceActionTypeEnumValues() []WorkRequestResourceActionTypeEnum { + values := make([]WorkRequestResourceActionTypeEnum, 0) + for _, v := range mappingWorkRequestResourceActionType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_summary.go new file mode 100644 index 000000000..d409b92da --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/identity/work_request_summary.go @@ -0,0 +1,109 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Identity and Access Management Service API +// +// APIs for managing users, groups, compartments, and policies. +// + +package identity + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// WorkRequestSummary The work request summary. Tracks the status of the asynchronous operation. +type WorkRequestSummary struct { + + // The OCID of the work request. + Id *string `mandatory:"true" json:"id"` + + // An enum-like description of the type of work the work request is doing. + OperationType WorkRequestSummaryOperationTypeEnum `mandatory:"true" json:"operationType"` + + // The current status of the work request. + Status WorkRequestSummaryStatusEnum `mandatory:"true" json:"status"` + + // The OCID of the compartment that contains the work request. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The resources this work request affects. + Resources []WorkRequestResource `mandatory:"false" json:"resources"` + + // The errors for work request. + Errors []WorkRequestError `mandatory:"false" json:"errors"` + + // Date and time the work was accepted, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeAccepted *common.SDKTime `mandatory:"false" json:"timeAccepted"` + + // Date and time the work started, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeStarted *common.SDKTime `mandatory:"false" json:"timeStarted"` + + // Date and time the work completed, in the format defined by RFC3339. + // Example: `2016-08-25T21:10:29.600Z` + TimeFinished *common.SDKTime `mandatory:"false" json:"timeFinished"` + + // How much progress the operation has made. + PercentComplete *float32 `mandatory:"false" json:"percentComplete"` +} + +func (m WorkRequestSummary) String() string { + return common.PointerString(m) +} + +// WorkRequestSummaryOperationTypeEnum Enum with underlying type: string +type WorkRequestSummaryOperationTypeEnum string + +// Set of constants representing the allowable values for WorkRequestSummaryOperationTypeEnum +const ( + WorkRequestSummaryOperationTypeCompartment WorkRequestSummaryOperationTypeEnum = "DELETE_COMPARTMENT" + WorkRequestSummaryOperationTypeTagDefinition WorkRequestSummaryOperationTypeEnum = "DELETE_TAG_DEFINITION" +) + +var mappingWorkRequestSummaryOperationType = map[string]WorkRequestSummaryOperationTypeEnum{ + "DELETE_COMPARTMENT": WorkRequestSummaryOperationTypeCompartment, + "DELETE_TAG_DEFINITION": WorkRequestSummaryOperationTypeTagDefinition, +} + +// GetWorkRequestSummaryOperationTypeEnumValues Enumerates the set of values for WorkRequestSummaryOperationTypeEnum +func GetWorkRequestSummaryOperationTypeEnumValues() []WorkRequestSummaryOperationTypeEnum { + values := make([]WorkRequestSummaryOperationTypeEnum, 0) + for _, v := range mappingWorkRequestSummaryOperationType { + values = append(values, v) + } + return values +} + +// WorkRequestSummaryStatusEnum Enum with underlying type: string +type WorkRequestSummaryStatusEnum string + +// Set of constants representing the allowable values for WorkRequestSummaryStatusEnum +const ( + WorkRequestSummaryStatusAccepted WorkRequestSummaryStatusEnum = "ACCEPTED" + WorkRequestSummaryStatusInProgress WorkRequestSummaryStatusEnum = "IN_PROGRESS" + WorkRequestSummaryStatusFailed WorkRequestSummaryStatusEnum = "FAILED" + WorkRequestSummaryStatusSucceeded WorkRequestSummaryStatusEnum = "SUCCEEDED" + WorkRequestSummaryStatusCanceling WorkRequestSummaryStatusEnum = "CANCELING" + WorkRequestSummaryStatusCanceled WorkRequestSummaryStatusEnum = "CANCELED" +) + +var mappingWorkRequestSummaryStatus = map[string]WorkRequestSummaryStatusEnum{ + "ACCEPTED": WorkRequestSummaryStatusAccepted, + "IN_PROGRESS": WorkRequestSummaryStatusInProgress, + "FAILED": WorkRequestSummaryStatusFailed, + "SUCCEEDED": WorkRequestSummaryStatusSucceeded, + "CANCELING": WorkRequestSummaryStatusCanceling, + "CANCELED": WorkRequestSummaryStatusCanceled, +} + +// GetWorkRequestSummaryStatusEnumValues Enumerates the set of values for WorkRequestSummaryStatusEnum +func GetWorkRequestSummaryStatusEnumValues() []WorkRequestSummaryStatusEnum { + values := make([]WorkRequestSummaryStatusEnum, 0) + for _, v := range mappingWorkRequestSummaryStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/abort_multipart_upload_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/abort_multipart_upload_request_response.go new file mode 100644 index 000000000..579890af2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/abort_multipart_upload_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// AbortMultipartUploadRequest wrapper for the AbortMultipartUpload operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/AbortMultipartUpload.go.html to see an example of how to use AbortMultipartUploadRequest. +type AbortMultipartUploadRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The name of the object. Avoid entering confidential information. + // Example: `test/object1.log` + ObjectName *string `mandatory:"true" contributesTo:"path" name:"objectName"` + + // The upload ID for a multipart upload. + UploadId *string `mandatory:"true" contributesTo:"query" name:"uploadId"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request AbortMultipartUploadRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request AbortMultipartUploadRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request AbortMultipartUploadRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request AbortMultipartUploadRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// AbortMultipartUploadResponse wrapper for the AbortMultipartUpload operation +type AbortMultipartUploadResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response AbortMultipartUploadResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response AbortMultipartUploadResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/archival_state.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/archival_state.go new file mode 100644 index 000000000..d4ef82683 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/archival_state.go @@ -0,0 +1,37 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +// ArchivalStateEnum Enum with underlying type: string +type ArchivalStateEnum string + +// Set of constants representing the allowable values for ArchivalStateEnum +const ( + ArchivalStateArchived ArchivalStateEnum = "Archived" + ArchivalStateRestoring ArchivalStateEnum = "Restoring" + ArchivalStateRestored ArchivalStateEnum = "Restored" +) + +var mappingArchivalState = map[string]ArchivalStateEnum{ + "Archived": ArchivalStateArchived, + "Restoring": ArchivalStateRestoring, + "Restored": ArchivalStateRestored, +} + +// GetArchivalStateEnumValues Enumerates the set of values for ArchivalStateEnum +func GetArchivalStateEnumValues() []ArchivalStateEnum { + values := make([]ArchivalStateEnum, 0) + for _, v := range mappingArchivalState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/bucket.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/bucket.go new file mode 100644 index 000000000..36fc7a57f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/bucket.go @@ -0,0 +1,210 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Bucket A bucket is a container for storing objects in a compartment within a namespace. A bucket is associated with a single compartment. +// The compartment has policies that indicate what actions a user can perform on a bucket and all the objects in the bucket. For more +// information, see Managing Buckets (https://docs.cloud.oracle.com/Content/Object/Tasks/managingbuckets.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type Bucket struct { + + // The Object Storage namespace in which the bucket resides. + Namespace *string `mandatory:"true" json:"namespace"` + + // The name of the bucket. Avoid entering confidential information. + // Example: my-new-bucket1 + Name *string `mandatory:"true" json:"name"` + + // The compartment ID in which the bucket is authorized. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // Arbitrary string keys and values for user-defined metadata. + Metadata map[string]string `mandatory:"true" json:"metadata"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the user who created the bucket. + CreatedBy *string `mandatory:"true" json:"createdBy"` + + // The date and time the bucket was created, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.29). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The entity tag (ETag) for the bucket. + Etag *string `mandatory:"true" json:"etag"` + + // The type of public access enabled on this bucket. + // A bucket is set to `NoPublicAccess` by default, which only allows an authenticated caller to access the + // bucket and its contents. When `ObjectRead` is enabled on the bucket, public access is allowed for the + // `GetObject`, `HeadObject`, and `ListObjects` operations. When `ObjectReadWithoutList` is enabled on the + // bucket, public access is allowed for the `GetObject` and `HeadObject` operations. + PublicAccessType BucketPublicAccessTypeEnum `mandatory:"false" json:"publicAccessType,omitempty"` + + // The storage tier type assigned to the bucket. A bucket is set to `Standard` tier by default, which means + // objects uploaded or copied to the bucket will be in the standard storage tier. When the `Archive` tier type + // is set explicitly for a bucket, objects uploaded or copied to the bucket will be stored in archive storage. + // The `storageTier` property is immutable after bucket is created. + StorageTier BucketStorageTierEnum `mandatory:"false" json:"storageTier,omitempty"` + + // Whether or not events are emitted for object state changes in this bucket. By default, `objectEventsEnabled` is + // set to `false`. Set `objectEventsEnabled` to `true` to emit events for object state changes. For more information + // about events, see Overview of Events (https://docs.cloud.oracle.com/Content/Events/Concepts/eventsoverview.htm). + ObjectEventsEnabled *bool `mandatory:"false" json:"objectEventsEnabled"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of a master encryption key used to call the Key Management + // service to generate a data encryption key or to encrypt or decrypt a data encryption key. + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` + + // The entity tag (ETag) for the live object lifecycle policy on the bucket. + ObjectLifecyclePolicyEtag *string `mandatory:"false" json:"objectLifecyclePolicyEtag"` + + // The approximate number of objects in the bucket. Count statistics are reported periodically. You will see a + // lag between what is displayed and the actual object count. + ApproximateCount *int64 `mandatory:"false" json:"approximateCount"` + + // The approximate total size in bytes of all objects in the bucket. Size statistics are reported periodically. You will + // see a lag between what is displayed and the actual size of the bucket. + ApproximateSize *int64 `mandatory:"false" json:"approximateSize"` + + // Whether or not this bucket is a replication source. By default, `replicationEnabled` is set to `false`. This will + // be set to 'true' when you create a replication policy for the bucket. + ReplicationEnabled *bool `mandatory:"false" json:"replicationEnabled"` + + // Whether or not this bucket is read only. By default, `isReadOnly` is set to `false`. This will + // be set to 'true' when this bucket is configured as a destination in a replication policy. + IsReadOnly *bool `mandatory:"false" json:"isReadOnly"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the bucket. + Id *string `mandatory:"false" json:"id"` + + // The versioning status on the bucket. A bucket is created with versioning `Disabled` by default. + // For versioning `Enabled`, objects are protected from overwrites and deletes, by maintaining their version history. When versioning is `Suspended`, the previous versions will still remain but new versions will no longer be created when overwitten or deleted. + Versioning BucketVersioningEnum `mandatory:"false" json:"versioning,omitempty"` + + // The auto tiering status on the bucket. A bucket is created with auto tiering `Disabled` by default. + // For auto tiering `InfrequentAccess`, objects are transitioned automatically between the 'Standard' + // and 'InfrequentAccess' tiers based on the access pattern of the objects. + AutoTiering BucketAutoTieringEnum `mandatory:"false" json:"autoTiering,omitempty"` +} + +func (m Bucket) String() string { + return common.PointerString(m) +} + +// BucketPublicAccessTypeEnum Enum with underlying type: string +type BucketPublicAccessTypeEnum string + +// Set of constants representing the allowable values for BucketPublicAccessTypeEnum +const ( + BucketPublicAccessTypeNopublicaccess BucketPublicAccessTypeEnum = "NoPublicAccess" + BucketPublicAccessTypeObjectread BucketPublicAccessTypeEnum = "ObjectRead" + BucketPublicAccessTypeObjectreadwithoutlist BucketPublicAccessTypeEnum = "ObjectReadWithoutList" +) + +var mappingBucketPublicAccessType = map[string]BucketPublicAccessTypeEnum{ + "NoPublicAccess": BucketPublicAccessTypeNopublicaccess, + "ObjectRead": BucketPublicAccessTypeObjectread, + "ObjectReadWithoutList": BucketPublicAccessTypeObjectreadwithoutlist, +} + +// GetBucketPublicAccessTypeEnumValues Enumerates the set of values for BucketPublicAccessTypeEnum +func GetBucketPublicAccessTypeEnumValues() []BucketPublicAccessTypeEnum { + values := make([]BucketPublicAccessTypeEnum, 0) + for _, v := range mappingBucketPublicAccessType { + values = append(values, v) + } + return values +} + +// BucketStorageTierEnum Enum with underlying type: string +type BucketStorageTierEnum string + +// Set of constants representing the allowable values for BucketStorageTierEnum +const ( + BucketStorageTierStandard BucketStorageTierEnum = "Standard" + BucketStorageTierArchive BucketStorageTierEnum = "Archive" +) + +var mappingBucketStorageTier = map[string]BucketStorageTierEnum{ + "Standard": BucketStorageTierStandard, + "Archive": BucketStorageTierArchive, +} + +// GetBucketStorageTierEnumValues Enumerates the set of values for BucketStorageTierEnum +func GetBucketStorageTierEnumValues() []BucketStorageTierEnum { + values := make([]BucketStorageTierEnum, 0) + for _, v := range mappingBucketStorageTier { + values = append(values, v) + } + return values +} + +// BucketVersioningEnum Enum with underlying type: string +type BucketVersioningEnum string + +// Set of constants representing the allowable values for BucketVersioningEnum +const ( + BucketVersioningEnabled BucketVersioningEnum = "Enabled" + BucketVersioningSuspended BucketVersioningEnum = "Suspended" + BucketVersioningDisabled BucketVersioningEnum = "Disabled" +) + +var mappingBucketVersioning = map[string]BucketVersioningEnum{ + "Enabled": BucketVersioningEnabled, + "Suspended": BucketVersioningSuspended, + "Disabled": BucketVersioningDisabled, +} + +// GetBucketVersioningEnumValues Enumerates the set of values for BucketVersioningEnum +func GetBucketVersioningEnumValues() []BucketVersioningEnum { + values := make([]BucketVersioningEnum, 0) + for _, v := range mappingBucketVersioning { + values = append(values, v) + } + return values +} + +// BucketAutoTieringEnum Enum with underlying type: string +type BucketAutoTieringEnum string + +// Set of constants representing the allowable values for BucketAutoTieringEnum +const ( + BucketAutoTieringDisabled BucketAutoTieringEnum = "Disabled" + BucketAutoTieringInfrequentaccess BucketAutoTieringEnum = "InfrequentAccess" +) + +var mappingBucketAutoTiering = map[string]BucketAutoTieringEnum{ + "Disabled": BucketAutoTieringDisabled, + "InfrequentAccess": BucketAutoTieringInfrequentaccess, +} + +// GetBucketAutoTieringEnumValues Enumerates the set of values for BucketAutoTieringEnum +func GetBucketAutoTieringEnumValues() []BucketAutoTieringEnum { + values := make([]BucketAutoTieringEnum, 0) + for _, v := range mappingBucketAutoTiering { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/bucket_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/bucket_summary.go new file mode 100644 index 000000000..a4692a607 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/bucket_summary.go @@ -0,0 +1,55 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// BucketSummary To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type BucketSummary struct { + + // The Object Storage namespace in which the bucket lives. + Namespace *string `mandatory:"true" json:"namespace"` + + // The name of the bucket. Avoid entering confidential information. + // Example: my-new-bucket1 + Name *string `mandatory:"true" json:"name"` + + // The compartment ID in which the bucket is authorized. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the user who created the bucket. + CreatedBy *string `mandatory:"true" json:"createdBy"` + + // The date and time the bucket was created, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.29). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The entity tag (ETag) for the bucket. + Etag *string `mandatory:"true" json:"etag"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` +} + +func (m BucketSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/cancel_work_request_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/cancel_work_request_request_response.go new file mode 100644 index 000000000..a46fea41a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/cancel_work_request_request_response.go @@ -0,0 +1,73 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CancelWorkRequestRequest wrapper for the CancelWorkRequest operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CancelWorkRequest.go.html to see an example of how to use CancelWorkRequestRequest. +type CancelWorkRequestRequest struct { + + // The ID of the asynchronous request. + WorkRequestId *string `mandatory:"true" contributesTo:"path" name:"workRequestId"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CancelWorkRequestRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CancelWorkRequestRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CancelWorkRequestRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CancelWorkRequestRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CancelWorkRequestResponse wrapper for the CancelWorkRequest operation +type CancelWorkRequestResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, + // provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` +} + +func (response CancelWorkRequestResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CancelWorkRequestResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/commit_multipart_upload_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/commit_multipart_upload_details.go new file mode 100644 index 000000000..fe2eaefa2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/commit_multipart_upload_details.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CommitMultipartUploadDetails To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type CommitMultipartUploadDetails struct { + + // The part numbers and entity tags (ETags) for the parts to be committed. + PartsToCommit []CommitMultipartUploadPartDetails `mandatory:"true" json:"partsToCommit"` + + // The part numbers for the parts to be excluded from the completed object. + // Each part created for this upload must be in either partsToExclude or partsToCommit, but cannot be in both. + PartsToExclude []int `mandatory:"false" json:"partsToExclude"` +} + +func (m CommitMultipartUploadDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/commit_multipart_upload_part_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/commit_multipart_upload_part_details.go new file mode 100644 index 000000000..c4df46407 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/commit_multipart_upload_part_details.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CommitMultipartUploadPartDetails To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type CommitMultipartUploadPartDetails struct { + + // The part number for this part. + PartNum *int `mandatory:"true" json:"partNum"` + + // The entity tag (ETag) returned when this part was uploaded. + Etag *string `mandatory:"true" json:"etag"` +} + +func (m CommitMultipartUploadPartDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/commit_multipart_upload_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/commit_multipart_upload_request_response.go new file mode 100644 index 000000000..1c2c54e38 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/commit_multipart_upload_request_response.go @@ -0,0 +1,112 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CommitMultipartUploadRequest wrapper for the CommitMultipartUpload operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CommitMultipartUpload.go.html to see an example of how to use CommitMultipartUploadRequest. +type CommitMultipartUploadRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The name of the object. Avoid entering confidential information. + // Example: `test/object1.log` + ObjectName *string `mandatory:"true" contributesTo:"path" name:"objectName"` + + // The upload ID for a multipart upload. + UploadId *string `mandatory:"true" contributesTo:"query" name:"uploadId"` + + // The part numbers and entity tags (ETags) for the parts you want to commit. + CommitMultipartUploadDetails `contributesTo:"body"` + + // The entity tag (ETag) to match with the ETag of an existing resource. If the specified ETag matches the ETag of + // the existing resource, GET and HEAD requests will return the resource and PUT and POST requests will upload + // the resource. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // The entity tag (ETag) to avoid matching. The only valid value is '*', which indicates that the request should + // fail if the resource already exists. + IfNoneMatch *string `mandatory:"false" contributesTo:"header" name:"if-none-match"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CommitMultipartUploadRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CommitMultipartUploadRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CommitMultipartUploadRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CommitMultipartUploadRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CommitMultipartUploadResponse wrapper for the CommitMultipartUpload operation +type CommitMultipartUploadResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Base-64 representation of the multipart object hash. + // The multipart object hash is calculated by taking the MD5 hashes of the parts passed to this call, + // concatenating the binary representation of those hashes in order of their part numbers, + // and then calculating the MD5 hash of the concatenated values. The multipart object hash is followed + // by a hyphen and the total number of parts (for example, '-6'). + OpcMultipartMd5 *string `presentIn:"header" name:"opc-multipart-md5"` + + // The entity tag (ETag) for the object. + ETag *string `presentIn:"header" name:"etag"` + + // The time the object was last modified, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.29). + LastModified *common.SDKTime `presentIn:"header" name:"last-modified"` + + // VersionId of the newly created object + VersionId *string `presentIn:"header" name:"version-id"` +} + +func (response CommitMultipartUploadResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CommitMultipartUploadResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/copy_object_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/copy_object_details.go new file mode 100644 index 000000000..96c3a441c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/copy_object_details.go @@ -0,0 +1,68 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CopyObjectDetails The parameters required by Object Storage to process a request to copy an object to another bucket. +// To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type CopyObjectDetails struct { + + // The name of the object to be copied. + SourceObjectName *string `mandatory:"true" json:"sourceObjectName"` + + // The destination region the object will be copied to, for example "us-ashburn-1". + DestinationRegion *string `mandatory:"true" json:"destinationRegion"` + + // The destination Object Storage namespace the object will be copied to. + DestinationNamespace *string `mandatory:"true" json:"destinationNamespace"` + + // The destination bucket the object will be copied to. + DestinationBucket *string `mandatory:"true" json:"destinationBucket"` + + // The name of the destination object resulting from the copy operation. Avoid entering confidential information. + DestinationObjectName *string `mandatory:"true" json:"destinationObjectName"` + + // The entity tag (ETag) to match against that of the source object. Used to confirm that the source object + // with a given name is the version of that object storing a specified ETag. + SourceObjectIfMatchETag *string `mandatory:"false" json:"sourceObjectIfMatchETag"` + + // VersionId of the object to copy. If not provided then current version is copied by default. + SourceVersionId *string `mandatory:"false" json:"sourceVersionId"` + + // The entity tag (ETag) to match against that of the destination object (an object intended to be overwritten). + // Used to confirm that the destination object stored under a given name is the version of that object + // storing a specified entity tag. + DestinationObjectIfMatchETag *string `mandatory:"false" json:"destinationObjectIfMatchETag"` + + // The entity tag (ETag) to avoid matching. The only valid value is '*', which indicates that the request should fail + // if the object already exists in the destination bucket. + DestinationObjectIfNoneMatchETag *string `mandatory:"false" json:"destinationObjectIfNoneMatchETag"` + + // Arbitrary string keys and values for the user-defined metadata for the object. Keys must be in + // "opc-meta-*" format. Avoid entering confidential information. Metadata key-value pairs entered + // in this field are assigned to the destination object. If you enter no metadata values, the destination + // object will inherit any existing metadata values associated with the source object. + DestinationObjectMetadata map[string]string `mandatory:"false" json:"destinationObjectMetadata"` + + // The storage tier that the object should be stored in. If not specified, the object will be stored in + // the same storage tier as the bucket. + DestinationObjectStorageTier StorageTierEnum `mandatory:"false" json:"destinationObjectStorageTier,omitempty"` +} + +func (m CopyObjectDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/copy_object_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/copy_object_request_response.go new file mode 100644 index 000000000..7a1ac03ad --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/copy_object_request_response.go @@ -0,0 +1,118 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CopyObjectRequest wrapper for the CopyObject operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CopyObject.go.html to see an example of how to use CopyObjectRequest. +type CopyObjectRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The source and destination of the object to be copied. + CopyObjectDetails `contributesTo:"body"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // The optional header that specifies "AES256" as the encryption algorithm. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerAlgorithm *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-algorithm"` + + // The optional header that specifies the base64-encoded 256-bit encryption key to use to encrypt or + // decrypt the data. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerKey *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-key"` + + // The optional header that specifies the base64-encoded SHA256 hash of the encryption key. This + // value is used to check the integrity of the encryption key. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerKeySha256 *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-key-sha256"` + + // The optional header that specifies "AES256" as the encryption algorithm to use to decrypt the source + // object. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSourceSseCustomerAlgorithm *string `mandatory:"false" contributesTo:"header" name:"opc-source-sse-customer-algorithm"` + + // The optional header that specifies the base64-encoded 256-bit encryption key to use to decrypt + // the source object. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSourceSseCustomerKey *string `mandatory:"false" contributesTo:"header" name:"opc-source-sse-customer-key"` + + // The optional header that specifies the base64-encoded SHA256 hash of the encryption key used to + // decrypt the source object. This value is used to check the integrity of the encryption key. For + // more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSourceSseCustomerKeySha256 *string `mandatory:"false" contributesTo:"header" name:"opc-source-sse-customer-key-sha256"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of a master encryption key used to call the Key + // Management service to generate a data encryption key or to encrypt or decrypt a data encryption key. + OpcSseKmsKeyId *string `mandatory:"false" contributesTo:"header" name:"opc-sse-kms-key-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CopyObjectRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CopyObjectRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CopyObjectRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CopyObjectRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CopyObjectResponse wrapper for the CopyObject operation +type CopyObjectResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the asynchronous request. If you need to contact Oracle about a + // particular request, provide this request ID. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` +} + +func (response CopyObjectResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CopyObjectResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_bucket_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_bucket_details.go new file mode 100644 index 000000000..7c0adc112 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_bucket_details.go @@ -0,0 +1,149 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateBucketDetails To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type CreateBucketDetails struct { + + // The name of the bucket. Valid characters are uppercase or lowercase letters, numbers, hyphens, underscores, and periods. + // Bucket names must be unique within an Object Storage namespace. Avoid entering confidential information. + // example: Example: my-new-bucket1 + Name *string `mandatory:"true" json:"name"` + + // The ID of the compartment in which to create the bucket. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // Arbitrary string, up to 4KB, of keys and values for user-defined metadata. + Metadata map[string]string `mandatory:"false" json:"metadata"` + + // The type of public access enabled on this bucket. + // A bucket is set to `NoPublicAccess` by default, which only allows an authenticated caller to access the + // bucket and its contents. When `ObjectRead` is enabled on the bucket, public access is allowed for the + // `GetObject`, `HeadObject`, and `ListObjects` operations. When `ObjectReadWithoutList` is enabled on the bucket, + // public access is allowed for the `GetObject` and `HeadObject` operations. + PublicAccessType CreateBucketDetailsPublicAccessTypeEnum `mandatory:"false" json:"publicAccessType,omitempty"` + + // The type of storage tier of this bucket. + // A bucket is set to 'Standard' tier by default, which means the bucket will be put in the standard storage tier. + // When 'Archive' tier type is set explicitly, the bucket is put in the Archive Storage tier. The 'storageTier' + // property is immutable after bucket is created. + StorageTier CreateBucketDetailsStorageTierEnum `mandatory:"false" json:"storageTier,omitempty"` + + // Whether or not events are emitted for object state changes in this bucket. By default, `objectEventsEnabled` is + // set to `false`. Set `objectEventsEnabled` to `true` to emit events for object state changes. For more information + // about events, see Overview of Events (https://docs.cloud.oracle.com/Content/Events/Concepts/eventsoverview.htm). + ObjectEventsEnabled *bool `mandatory:"false" json:"objectEventsEnabled"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}}` + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of a master encryption key used to call the Key + // Management service to generate a data encryption key or to encrypt or decrypt a data encryption key. + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` + + // Set the versioning status on the bucket. By default, a bucket is created with versioning `Disabled`. Use this option to enable versioning during bucket creation. Objects in a version enabled bucket are protected from overwrites and deletions. Previous versions of the same object will be available in the bucket. + Versioning CreateBucketDetailsVersioningEnum `mandatory:"false" json:"versioning,omitempty"` + + // Set the auto tiering status on the bucket. By default, a bucket is created with auto tiering `Disabled`. + // Use this option to enable auto tiering during bucket creation. Objects in a bucket with auto tiering set to + // `InfrequentAccess` are transitioned automatically between the 'Standard' and 'InfrequentAccess' + // tiers based on the access pattern of the objects. + AutoTiering BucketAutoTieringEnum `mandatory:"false" json:"autoTiering,omitempty"` +} + +func (m CreateBucketDetails) String() string { + return common.PointerString(m) +} + +// CreateBucketDetailsPublicAccessTypeEnum Enum with underlying type: string +type CreateBucketDetailsPublicAccessTypeEnum string + +// Set of constants representing the allowable values for CreateBucketDetailsPublicAccessTypeEnum +const ( + CreateBucketDetailsPublicAccessTypeNopublicaccess CreateBucketDetailsPublicAccessTypeEnum = "NoPublicAccess" + CreateBucketDetailsPublicAccessTypeObjectread CreateBucketDetailsPublicAccessTypeEnum = "ObjectRead" + CreateBucketDetailsPublicAccessTypeObjectreadwithoutlist CreateBucketDetailsPublicAccessTypeEnum = "ObjectReadWithoutList" +) + +var mappingCreateBucketDetailsPublicAccessType = map[string]CreateBucketDetailsPublicAccessTypeEnum{ + "NoPublicAccess": CreateBucketDetailsPublicAccessTypeNopublicaccess, + "ObjectRead": CreateBucketDetailsPublicAccessTypeObjectread, + "ObjectReadWithoutList": CreateBucketDetailsPublicAccessTypeObjectreadwithoutlist, +} + +// GetCreateBucketDetailsPublicAccessTypeEnumValues Enumerates the set of values for CreateBucketDetailsPublicAccessTypeEnum +func GetCreateBucketDetailsPublicAccessTypeEnumValues() []CreateBucketDetailsPublicAccessTypeEnum { + values := make([]CreateBucketDetailsPublicAccessTypeEnum, 0) + for _, v := range mappingCreateBucketDetailsPublicAccessType { + values = append(values, v) + } + return values +} + +// CreateBucketDetailsStorageTierEnum Enum with underlying type: string +type CreateBucketDetailsStorageTierEnum string + +// Set of constants representing the allowable values for CreateBucketDetailsStorageTierEnum +const ( + CreateBucketDetailsStorageTierStandard CreateBucketDetailsStorageTierEnum = "Standard" + CreateBucketDetailsStorageTierArchive CreateBucketDetailsStorageTierEnum = "Archive" +) + +var mappingCreateBucketDetailsStorageTier = map[string]CreateBucketDetailsStorageTierEnum{ + "Standard": CreateBucketDetailsStorageTierStandard, + "Archive": CreateBucketDetailsStorageTierArchive, +} + +// GetCreateBucketDetailsStorageTierEnumValues Enumerates the set of values for CreateBucketDetailsStorageTierEnum +func GetCreateBucketDetailsStorageTierEnumValues() []CreateBucketDetailsStorageTierEnum { + values := make([]CreateBucketDetailsStorageTierEnum, 0) + for _, v := range mappingCreateBucketDetailsStorageTier { + values = append(values, v) + } + return values +} + +// CreateBucketDetailsVersioningEnum Enum with underlying type: string +type CreateBucketDetailsVersioningEnum string + +// Set of constants representing the allowable values for CreateBucketDetailsVersioningEnum +const ( + CreateBucketDetailsVersioningEnabled CreateBucketDetailsVersioningEnum = "Enabled" + CreateBucketDetailsVersioningDisabled CreateBucketDetailsVersioningEnum = "Disabled" +) + +var mappingCreateBucketDetailsVersioning = map[string]CreateBucketDetailsVersioningEnum{ + "Enabled": CreateBucketDetailsVersioningEnabled, + "Disabled": CreateBucketDetailsVersioningDisabled, +} + +// GetCreateBucketDetailsVersioningEnumValues Enumerates the set of values for CreateBucketDetailsVersioningEnum +func GetCreateBucketDetailsVersioningEnumValues() []CreateBucketDetailsVersioningEnum { + values := make([]CreateBucketDetailsVersioningEnum, 0) + for _, v := range mappingCreateBucketDetailsVersioning { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_bucket_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_bucket_request_response.go new file mode 100644 index 000000000..451d63378 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_bucket_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateBucketRequest wrapper for the CreateBucket operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CreateBucket.go.html to see an example of how to use CreateBucketRequest. +type CreateBucketRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // Request object for creating a bucket. + CreateBucketDetails `contributesTo:"body"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateBucketRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateBucketRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateBucketRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateBucketRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateBucketResponse wrapper for the CreateBucket operation +type CreateBucketResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Bucket instance + Bucket `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The entity tag (ETag) for the bucket that was created. + ETag *string `presentIn:"header" name:"etag"` + + // The full path to the bucket that was created. + Location *string `presentIn:"header" name:"location"` +} + +func (response CreateBucketResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateBucketResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_multipart_upload_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_multipart_upload_details.go new file mode 100644 index 000000000..406fee97f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_multipart_upload_details.go @@ -0,0 +1,69 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateMultipartUploadDetails To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type CreateMultipartUploadDetails struct { + + // The name of the object to which this multi-part upload is targeted. Avoid entering confidential information. + // Example: test/object1.log + Object *string `mandatory:"true" json:"object"` + + // The optional Content-Type header that defines the standard MIME type format of the object to upload. + // Specifying values for this header has no effect on Object Storage behavior. Programs that read the object + // determine what to do based on the value provided. For example, you could use this header to identify and + // perform special operations on text only objects. + ContentType *string `mandatory:"false" json:"contentType"` + + // The optional Content-Language header that defines the content language of the object to upload. Specifying + // values for this header has no effect on Object Storage behavior. Programs that read the object determine what + // to do based on the value provided. For example, you could use this header to identify and differentiate objects + // based on a particular language. + ContentLanguage *string `mandatory:"false" json:"contentLanguage"` + + // The optional Content-Encoding header that defines the content encodings that were applied to the object to + // upload. Specifying values for this header has no effect on Object Storage behavior. Programs that read the + // object determine what to do based on the value provided. For example, you could use this header to determine + // what decoding mechanisms need to be applied to obtain the media-type specified by the Content-Type header of + // the object. + ContentEncoding *string `mandatory:"false" json:"contentEncoding"` + + // The optional Content-Disposition header that defines presentational information for the object to be + // returned in GetObject and HeadObject responses. Specifying values for this header has no effect on Object + // Storage behavior. Programs that read the object determine what to do based on the value provided. + // For example, you could use this header to let users download objects with custom filenames in a browser. + ContentDisposition *string `mandatory:"false" json:"contentDisposition"` + + // The optional Cache-Control header that defines the caching behavior value to be returned in GetObject and + // HeadObject responses. Specifying values for this header has no effect on Object Storage behavior. Programs + // that read the object determine what to do based on the value provided. + // For example, you could use this header to identify objects that require caching restrictions. + CacheControl *string `mandatory:"false" json:"cacheControl"` + + // The storage tier that the object should be stored in. If not specified, the object will be stored in + // the same storage tier as the bucket. + StorageTier StorageTierEnum `mandatory:"false" json:"storageTier,omitempty"` + + // Arbitrary string keys and values for the user-defined metadata for the object. + // Keys must be in "opc-meta-*" format. Avoid entering confidential information. + Metadata map[string]string `mandatory:"false" json:"metadata"` +} + +func (m CreateMultipartUploadDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_multipart_upload_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_multipart_upload_request_response.go new file mode 100644 index 000000000..c275ae2bf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_multipart_upload_request_response.go @@ -0,0 +1,113 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateMultipartUploadRequest wrapper for the CreateMultipartUpload operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CreateMultipartUpload.go.html to see an example of how to use CreateMultipartUploadRequest. +type CreateMultipartUploadRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // Request object for creating a multipart upload. + CreateMultipartUploadDetails `contributesTo:"body"` + + // The entity tag (ETag) to match with the ETag of an existing resource. If the specified ETag matches the ETag of + // the existing resource, GET and HEAD requests will return the resource and PUT and POST requests will upload + // the resource. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // The entity tag (ETag) to avoid matching. The only valid value is '*', which indicates that the request should + // fail if the resource already exists. + IfNoneMatch *string `mandatory:"false" contributesTo:"header" name:"if-none-match"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // The optional header that specifies "AES256" as the encryption algorithm. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerAlgorithm *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-algorithm"` + + // The optional header that specifies the base64-encoded 256-bit encryption key to use to encrypt or + // decrypt the data. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerKey *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-key"` + + // The optional header that specifies the base64-encoded SHA256 hash of the encryption key. This + // value is used to check the integrity of the encryption key. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerKeySha256 *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-key-sha256"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of a master encryption key used to call the Key + // Management service to generate a data encryption key or to encrypt or decrypt a data encryption key. + OpcSseKmsKeyId *string `mandatory:"false" contributesTo:"header" name:"opc-sse-kms-key-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateMultipartUploadRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateMultipartUploadRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateMultipartUploadRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateMultipartUploadRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateMultipartUploadResponse wrapper for the CreateMultipartUpload operation +type CreateMultipartUploadResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The MultipartUpload instance + MultipartUpload `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The full path to the new upload. + Location *string `presentIn:"header" name:"location"` +} + +func (response CreateMultipartUploadResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateMultipartUploadResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_preauthenticated_request_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_preauthenticated_request_details.go new file mode 100644 index 000000000..064ca3521 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_preauthenticated_request_details.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreatePreauthenticatedRequestDetails The representation of CreatePreauthenticatedRequestDetails +type CreatePreauthenticatedRequestDetails struct { + + // A user-specified name for the pre-authenticated request. Names can be helpful in managing pre-authenticated requests. + // Avoid entering confidential information. + Name *string `mandatory:"true" json:"name"` + + // The operation that can be performed on this resource. + AccessType CreatePreauthenticatedRequestDetailsAccessTypeEnum `mandatory:"true" json:"accessType"` + + // The expiration date for the pre-authenticated request as per RFC 3339 (https://tools.ietf.org/html/rfc3339). + // After this date the pre-authenticated request will no longer be valid. + TimeExpires *common.SDKTime `mandatory:"true" json:"timeExpires"` + + // Specifies whether a list operation is allowed on a PAR with accessType "AnyObjectRead" or "AnyObjectReadWrite". + // Deny: Prevents the user from performing a list operation. + // ListObjects: Authorizes the user to perform a list operation. + BucketListingAction PreauthenticatedRequestBucketListingActionEnum `mandatory:"false" json:"bucketListingAction,omitempty"` + + // The name of the object that is being granted access to by the pre-authenticated request. Avoid entering confidential + // information. The object name can be null and if so, the pre-authenticated request grants access to the entire bucket + // if the access type allows that. The object name can be a prefix as well, in that case pre-authenticated request + // grants access to all the objects within the bucket starting with that prefix provided that we have the correct access type. + ObjectName *string `mandatory:"false" json:"objectName"` +} + +func (m CreatePreauthenticatedRequestDetails) String() string { + return common.PointerString(m) +} + +// CreatePreauthenticatedRequestDetailsAccessTypeEnum Enum with underlying type: string +type CreatePreauthenticatedRequestDetailsAccessTypeEnum string + +// Set of constants representing the allowable values for CreatePreauthenticatedRequestDetailsAccessTypeEnum +const ( + CreatePreauthenticatedRequestDetailsAccessTypeObjectread CreatePreauthenticatedRequestDetailsAccessTypeEnum = "ObjectRead" + CreatePreauthenticatedRequestDetailsAccessTypeObjectwrite CreatePreauthenticatedRequestDetailsAccessTypeEnum = "ObjectWrite" + CreatePreauthenticatedRequestDetailsAccessTypeObjectreadwrite CreatePreauthenticatedRequestDetailsAccessTypeEnum = "ObjectReadWrite" + CreatePreauthenticatedRequestDetailsAccessTypeAnyobjectwrite CreatePreauthenticatedRequestDetailsAccessTypeEnum = "AnyObjectWrite" + CreatePreauthenticatedRequestDetailsAccessTypeAnyobjectread CreatePreauthenticatedRequestDetailsAccessTypeEnum = "AnyObjectRead" + CreatePreauthenticatedRequestDetailsAccessTypeAnyobjectreadwrite CreatePreauthenticatedRequestDetailsAccessTypeEnum = "AnyObjectReadWrite" +) + +var mappingCreatePreauthenticatedRequestDetailsAccessType = map[string]CreatePreauthenticatedRequestDetailsAccessTypeEnum{ + "ObjectRead": CreatePreauthenticatedRequestDetailsAccessTypeObjectread, + "ObjectWrite": CreatePreauthenticatedRequestDetailsAccessTypeObjectwrite, + "ObjectReadWrite": CreatePreauthenticatedRequestDetailsAccessTypeObjectreadwrite, + "AnyObjectWrite": CreatePreauthenticatedRequestDetailsAccessTypeAnyobjectwrite, + "AnyObjectRead": CreatePreauthenticatedRequestDetailsAccessTypeAnyobjectread, + "AnyObjectReadWrite": CreatePreauthenticatedRequestDetailsAccessTypeAnyobjectreadwrite, +} + +// GetCreatePreauthenticatedRequestDetailsAccessTypeEnumValues Enumerates the set of values for CreatePreauthenticatedRequestDetailsAccessTypeEnum +func GetCreatePreauthenticatedRequestDetailsAccessTypeEnumValues() []CreatePreauthenticatedRequestDetailsAccessTypeEnum { + values := make([]CreatePreauthenticatedRequestDetailsAccessTypeEnum, 0) + for _, v := range mappingCreatePreauthenticatedRequestDetailsAccessType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_preauthenticated_request_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_preauthenticated_request_request_response.go new file mode 100644 index 000000000..d2cacb4b1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_preauthenticated_request_request_response.go @@ -0,0 +1,83 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreatePreauthenticatedRequestRequest wrapper for the CreatePreauthenticatedRequest operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CreatePreauthenticatedRequest.go.html to see an example of how to use CreatePreauthenticatedRequestRequest. +type CreatePreauthenticatedRequestRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // Information needed to create the pre-authenticated request. + CreatePreauthenticatedRequestDetails `contributesTo:"body"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreatePreauthenticatedRequestRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreatePreauthenticatedRequestRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreatePreauthenticatedRequestRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreatePreauthenticatedRequestRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreatePreauthenticatedRequestResponse wrapper for the CreatePreauthenticatedRequest operation +type CreatePreauthenticatedRequestResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The PreauthenticatedRequest instance + PreauthenticatedRequest `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response CreatePreauthenticatedRequestResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreatePreauthenticatedRequestResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_replication_policy_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_replication_policy_details.go new file mode 100644 index 000000000..5283b3557 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_replication_policy_details.go @@ -0,0 +1,34 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateReplicationPolicyDetails The details to create a replication policy. +type CreateReplicationPolicyDetails struct { + + // The name of the policy. Avoid entering confidential information. + Name *string `mandatory:"true" json:"name"` + + // The destination region to replicate to, for example "us-ashburn-1". + DestinationRegionName *string `mandatory:"true" json:"destinationRegionName"` + + // The bucket to replicate to in the destination region. Replication policy creation does not automatically + // create a destination bucket. Create the destination bucket before creating the policy. + DestinationBucketName *string `mandatory:"true" json:"destinationBucketName"` +} + +func (m CreateReplicationPolicyDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_replication_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_replication_policy_request_response.go new file mode 100644 index 000000000..9b9e1ea1b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_replication_policy_request_response.go @@ -0,0 +1,83 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateReplicationPolicyRequest wrapper for the CreateReplicationPolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CreateReplicationPolicy.go.html to see an example of how to use CreateReplicationPolicyRequest. +type CreateReplicationPolicyRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The replication policy. + CreateReplicationPolicyDetails `contributesTo:"body"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateReplicationPolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateReplicationPolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateReplicationPolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateReplicationPolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateReplicationPolicyResponse wrapper for the CreateReplicationPolicy operation +type CreateReplicationPolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ReplicationPolicy instance + ReplicationPolicy `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, + // provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` +} + +func (response CreateReplicationPolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateReplicationPolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_retention_rule_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_retention_rule_details.go new file mode 100644 index 000000000..62b95d4bf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_retention_rule_details.go @@ -0,0 +1,36 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// CreateRetentionRuleDetails The details to create a retention rule. +type CreateRetentionRuleDetails struct { + + // A user-specified name for the retention rule. Names can be helpful in identifying retention rules. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + Duration *Duration `mandatory:"false" json:"duration"` + + // The date and time as per RFC 3339 (https://tools.ietf.org/html/rfc3339) after which this rule is locked + // and can only be deleted by deleting the bucket. Once a rule is locked, only increases in the duration are + // allowed and no other properties can be changed. This property cannot be updated for rules that are in a + // locked state. Specifying it when a duration is not specified is considered an error. + TimeRuleLocked *common.SDKTime `mandatory:"false" json:"timeRuleLocked"` +} + +func (m CreateRetentionRuleDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_retention_rule_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_retention_rule_request_response.go new file mode 100644 index 000000000..4f43439da --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/create_retention_rule_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// CreateRetentionRuleRequest wrapper for the CreateRetentionRule operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CreateRetentionRule.go.html to see an example of how to use CreateRetentionRuleRequest. +type CreateRetentionRuleRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The retention rule to create for the bucket. + CreateRetentionRuleDetails `contributesTo:"body"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request CreateRetentionRuleRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request CreateRetentionRuleRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request CreateRetentionRuleRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request CreateRetentionRuleRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// CreateRetentionRuleResponse wrapper for the CreateRetentionRule operation +type CreateRetentionRuleResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The RetentionRule instance + RetentionRule `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // The entity tag (ETag) for the retention rule that was created. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response CreateRetentionRuleResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response CreateRetentionRuleResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_bucket_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_bucket_request_response.go new file mode 100644 index 000000000..16a13d46f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_bucket_request_response.go @@ -0,0 +1,82 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteBucketRequest wrapper for the DeleteBucket operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/DeleteBucket.go.html to see an example of how to use DeleteBucketRequest. +type DeleteBucketRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The entity tag (ETag) to match with the ETag of an existing resource. If the specified ETag matches the ETag of + // the existing resource, GET and HEAD requests will return the resource and PUT and POST requests will upload + // the resource. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteBucketRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteBucketRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteBucketRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteBucketRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteBucketResponse wrapper for the DeleteBucket operation +type DeleteBucketResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteBucketResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteBucketResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_object_lifecycle_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_object_lifecycle_policy_request_response.go new file mode 100644 index 000000000..f2c8c3b25 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_object_lifecycle_policy_request_response.go @@ -0,0 +1,82 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteObjectLifecyclePolicyRequest wrapper for the DeleteObjectLifecyclePolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/DeleteObjectLifecyclePolicy.go.html to see an example of how to use DeleteObjectLifecyclePolicyRequest. +type DeleteObjectLifecyclePolicyRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // The entity tag (ETag) to match with the ETag of an existing resource. If the specified ETag matches the ETag of + // the existing resource, GET and HEAD requests will return the resource and PUT and POST requests will upload + // the resource. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteObjectLifecyclePolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteObjectLifecyclePolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteObjectLifecyclePolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteObjectLifecyclePolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteObjectLifecyclePolicyResponse wrapper for the DeleteObjectLifecyclePolicy operation +type DeleteObjectLifecyclePolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, + // provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` +} + +func (response DeleteObjectLifecyclePolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteObjectLifecyclePolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_object_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_object_request_response.go new file mode 100644 index 000000000..719162c18 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_object_request_response.go @@ -0,0 +1,99 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteObjectRequest wrapper for the DeleteObject operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/DeleteObject.go.html to see an example of how to use DeleteObjectRequest. +type DeleteObjectRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The name of the object. Avoid entering confidential information. + // Example: `test/object1.log` + ObjectName *string `mandatory:"true" contributesTo:"path" name:"objectName"` + + // The entity tag (ETag) to match with the ETag of an existing resource. If the specified ETag matches the ETag of + // the existing resource, GET and HEAD requests will return the resource and PUT and POST requests will upload + // the resource. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // VersionId used to identify a particular version of the object + VersionId *string `mandatory:"false" contributesTo:"query" name:"versionId"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteObjectRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteObjectRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteObjectRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteObjectRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteObjectResponse wrapper for the DeleteObject operation +type DeleteObjectResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The time the object was deleted, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.29). + LastModified *common.SDKTime `presentIn:"header" name:"last-modified"` + + // The `versionId` of the delete marker created as a result of the DELETE Object. + // If the request contains a specific `versionId`, then this response header will be the same as the requested `versionId` of the object that was deleted. + VersionId *string `presentIn:"header" name:"version-id"` + + // This is `true` if the deleted object is a delete marker, otherwise `false` + IsDeleteMarker *bool `presentIn:"header" name:"is-delete-marker"` +} + +func (response DeleteObjectResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteObjectResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_preauthenticated_request_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_preauthenticated_request_request_response.go new file mode 100644 index 000000000..577689004 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_preauthenticated_request_request_response.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeletePreauthenticatedRequestRequest wrapper for the DeletePreauthenticatedRequest operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/DeletePreauthenticatedRequest.go.html to see an example of how to use DeletePreauthenticatedRequestRequest. +type DeletePreauthenticatedRequestRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The unique identifier for the pre-authenticated request. This can be used to manage operations against + // the pre-authenticated request, such as GET or DELETE. + ParId *string `mandatory:"true" contributesTo:"path" name:"parId"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeletePreauthenticatedRequestRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeletePreauthenticatedRequestRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeletePreauthenticatedRequestRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeletePreauthenticatedRequestRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeletePreauthenticatedRequestResponse wrapper for the DeletePreauthenticatedRequest operation +type DeletePreauthenticatedRequestResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeletePreauthenticatedRequestResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeletePreauthenticatedRequestResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_replication_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_replication_policy_request_response.go new file mode 100644 index 000000000..9a53cba40 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_replication_policy_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteReplicationPolicyRequest wrapper for the DeleteReplicationPolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/DeleteReplicationPolicy.go.html to see an example of how to use DeleteReplicationPolicyRequest. +type DeleteReplicationPolicyRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The ID of the replication policy. + ReplicationId *string `mandatory:"true" contributesTo:"path" name:"replicationId"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteReplicationPolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteReplicationPolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteReplicationPolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteReplicationPolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteReplicationPolicyResponse wrapper for the DeleteReplicationPolicy operation +type DeleteReplicationPolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, + // provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` +} + +func (response DeleteReplicationPolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteReplicationPolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_retention_rule_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_retention_rule_request_response.go new file mode 100644 index 000000000..f0ffbaec8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/delete_retention_rule_request_response.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// DeleteRetentionRuleRequest wrapper for the DeleteRetentionRule operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/DeleteRetentionRule.go.html to see an example of how to use DeleteRetentionRuleRequest. +type DeleteRetentionRuleRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The ID of the retention rule. + RetentionRuleId *string `mandatory:"true" contributesTo:"path" name:"retentionRuleId"` + + // The entity tag (ETag) to match with the ETag of an existing resource. If the specified ETag matches the ETag of + // the existing resource, GET and HEAD requests will return the resource and PUT and POST requests will upload + // the resource. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request DeleteRetentionRuleRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request DeleteRetentionRuleRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request DeleteRetentionRuleRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request DeleteRetentionRuleRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// DeleteRetentionRuleResponse wrapper for the DeleteRetentionRule operation +type DeleteRetentionRuleResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response DeleteRetentionRuleResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response DeleteRetentionRuleResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/duration.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/duration.go new file mode 100644 index 000000000..52e5476a1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/duration.go @@ -0,0 +1,56 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// Duration The amount of time that objects in the bucket should be preserved for and which is calculated in relation to +// each object's Last-Modified timestamp. If duration is not present, then there is no time limit and the objects +// in the bucket will be preserved indefinitely. +type Duration struct { + + // The timeAmount is interpreted in units defined by the timeUnit parameter, and is calculated in relation + // to each object's Last-Modified timestamp. + TimeAmount *int64 `mandatory:"true" json:"timeAmount"` + + // The unit that should be used to interpret timeAmount. + TimeUnit DurationTimeUnitEnum `mandatory:"true" json:"timeUnit"` +} + +func (m Duration) String() string { + return common.PointerString(m) +} + +// DurationTimeUnitEnum Enum with underlying type: string +type DurationTimeUnitEnum string + +// Set of constants representing the allowable values for DurationTimeUnitEnum +const ( + DurationTimeUnitYears DurationTimeUnitEnum = "YEARS" + DurationTimeUnitDays DurationTimeUnitEnum = "DAYS" +) + +var mappingDurationTimeUnit = map[string]DurationTimeUnitEnum{ + "YEARS": DurationTimeUnitYears, + "DAYS": DurationTimeUnitDays, +} + +// GetDurationTimeUnitEnumValues Enumerates the set of values for DurationTimeUnitEnum +func GetDurationTimeUnitEnumValues() []DurationTimeUnitEnum { + values := make([]DurationTimeUnitEnum, 0) + for _, v := range mappingDurationTimeUnit { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_bucket_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_bucket_request_response.go new file mode 100644 index 000000000..5c6bdc6e7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_bucket_request_response.go @@ -0,0 +1,130 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetBucketRequest wrapper for the GetBucket operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetBucket.go.html to see an example of how to use GetBucketRequest. +type GetBucketRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The entity tag (ETag) to match with the ETag of an existing resource. If the specified ETag matches the ETag of + // the existing resource, GET and HEAD requests will return the resource and PUT and POST requests will upload + // the resource. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // The entity tag (ETag) to avoid matching. Wildcards ('*') are not allowed. If the specified ETag does not + // match the ETag of the existing resource, the request returns the expected response. If the ETag matches + // the ETag of the existing resource, the request returns an HTTP 304 status without a response body. + IfNoneMatch *string `mandatory:"false" contributesTo:"header" name:"if-none-match"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Bucket summary includes the 'namespace', 'name', 'compartmentId', 'createdBy', 'timeCreated', + // and 'etag' fields. This parameter can also include 'approximateCount' (approximate number of objects), 'approximateSize' + // (total approximate size in bytes of all objects) and 'autoTiering' (state of auto tiering on the bucket). + // For example 'approximateCount,approximateSize,autoTiering'. + Fields []GetBucketFieldsEnum `contributesTo:"query" name:"fields" omitEmpty:"true" collectionFormat:"csv"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetBucketRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetBucketRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetBucketRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetBucketRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetBucketResponse wrapper for the GetBucket operation +type GetBucketResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Bucket instance + Bucket `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The current entity tag (ETag) for the bucket. + ETag *string `presentIn:"header" name:"etag"` + + // Flag to indicate whether or not the object was modified. If this is true, + // the getter for the object itself will return null. Callers should check this + // if they specified one of the request params that might result in a conditional + // response (like 'if-match'/'if-none-match'). + IsNotModified bool +} + +func (response GetBucketResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetBucketResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// GetBucketFieldsEnum Enum with underlying type: string +type GetBucketFieldsEnum string + +// Set of constants representing the allowable values for GetBucketFieldsEnum +const ( + GetBucketFieldsApproximatecount GetBucketFieldsEnum = "approximateCount" + GetBucketFieldsApproximatesize GetBucketFieldsEnum = "approximateSize" + GetBucketFieldsAutotiering GetBucketFieldsEnum = "autoTiering" +) + +var mappingGetBucketFields = map[string]GetBucketFieldsEnum{ + "approximateCount": GetBucketFieldsApproximatecount, + "approximateSize": GetBucketFieldsApproximatesize, + "autoTiering": GetBucketFieldsAutotiering, +} + +// GetGetBucketFieldsEnumValues Enumerates the set of values for GetBucketFieldsEnum +func GetGetBucketFieldsEnumValues() []GetBucketFieldsEnum { + values := make([]GetBucketFieldsEnum, 0) + for _, v := range mappingGetBucketFields { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_namespace_metadata_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_namespace_metadata_request_response.go new file mode 100644 index 000000000..3d39425fa --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_namespace_metadata_request_response.go @@ -0,0 +1,76 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetNamespaceMetadataRequest wrapper for the GetNamespaceMetadata operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetNamespaceMetadata.go.html to see an example of how to use GetNamespaceMetadataRequest. +type GetNamespaceMetadataRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetNamespaceMetadataRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetNamespaceMetadataRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetNamespaceMetadataRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetNamespaceMetadataRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetNamespaceMetadataResponse wrapper for the GetNamespaceMetadata operation +type GetNamespaceMetadataResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The NamespaceMetadata instance + NamespaceMetadata `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetNamespaceMetadataResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetNamespaceMetadataResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_namespace_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_namespace_request_response.go new file mode 100644 index 000000000..52d087886 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_namespace_request_response.go @@ -0,0 +1,70 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetNamespaceRequest wrapper for the GetNamespace operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetNamespace.go.html to see an example of how to use GetNamespaceRequest. +type GetNamespaceRequest struct { + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // This is an optional field representing either the tenancy OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) or the compartment + // OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) within the tenancy whose Object Storage namespace is to be retrieved. + CompartmentId *string `mandatory:"false" contributesTo:"query" name:"compartmentId"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetNamespaceRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetNamespaceRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetNamespaceRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetNamespaceRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetNamespaceResponse wrapper for the GetNamespace operation +type GetNamespaceResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The string instance + Value *string `presentIn:"body"` +} + +func (response GetNamespaceResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetNamespaceResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_object_lifecycle_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_object_lifecycle_policy_request_response.go new file mode 100644 index 000000000..934f0b837 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_object_lifecycle_policy_request_response.go @@ -0,0 +1,83 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetObjectLifecyclePolicyRequest wrapper for the GetObjectLifecyclePolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetObjectLifecyclePolicy.go.html to see an example of how to use GetObjectLifecyclePolicyRequest. +type GetObjectLifecyclePolicyRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetObjectLifecyclePolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetObjectLifecyclePolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetObjectLifecyclePolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetObjectLifecyclePolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetObjectLifecyclePolicyResponse wrapper for the GetObjectLifecyclePolicy operation +type GetObjectLifecyclePolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ObjectLifecyclePolicy instance + ObjectLifecyclePolicy `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, + // provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // The entity tag (ETag) for the object lifecycle policy. + ETag *string `presentIn:"header" name:"etag"` +} + +func (response GetObjectLifecyclePolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetObjectLifecyclePolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_object_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_object_request_response.go new file mode 100644 index 000000000..f01455cc4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_object_request_response.go @@ -0,0 +1,247 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "io" + "net/http" +) + +// GetObjectRequest wrapper for the GetObject operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetObject.go.html to see an example of how to use GetObjectRequest. +type GetObjectRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The name of the object. Avoid entering confidential information. + // Example: `test/object1.log` + ObjectName *string `mandatory:"true" contributesTo:"path" name:"objectName"` + + // VersionId used to identify a particular version of the object + VersionId *string `mandatory:"false" contributesTo:"query" name:"versionId"` + + // The entity tag (ETag) to match with the ETag of an existing resource. If the specified ETag matches the ETag of + // the existing resource, GET and HEAD requests will return the resource and PUT and POST requests will upload + // the resource. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // The entity tag (ETag) to avoid matching. Wildcards ('*') are not allowed. If the specified ETag does not + // match the ETag of the existing resource, the request returns the expected response. If the ETag matches + // the ETag of the existing resource, the request returns an HTTP 304 status without a response body. + IfNoneMatch *string `mandatory:"false" contributesTo:"header" name:"if-none-match"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Optional byte range to fetch, as described in RFC 7233 (https://tools.ietf.org/html/rfc7233#section-2.1). + // Note that only a single range of bytes is supported. + Range *string `mandatory:"false" contributesTo:"header" name:"range"` + + // The optional header that specifies "AES256" as the encryption algorithm. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerAlgorithm *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-algorithm"` + + // The optional header that specifies the base64-encoded 256-bit encryption key to use to encrypt or + // decrypt the data. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerKey *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-key"` + + // The optional header that specifies the base64-encoded SHA256 hash of the encryption key. This + // value is used to check the integrity of the encryption key. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerKeySha256 *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-key-sha256"` + + // Specify this query parameter to override the value of the Content-Disposition response header in the GetObject response. + HttpResponseContentDisposition *string `mandatory:"false" contributesTo:"query" name:"httpResponseContentDisposition"` + + // Specify this query parameter to override the Cache-Control response header in the GetObject response. + HttpResponseCacheControl *string `mandatory:"false" contributesTo:"query" name:"httpResponseCacheControl"` + + // Specify this query parameter to override the Content-Type response header in the GetObject response. + HttpResponseContentType *string `mandatory:"false" contributesTo:"query" name:"httpResponseContentType"` + + // Specify this query parameter to override the Content-Language response header in the GetObject response. + HttpResponseContentLanguage *string `mandatory:"false" contributesTo:"query" name:"httpResponseContentLanguage"` + + // Specify this query parameter to override the Content-Encoding response header in the GetObject response. + HttpResponseContentEncoding *string `mandatory:"false" contributesTo:"query" name:"httpResponseContentEncoding"` + + // Specify this query parameter to override the Expires response header in the GetObject response. + HttpResponseExpires *string `mandatory:"false" contributesTo:"query" name:"httpResponseExpires"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetObjectRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetObjectRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetObjectRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetObjectRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetObjectResponse wrapper for the GetObject operation +type GetObjectResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The io.ReadCloser instance + Content io.ReadCloser `presentIn:"body" encoding:"binary"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The entity tag (ETag) for the object. + ETag *string `presentIn:"header" name:"etag"` + + // The user-defined metadata for the object. + OpcMeta map[string]string `presentIn:"header-collection" prefix:"opc-meta-"` + + // The object size in bytes. + ContentLength *int64 `presentIn:"header" name:"content-length"` + + // Content-Range header for range requests, per RFC 7233 (https://tools.ietf.org/html/rfc7233#section-4.2). + ContentRange *string `presentIn:"header" name:"content-range"` + + // Content-MD5 header, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.15). + // Unavailable for objects uploaded using multipart upload. + ContentMd5 *string `presentIn:"header" name:"content-md5"` + + // Only applicable to objects uploaded using multipart upload. + // Base-64 representation of the multipart object hash. + // The multipart object hash is calculated by taking the MD5 hashes of the parts, + // concatenating the binary representation of those hashes in order of their part numbers, + // and then calculating the MD5 hash of the concatenated values. + OpcMultipartMd5 *string `presentIn:"header" name:"opc-multipart-md5"` + + // Content-Type header, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.17). + ContentType *string `presentIn:"header" name:"content-type"` + + // Content-Language header, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.12). + ContentLanguage *string `presentIn:"header" name:"content-language"` + + // Content-Encoding header, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.11). + ContentEncoding *string `presentIn:"header" name:"content-encoding"` + + // Cache-Control header, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.9). + CacheControl *string `presentIn:"header" name:"cache-control"` + + // Content-Disposition header, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-19.5.1). + ContentDisposition *string `presentIn:"header" name:"content-disposition"` + + // The object modification time, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.29). + LastModified *common.SDKTime `presentIn:"header" name:"last-modified"` + + // The storage tier that the object is stored in. + StorageTier GetObjectStorageTierEnum `presentIn:"header" name:"storage-tier"` + + // Archival state of an object. This field is set only for objects in Archive tier. + ArchivalState GetObjectArchivalStateEnum `presentIn:"header" name:"archival-state"` + + // Time that the object is returned to the archived state. This field is only present for restored objects. + TimeOfArchival *common.SDKTime `presentIn:"header" name:"time-of-archival"` + + // VersionId of the object requested + VersionId *string `presentIn:"header" name:"version-id"` + + // The date and time after which the object is no longer cached by a browser, proxy, or other caching entity. See + // RFC 2616 (https://tools.ietf.org/rfc/rfc2616#section-14.21). + Expires *common.SDKTime `presentIn:"header" name:"expires"` + + // Flag to indicate whether or not the object was modified. If this is true, + // the getter for the object itself will return null. Callers should check this + // if they specified one of the request params that might result in a conditional + // response (like 'if-match'/'if-none-match'). + IsNotModified bool +} + +func (response GetObjectResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetObjectResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// GetObjectStorageTierEnum Enum with underlying type: string +type GetObjectStorageTierEnum string + +// Set of constants representing the allowable values for GetObjectStorageTierEnum +const ( + GetObjectStorageTierStandard GetObjectStorageTierEnum = "Standard" + GetObjectStorageTierInfrequentaccess GetObjectStorageTierEnum = "InfrequentAccess" + GetObjectStorageTierArchive GetObjectStorageTierEnum = "Archive" +) + +var mappingGetObjectStorageTier = map[string]GetObjectStorageTierEnum{ + "Standard": GetObjectStorageTierStandard, + "InfrequentAccess": GetObjectStorageTierInfrequentaccess, + "Archive": GetObjectStorageTierArchive, +} + +// GetGetObjectStorageTierEnumValues Enumerates the set of values for GetObjectStorageTierEnum +func GetGetObjectStorageTierEnumValues() []GetObjectStorageTierEnum { + values := make([]GetObjectStorageTierEnum, 0) + for _, v := range mappingGetObjectStorageTier { + values = append(values, v) + } + return values +} + +// GetObjectArchivalStateEnum Enum with underlying type: string +type GetObjectArchivalStateEnum string + +// Set of constants representing the allowable values for GetObjectArchivalStateEnum +const ( + GetObjectArchivalStateArchived GetObjectArchivalStateEnum = "Archived" + GetObjectArchivalStateRestoring GetObjectArchivalStateEnum = "Restoring" + GetObjectArchivalStateRestored GetObjectArchivalStateEnum = "Restored" +) + +var mappingGetObjectArchivalState = map[string]GetObjectArchivalStateEnum{ + "Archived": GetObjectArchivalStateArchived, + "Restoring": GetObjectArchivalStateRestoring, + "Restored": GetObjectArchivalStateRestored, +} + +// GetGetObjectArchivalStateEnumValues Enumerates the set of values for GetObjectArchivalStateEnum +func GetGetObjectArchivalStateEnumValues() []GetObjectArchivalStateEnum { + values := make([]GetObjectArchivalStateEnum, 0) + for _, v := range mappingGetObjectArchivalState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_preauthenticated_request_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_preauthenticated_request_request_response.go new file mode 100644 index 000000000..6a837a732 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_preauthenticated_request_request_response.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetPreauthenticatedRequestRequest wrapper for the GetPreauthenticatedRequest operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetPreauthenticatedRequest.go.html to see an example of how to use GetPreauthenticatedRequestRequest. +type GetPreauthenticatedRequestRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The unique identifier for the pre-authenticated request. This can be used to manage operations against + // the pre-authenticated request, such as GET or DELETE. + ParId *string `mandatory:"true" contributesTo:"path" name:"parId"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetPreauthenticatedRequestRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetPreauthenticatedRequestRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetPreauthenticatedRequestRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetPreauthenticatedRequestRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetPreauthenticatedRequestResponse wrapper for the GetPreauthenticatedRequest operation +type GetPreauthenticatedRequestResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The PreauthenticatedRequestSummary instance + PreauthenticatedRequestSummary `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetPreauthenticatedRequestResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetPreauthenticatedRequestResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_replication_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_replication_policy_request_response.go new file mode 100644 index 000000000..7eabc0c06 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_replication_policy_request_response.go @@ -0,0 +1,83 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetReplicationPolicyRequest wrapper for the GetReplicationPolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetReplicationPolicy.go.html to see an example of how to use GetReplicationPolicyRequest. +type GetReplicationPolicyRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The ID of the replication policy. + ReplicationId *string `mandatory:"true" contributesTo:"path" name:"replicationId"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetReplicationPolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetReplicationPolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetReplicationPolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetReplicationPolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetReplicationPolicyResponse wrapper for the GetReplicationPolicy operation +type GetReplicationPolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ReplicationPolicy instance + ReplicationPolicy `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, + // provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` +} + +func (response GetReplicationPolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetReplicationPolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_retention_rule_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_retention_rule_request_response.go new file mode 100644 index 000000000..7508f7198 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_retention_rule_request_response.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetRetentionRuleRequest wrapper for the GetRetentionRule operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetRetentionRule.go.html to see an example of how to use GetRetentionRuleRequest. +type GetRetentionRuleRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The ID of the retention rule. + RetentionRuleId *string `mandatory:"true" contributesTo:"path" name:"retentionRuleId"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetRetentionRuleRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetRetentionRuleRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetRetentionRuleRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetRetentionRuleRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetRetentionRuleResponse wrapper for the GetRetentionRule operation +type GetRetentionRuleResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The RetentionRule instance + RetentionRule `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The entity tag (ETag) for the retention rule. + Etag *string `presentIn:"header" name:"etag"` + + // The time the retention rule was last modified, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.29) + LastModified *common.SDKTime `presentIn:"header" name:"last-modified"` +} + +func (response GetRetentionRuleResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetRetentionRuleResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_work_request_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_work_request_request_response.go new file mode 100644 index 000000000..81f85fc1d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/get_work_request_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetWorkRequestRequest wrapper for the GetWorkRequest operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetWorkRequest.go.html to see an example of how to use GetWorkRequestRequest. +type GetWorkRequestRequest struct { + + // The ID of the asynchronous request. + WorkRequestId *string `mandatory:"true" contributesTo:"path" name:"workRequestId"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetWorkRequestRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetWorkRequestRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetWorkRequestRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetWorkRequestRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetWorkRequestResponse wrapper for the GetWorkRequest operation +type GetWorkRequestResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The WorkRequest instance + WorkRequest `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // A decimal number representing the number of seconds the client should wait before polling this endpoint again. + RetryAfter *float32 `presentIn:"header" name:"retry-after"` +} + +func (response GetWorkRequestResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetWorkRequestResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/head_bucket_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/head_bucket_request_response.go new file mode 100644 index 000000000..aaa57eb39 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/head_bucket_request_response.go @@ -0,0 +1,96 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// HeadBucketRequest wrapper for the HeadBucket operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/HeadBucket.go.html to see an example of how to use HeadBucketRequest. +type HeadBucketRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The entity tag (ETag) to match with the ETag of an existing resource. If the specified ETag matches the ETag of + // the existing resource, GET and HEAD requests will return the resource and PUT and POST requests will upload + // the resource. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // The entity tag (ETag) to avoid matching. Wildcards ('*') are not allowed. If the specified ETag does not + // match the ETag of the existing resource, the request returns the expected response. If the ETag matches + // the ETag of the existing resource, the request returns an HTTP 304 status without a response body. + IfNoneMatch *string `mandatory:"false" contributesTo:"header" name:"if-none-match"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request HeadBucketRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request HeadBucketRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request HeadBucketRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request HeadBucketRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// HeadBucketResponse wrapper for the HeadBucket operation +type HeadBucketResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The current entity tag (ETag) for the bucket. + ETag *string `presentIn:"header" name:"etag"` + + // Flag to indicate whether or not the object was modified. If this is true, + // the getter for the object itself will return null. Callers should check this + // if they specified one of the request params that might result in a conditional + // response (like 'if-match'/'if-none-match'). + IsNotModified bool +} + +func (response HeadBucketResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response HeadBucketResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/head_object_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/head_object_request_response.go new file mode 100644 index 000000000..0017be7d2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/head_object_request_response.go @@ -0,0 +1,214 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// HeadObjectRequest wrapper for the HeadObject operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/HeadObject.go.html to see an example of how to use HeadObjectRequest. +type HeadObjectRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The name of the object. Avoid entering confidential information. + // Example: `test/object1.log` + ObjectName *string `mandatory:"true" contributesTo:"path" name:"objectName"` + + // VersionId used to identify a particular version of the object + VersionId *string `mandatory:"false" contributesTo:"query" name:"versionId"` + + // The entity tag (ETag) to match with the ETag of an existing resource. If the specified ETag matches the ETag of + // the existing resource, GET and HEAD requests will return the resource and PUT and POST requests will upload + // the resource. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // The entity tag (ETag) to avoid matching. Wildcards ('*') are not allowed. If the specified ETag does not + // match the ETag of the existing resource, the request returns the expected response. If the ETag matches + // the ETag of the existing resource, the request returns an HTTP 304 status without a response body. + IfNoneMatch *string `mandatory:"false" contributesTo:"header" name:"if-none-match"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // The optional header that specifies "AES256" as the encryption algorithm. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerAlgorithm *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-algorithm"` + + // The optional header that specifies the base64-encoded 256-bit encryption key to use to encrypt or + // decrypt the data. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerKey *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-key"` + + // The optional header that specifies the base64-encoded SHA256 hash of the encryption key. This + // value is used to check the integrity of the encryption key. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerKeySha256 *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-key-sha256"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request HeadObjectRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request HeadObjectRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request HeadObjectRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request HeadObjectRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// HeadObjectResponse wrapper for the HeadObject operation +type HeadObjectResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The entity tag (ETag) for the object. + ETag *string `presentIn:"header" name:"etag"` + + // The user-defined metadata for the object. + OpcMeta map[string]string `presentIn:"header-collection" prefix:"opc-meta-"` + + // The object size in bytes. + ContentLength *int64 `presentIn:"header" name:"content-length"` + + // Content-MD5 header, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.15). + // Unavailable for objects uploaded using multipart upload. + ContentMd5 *string `presentIn:"header" name:"content-md5"` + + // Only applicable to objects uploaded using multipart upload. + // Base-64 representation of the multipart object hash. + // The multipart object hash is calculated by taking the MD5 hashes of the parts, + // concatenating the binary representation of those hashes in order of their part numbers, + // and then calculating the MD5 hash of the concatenated values. + OpcMultipartMd5 *string `presentIn:"header" name:"opc-multipart-md5"` + + // Content-Type header, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.17). + ContentType *string `presentIn:"header" name:"content-type"` + + // Content-Language header, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.12). + ContentLanguage *string `presentIn:"header" name:"content-language"` + + // Content-Encoding header, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.11). + ContentEncoding *string `presentIn:"header" name:"content-encoding"` + + // Cache-Control header, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.9). + CacheControl *string `presentIn:"header" name:"cache-control"` + + // Content-Disposition header, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-19.5.1). + ContentDisposition *string `presentIn:"header" name:"content-disposition"` + + // The object modification time, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.29). + LastModified *common.SDKTime `presentIn:"header" name:"last-modified"` + + // The storage tier that the object is stored in. + StorageTier HeadObjectStorageTierEnum `presentIn:"header" name:"storage-tier"` + + // Archival state of an object. This field is set only for objects in Archive tier. + ArchivalState HeadObjectArchivalStateEnum `presentIn:"header" name:"archival-state"` + + // Time that the object is returned to the archived state. This field is only present for restored objects. + TimeOfArchival *common.SDKTime `presentIn:"header" name:"time-of-archival"` + + // VersionId of the object requested + VersionId *string `presentIn:"header" name:"version-id"` + + // Flag to indicate whether or not the object was modified. If this is true, + // the getter for the object itself will return null. Callers should check this + // if they specified one of the request params that might result in a conditional + // response (like 'if-match'/'if-none-match'). + IsNotModified bool +} + +func (response HeadObjectResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response HeadObjectResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// HeadObjectStorageTierEnum Enum with underlying type: string +type HeadObjectStorageTierEnum string + +// Set of constants representing the allowable values for HeadObjectStorageTierEnum +const ( + HeadObjectStorageTierStandard HeadObjectStorageTierEnum = "Standard" + HeadObjectStorageTierInfrequentaccess HeadObjectStorageTierEnum = "InfrequentAccess" + HeadObjectStorageTierArchive HeadObjectStorageTierEnum = "Archive" +) + +var mappingHeadObjectStorageTier = map[string]HeadObjectStorageTierEnum{ + "Standard": HeadObjectStorageTierStandard, + "InfrequentAccess": HeadObjectStorageTierInfrequentaccess, + "Archive": HeadObjectStorageTierArchive, +} + +// GetHeadObjectStorageTierEnumValues Enumerates the set of values for HeadObjectStorageTierEnum +func GetHeadObjectStorageTierEnumValues() []HeadObjectStorageTierEnum { + values := make([]HeadObjectStorageTierEnum, 0) + for _, v := range mappingHeadObjectStorageTier { + values = append(values, v) + } + return values +} + +// HeadObjectArchivalStateEnum Enum with underlying type: string +type HeadObjectArchivalStateEnum string + +// Set of constants representing the allowable values for HeadObjectArchivalStateEnum +const ( + HeadObjectArchivalStateArchived HeadObjectArchivalStateEnum = "Archived" + HeadObjectArchivalStateRestoring HeadObjectArchivalStateEnum = "Restoring" + HeadObjectArchivalStateRestored HeadObjectArchivalStateEnum = "Restored" +) + +var mappingHeadObjectArchivalState = map[string]HeadObjectArchivalStateEnum{ + "Archived": HeadObjectArchivalStateArchived, + "Restoring": HeadObjectArchivalStateRestoring, + "Restored": HeadObjectArchivalStateRestored, +} + +// GetHeadObjectArchivalStateEnumValues Enumerates the set of values for HeadObjectArchivalStateEnum +func GetHeadObjectArchivalStateEnumValues() []HeadObjectArchivalStateEnum { + values := make([]HeadObjectArchivalStateEnum, 0) + for _, v := range mappingHeadObjectArchivalState { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_buckets_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_buckets_request_response.go new file mode 100644 index 000000000..b4c4120d4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_buckets_request_response.go @@ -0,0 +1,123 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListBucketsRequest wrapper for the ListBuckets operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListBuckets.go.html to see an example of how to use ListBucketsRequest. +type ListBucketsRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The ID of the compartment in which to list buckets. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" call. For important + // details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Bucket summary in list of buckets includes the 'namespace', 'name', 'compartmentId', 'createdBy', 'timeCreated', + // and 'etag' fields. This parameter can also include 'tags' (freeformTags and definedTags). The only supported value + // of this parameter is 'tags' for now. Example 'tags'. + Fields []ListBucketsFieldsEnum `contributesTo:"query" name:"fields" omitEmpty:"true" collectionFormat:"csv"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListBucketsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListBucketsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListBucketsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListBucketsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListBucketsResponse wrapper for the ListBuckets operation +type ListBucketsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []BucketSummary instances + Items []BucketSummary `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For paginating a list of buckets. + // In the GET request, set the limit to the number of buckets items that you want returned in the response. + // If the `opc-next-page` header appears in the response, then this is a partial list and there are additional + // buckets to get. Include the header's value as the `page` parameter in the subsequent GET request to get the + // next batch of buckets. Repeat this process to retrieve the entire list of buckets. + // By default, the page limit is set to 25 buckets per page, but you can specify a value from 1 to 1000. + // For more details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListBucketsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListBucketsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListBucketsFieldsEnum Enum with underlying type: string +type ListBucketsFieldsEnum string + +// Set of constants representing the allowable values for ListBucketsFieldsEnum +const ( + ListBucketsFieldsTags ListBucketsFieldsEnum = "tags" +) + +var mappingListBucketsFields = map[string]ListBucketsFieldsEnum{ + "tags": ListBucketsFieldsTags, +} + +// GetListBucketsFieldsEnumValues Enumerates the set of values for ListBucketsFieldsEnum +func GetListBucketsFieldsEnumValues() []ListBucketsFieldsEnum { + values := make([]ListBucketsFieldsEnum, 0) + for _, v := range mappingListBucketsFields { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_multipart_upload_parts_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_multipart_upload_parts_request_response.go new file mode 100644 index 000000000..b28414b6d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_multipart_upload_parts_request_response.go @@ -0,0 +1,105 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListMultipartUploadPartsRequest wrapper for the ListMultipartUploadParts operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListMultipartUploadParts.go.html to see an example of how to use ListMultipartUploadPartsRequest. +type ListMultipartUploadPartsRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The name of the object. Avoid entering confidential information. + // Example: `test/object1.log` + ObjectName *string `mandatory:"true" contributesTo:"path" name:"objectName"` + + // The upload ID for a multipart upload. + UploadId *string `mandatory:"true" contributesTo:"query" name:"uploadId"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" call. For important + // details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListMultipartUploadPartsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListMultipartUploadPartsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListMultipartUploadPartsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListMultipartUploadPartsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListMultipartUploadPartsResponse wrapper for the ListMultipartUploadParts operation +type ListMultipartUploadPartsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []MultipartUploadPartSummary instances + Items []MultipartUploadPartSummary `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For paginating a list of multipart upload parts. + // In the GET request, set the limit to the number of multipart upload parts that you want returned in the + // response. If the `opc-next-page` header appears in the response, then this is a partial list and there are + // additional multipart upload parts to get. Include the header's value as the `page` parameter in the subsequent + // GET request to get the next batch of multipart upload parts. Repeat this process to retrieve the entire list + // of multipart upload parts. + // For more details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListMultipartUploadPartsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListMultipartUploadPartsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_multipart_uploads_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_multipart_uploads_request_response.go new file mode 100644 index 000000000..074de6d25 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_multipart_uploads_request_response.go @@ -0,0 +1,98 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListMultipartUploadsRequest wrapper for the ListMultipartUploads operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListMultipartUploads.go.html to see an example of how to use ListMultipartUploadsRequest. +type ListMultipartUploadsRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" call. For important + // details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListMultipartUploadsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListMultipartUploadsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListMultipartUploadsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListMultipartUploadsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListMultipartUploadsResponse wrapper for the ListMultipartUploads operation +type ListMultipartUploadsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []MultipartUpload instances + Items []MultipartUpload `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For paginating a list of multipart uploads. + // In the GET request, set the limit to the number of multipart uploads that you want returned in the response. + // If the `opc-next-page` header appears in the response, then this is a partial list and there are + // additional multipart uploads to get. Include the header's value as the `page` parameter in the subsequent + // GET request to get the next batch of objects. Repeat this process to retrieve the entire list of + // multipart uploads. + // For more details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListMultipartUploadsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListMultipartUploadsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_object_versions_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_object_versions_request_response.go new file mode 100644 index 000000000..b46816ab3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_object_versions_request_response.go @@ -0,0 +1,159 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListObjectVersionsRequest wrapper for the ListObjectVersions operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListObjectVersions.go.html to see an example of how to use ListObjectVersionsRequest. +type ListObjectVersionsRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The string to use for matching against the start of object names in a list query. + Prefix *string `mandatory:"false" contributesTo:"query" name:"prefix"` + + // Object names returned by a list query must be greater or equal to this parameter. + Start *string `mandatory:"false" contributesTo:"query" name:"start"` + + // Object names returned by a list query must be strictly less than this parameter. + End *string `mandatory:"false" contributesTo:"query" name:"end"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // When this parameter is set, only objects whose names do not contain the delimiter character + // (after an optionally specified prefix) are returned in the objects key of the response body. + // Scanned objects whose names contain the delimiter have the part of their name up to the first + // occurrence of the delimiter (including the optional prefix) returned as a set of prefixes. + // Note that only '/' is a supported delimiter character at this time. + Delimiter *string `mandatory:"false" contributesTo:"query" name:"delimiter"` + + // Object summary by default includes only the 'name' field. Use this parameter to also + // include 'size' (object size in bytes), 'etag', 'md5', 'timeCreated' (object creation date and time), + // 'timeModified' (object modification date and time), 'storageTier' and 'archivalState' fields. + // Specify the value of this parameter as a comma-separated, case-insensitive list of those field names. + // For example 'name,etag,timeCreated,md5,timeModified,storageTier,archivalState'. + Fields ListObjectVersionsFieldsEnum `mandatory:"false" contributesTo:"query" name:"fields" omitEmpty:"true"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Object names returned by a list query must be greater than this parameter. + StartAfter *string `mandatory:"false" contributesTo:"query" name:"startAfter"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" call. For important + // details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListObjectVersionsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListObjectVersionsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListObjectVersionsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListObjectVersionsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListObjectVersionsResponse wrapper for the ListObjectVersions operation +type ListObjectVersionsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of ObjectVersionCollection instances + ObjectVersionCollection `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For paginating a list of object versions. + // In the GET request, set the limit to the number of object versions that you want returned in the response. + // If the `opc-next-page` header appears in the response, then this is a partial list and there are + // additional object versions to get. Include the header's value as the `page` parameter in the subsequent + // GET request to get the next batch of object versions and prefixes. Repeat this process to retrieve the entire list of + // object versions and prefixes. + // For more details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListObjectVersionsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListObjectVersionsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListObjectVersionsFieldsEnum Enum with underlying type: string +type ListObjectVersionsFieldsEnum string + +// Set of constants representing the allowable values for ListObjectVersionsFieldsEnum +const ( + ListObjectVersionsFieldsName ListObjectVersionsFieldsEnum = "name" + ListObjectVersionsFieldsSize ListObjectVersionsFieldsEnum = "size" + ListObjectVersionsFieldsEtag ListObjectVersionsFieldsEnum = "etag" + ListObjectVersionsFieldsTimecreated ListObjectVersionsFieldsEnum = "timeCreated" + ListObjectVersionsFieldsMd5 ListObjectVersionsFieldsEnum = "md5" + ListObjectVersionsFieldsTimemodified ListObjectVersionsFieldsEnum = "timeModified" + ListObjectVersionsFieldsStoragetier ListObjectVersionsFieldsEnum = "storageTier" + ListObjectVersionsFieldsArchivalstate ListObjectVersionsFieldsEnum = "archivalState" +) + +var mappingListObjectVersionsFields = map[string]ListObjectVersionsFieldsEnum{ + "name": ListObjectVersionsFieldsName, + "size": ListObjectVersionsFieldsSize, + "etag": ListObjectVersionsFieldsEtag, + "timeCreated": ListObjectVersionsFieldsTimecreated, + "md5": ListObjectVersionsFieldsMd5, + "timeModified": ListObjectVersionsFieldsTimemodified, + "storageTier": ListObjectVersionsFieldsStoragetier, + "archivalState": ListObjectVersionsFieldsArchivalstate, +} + +// GetListObjectVersionsFieldsEnumValues Enumerates the set of values for ListObjectVersionsFieldsEnum +func GetListObjectVersionsFieldsEnumValues() []ListObjectVersionsFieldsEnum { + values := make([]ListObjectVersionsFieldsEnum, 0) + for _, v := range mappingListObjectVersionsFields { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_objects.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_objects.go new file mode 100644 index 000000000..0b2dd8195 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_objects.go @@ -0,0 +1,37 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ListObjects To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type ListObjects struct { + + // An array of object summaries. + Objects []ObjectSummary `mandatory:"true" json:"objects"` + + // Prefixes that are common to the results returned by the request if the request specified a delimiter. + Prefixes []string `mandatory:"false" json:"prefixes"` + + // The name of the object to use in the `start` parameter to obtain the next page of + // a truncated ListObjects response. Avoid entering confidential information. + // Example: test/object1.log + NextStartWith *string `mandatory:"false" json:"nextStartWith"` +} + +func (m ListObjects) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_objects_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_objects_request_response.go new file mode 100644 index 000000000..f46fee9a5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_objects_request_response.go @@ -0,0 +1,111 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListObjectsRequest wrapper for the ListObjects operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListObjects.go.html to see an example of how to use ListObjectsRequest. +type ListObjectsRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The string to use for matching against the start of object names in a list query. + Prefix *string `mandatory:"false" contributesTo:"query" name:"prefix"` + + // Object names returned by a list query must be greater or equal to this parameter. + Start *string `mandatory:"false" contributesTo:"query" name:"start"` + + // Object names returned by a list query must be strictly less than this parameter. + End *string `mandatory:"false" contributesTo:"query" name:"end"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // When this parameter is set, only objects whose names do not contain the delimiter character + // (after an optionally specified prefix) are returned in the objects key of the response body. + // Scanned objects whose names contain the delimiter have the part of their name up to the first + // occurrence of the delimiter (including the optional prefix) returned as a set of prefixes. + // Note that only '/' is a supported delimiter character at this time. + Delimiter *string `mandatory:"false" contributesTo:"query" name:"delimiter"` + + // Object summary by default includes only the 'name' field. Use this parameter to also + // include 'size' (object size in bytes), 'etag', 'md5', 'timeCreated' (object creation date and time), + // 'timeModified' (object modification date and time), 'storageTier' and 'archivalState' fields. + // Specify the value of this parameter as a comma-separated, case-insensitive list of those field names. + // For example 'name,etag,timeCreated,md5,timeModified,storageTier,archivalState'. + Fields *string `mandatory:"false" contributesTo:"query" name:"fields" omitEmpty:"true"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Object names returned by a list query must be greater than this parameter. + StartAfter *string `mandatory:"false" contributesTo:"query" name:"startAfter"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListObjectsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListObjectsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListObjectsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListObjectsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListObjectsResponse wrapper for the ListObjects operation +type ListObjectsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ListObjects instance + ListObjects `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListObjectsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListObjectsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_preauthenticated_requests_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_preauthenticated_requests_request_response.go new file mode 100644 index 000000000..5c14a4ef3 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_preauthenticated_requests_request_response.go @@ -0,0 +1,101 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListPreauthenticatedRequestsRequest wrapper for the ListPreauthenticatedRequests operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListPreauthenticatedRequests.go.html to see an example of how to use ListPreauthenticatedRequestsRequest. +type ListPreauthenticatedRequestsRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // User-specified object name prefixes can be used to query and return a list of pre-authenticated requests. + ObjectNamePrefix *string `mandatory:"false" contributesTo:"query" name:"objectNamePrefix"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" call. For important + // details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListPreauthenticatedRequestsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListPreauthenticatedRequestsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListPreauthenticatedRequestsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListPreauthenticatedRequestsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListPreauthenticatedRequestsResponse wrapper for the ListPreauthenticatedRequests operation +type ListPreauthenticatedRequestsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []PreauthenticatedRequestSummary instances + Items []PreauthenticatedRequestSummary `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For paginating a list of pre-authenticated requests. + // In the GET request, set the limit to the number of pre-authenticated requests that you want returned in + // the response. If the `opc-next-page` header appears in the response, then this is a partial list and there + // are additional pre-authenticated requests to get. Include the header's value as the `page` parameter in + // the subsequent GET request to get the next batch of pre-authenticated requests. Repeat this process to + // retrieve the entire list of pre-authenticated requests. + // For more details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListPreauthenticatedRequestsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListPreauthenticatedRequestsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_replication_policies_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_replication_policies_request_response.go new file mode 100644 index 000000000..956de55f7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_replication_policies_request_response.go @@ -0,0 +1,97 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListReplicationPoliciesRequest wrapper for the ListReplicationPolicies operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListReplicationPolicies.go.html to see an example of how to use ListReplicationPoliciesRequest. +type ListReplicationPoliciesRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" call. For important + // details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListReplicationPoliciesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListReplicationPoliciesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListReplicationPoliciesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListReplicationPoliciesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListReplicationPoliciesResponse wrapper for the ListReplicationPolicies operation +type ListReplicationPoliciesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []ReplicationPolicySummary instances + Items []ReplicationPolicySummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // For paginating a list of replication policies. + // In the GET request, set the limit to the number of buckets items that you want returned in the response. + // If the `opc-next-page` header appears in the response, then this is a partial list and there are additional + // policies to get. Include the header's value as the `page` parameter in the subsequent GET request to get the + // next batch of policies. Repeat this process to retrieve the entire list of policies. + // For more details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListReplicationPoliciesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListReplicationPoliciesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_replication_sources_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_replication_sources_request_response.go new file mode 100644 index 000000000..2a614e599 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_replication_sources_request_response.go @@ -0,0 +1,97 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListReplicationSourcesRequest wrapper for the ListReplicationSources operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListReplicationSources.go.html to see an example of how to use ListReplicationSourcesRequest. +type ListReplicationSourcesRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" call. For important + // details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListReplicationSourcesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListReplicationSourcesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListReplicationSourcesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListReplicationSourcesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListReplicationSourcesResponse wrapper for the ListReplicationSources operation +type ListReplicationSourcesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []ReplicationSource instances + Items []ReplicationSource `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // For paginating a list of replication sources. + // In the GET request, set the limit to the number of items that you want returned in the response. + // If the `opc-next-page` header appears in the response, then this is a partial list and there are additional + // policies to get. Include the header's value as the `page` parameter in the subsequent GET request to get the + // next batch of policies. Repeat this process to retrieve the entire list of sources. + // For more details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListReplicationSourcesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListReplicationSourcesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_retention_rules_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_retention_rules_request_response.go new file mode 100644 index 000000000..557f8c96c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_retention_rules_request_response.go @@ -0,0 +1,93 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListRetentionRulesRequest wrapper for the ListRetentionRules operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListRetentionRules.go.html to see an example of how to use ListRetentionRulesRequest. +type ListRetentionRulesRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" call. For important + // details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. + // If you need to contact Oracle about a particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListRetentionRulesRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListRetentionRulesRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListRetentionRulesRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListRetentionRulesRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListRetentionRulesResponse wrapper for the ListRetentionRules operation +type ListRetentionRulesResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of RetentionRuleCollection instances + RetentionRuleCollection `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Paginating a list of retention rules. + // If the `opc-next-page` header appears in the response, it indicates that this is a partial list + // of retention rules and there are additional rules to get. Include the value of this header as + // the `page` parameter in a subsequent GET request to get the next set of retention rules. + // Repeat this process to retrieve the entire list of retention rules. + // For more details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListRetentionRulesResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListRetentionRulesResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_work_request_errors_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_work_request_errors_request_response.go new file mode 100644 index 000000000..52536d10f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_work_request_errors_request_response.go @@ -0,0 +1,94 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListWorkRequestErrorsRequest wrapper for the ListWorkRequestErrors operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListWorkRequestErrors.go.html to see an example of how to use ListWorkRequestErrorsRequest. +type ListWorkRequestErrorsRequest struct { + + // The ID of the asynchronous request. + WorkRequestId *string `mandatory:"true" contributesTo:"path" name:"workRequestId"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" call. For important + // details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListWorkRequestErrorsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListWorkRequestErrorsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListWorkRequestErrorsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListWorkRequestErrorsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListWorkRequestErrorsResponse wrapper for the ListWorkRequestErrors operation +type ListWorkRequestErrorsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []WorkRequestError instances + Items []WorkRequestError `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For paginating a list of work request errors. + // In the GET request, set the limit to the number of work request errors that you want returned in the + // response. If the `opc-next-page` header appears in the response, then this is a partial list and there are + // additional work request errors to get. Include the header's value as the `page` parameter in the subsequent + // GET request to get the next batch of work request errors. Repeat this process to retrieve the entire list of work + // request errors. + // For more details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` +} + +func (response ListWorkRequestErrorsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListWorkRequestErrorsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_work_request_logs_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_work_request_logs_request_response.go new file mode 100644 index 000000000..e7d12faaf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_work_request_logs_request_response.go @@ -0,0 +1,94 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListWorkRequestLogsRequest wrapper for the ListWorkRequestLogs operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListWorkRequestLogs.go.html to see an example of how to use ListWorkRequestLogsRequest. +type ListWorkRequestLogsRequest struct { + + // The ID of the asynchronous request. + WorkRequestId *string `mandatory:"true" contributesTo:"path" name:"workRequestId"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" call. For important + // details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListWorkRequestLogsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListWorkRequestLogsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListWorkRequestLogsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListWorkRequestLogsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListWorkRequestLogsResponse wrapper for the ListWorkRequestLogs operation +type ListWorkRequestLogsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []WorkRequestLogEntry instances + Items []WorkRequestLogEntry `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // For paginating a list of work request logs. + // In the GET request, set the limit to the number of compartment work requests that you want returned in the + // response. If the `opc-next-page` header appears in the response, then this is a partial list and there are + // additional work requests to get. Include the header's value as the `page` parameter in the subsequent + // GET request to get the next batch of work requests. Repeat this process to retrieve the entire list of work + // requests. + // For more details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` +} + +func (response ListWorkRequestLogsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListWorkRequestLogsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_work_requests_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_work_requests_request_response.go new file mode 100644 index 000000000..8d4e7c5ef --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/list_work_requests_request_response.go @@ -0,0 +1,94 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListWorkRequestsRequest wrapper for the ListWorkRequests operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListWorkRequests.go.html to see an example of how to use ListWorkRequestsRequest. +type ListWorkRequestsRequest struct { + + // The ID of the compartment in which to list buckets. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // For list pagination. The value of the `opc-next-page` response header from the previous "List" call. For important + // details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // For list pagination. The maximum number of results per page, or items to return in a paginated + // "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListWorkRequestsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListWorkRequestsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListWorkRequestsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListWorkRequestsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListWorkRequestsResponse wrapper for the ListWorkRequests operation +type ListWorkRequestsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []WorkRequestSummary instances + Items []WorkRequestSummary `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // For paginating a list of work requests. + // In the GET request, set the limit to the number of compartment work requests that you want returned in the + // response. If the `opc-next-page` header appears in the response, then this is a partial list and there are + // additional work requests to get. Include the header's value as the `page` parameter in the subsequent + // GET request to get the next batch of work requests. Repeat this process to retrieve the entire list of work + // requests. + // For more details about how pagination works, see List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` +} + +func (response ListWorkRequestsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListWorkRequestsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/make_bucket_writable_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/make_bucket_writable_request_response.go new file mode 100644 index 000000000..df6eec7c1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/make_bucket_writable_request_response.go @@ -0,0 +1,77 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// MakeBucketWritableRequest wrapper for the MakeBucketWritable operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/MakeBucketWritable.go.html to see an example of how to use MakeBucketWritableRequest. +type MakeBucketWritableRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request MakeBucketWritableRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request MakeBucketWritableRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request MakeBucketWritableRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request MakeBucketWritableRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// MakeBucketWritableResponse wrapper for the MakeBucketWritable operation +type MakeBucketWritableResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response MakeBucketWritableResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response MakeBucketWritableResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/multipart_upload.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/multipart_upload.go new file mode 100644 index 000000000..3496bd4ed --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/multipart_upload.go @@ -0,0 +1,49 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// MultipartUpload Multipart uploads provide efficient and resilient uploads, especially for large objects. Multipart uploads also accommodate +// objects that are too large for a single upload operation. With multipart uploads, individual parts of an object can be +// uploaded in parallel to reduce the amount of time you spend uploading. Multipart uploads can also minimize the impact +// of network failures by letting you retry a failed part upload instead of requiring you to retry an entire object upload. +// See Using Multipart Uploads (https://docs.cloud.oracle.com/Content/Object/Tasks/usingmultipartuploads.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type MultipartUpload struct { + + // The Object Storage namespace in which the in-progress multipart upload is stored. + Namespace *string `mandatory:"true" json:"namespace"` + + // The bucket in which the in-progress multipart upload is stored. + Bucket *string `mandatory:"true" json:"bucket"` + + // The object name of the in-progress multipart upload. + Object *string `mandatory:"true" json:"object"` + + // The unique identifier for the in-progress multipart upload. + UploadId *string `mandatory:"true" json:"uploadId"` + + // The date and time the upload was created, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.29). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The storage tier that the object is stored in. + StorageTier StorageTierEnum `mandatory:"false" json:"storageTier,omitempty"` +} + +func (m MultipartUpload) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/multipart_upload_part_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/multipart_upload_part_summary.go new file mode 100644 index 000000000..30098a614 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/multipart_upload_part_summary.go @@ -0,0 +1,39 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// MultipartUploadPartSummary Gets summary information about multipart uploads. +// To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, +// see Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type MultipartUploadPartSummary struct { + + // The current entity tag (ETag) for the part. + Etag *string `mandatory:"true" json:"etag"` + + // The MD5 hash of the bytes of the part. + Md5 *string `mandatory:"true" json:"md5"` + + // The size of the part in bytes. + Size *int64 `mandatory:"true" json:"size"` + + // The part number for this part. + PartNumber *int `mandatory:"true" json:"partNumber"` +} + +func (m MultipartUploadPartSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/namespace_metadata.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/namespace_metadata.go new file mode 100644 index 000000000..b915e0f5b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/namespace_metadata.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// NamespaceMetadata NamespaceMetadata maps a namespace string to defaultS3CompartmentId and defaultSwiftCompartmentId values. +type NamespaceMetadata struct { + + // The Object Storage namespace to which the metadata belongs. + Namespace *string `mandatory:"true" json:"namespace"` + + // If the field is set, specifies the default compartment assignment for the Amazon S3 Compatibility API. + DefaultS3CompartmentId *string `mandatory:"true" json:"defaultS3CompartmentId"` + + // If the field is set, specifies the default compartment assignment for the Swift API. + DefaultSwiftCompartmentId *string `mandatory:"true" json:"defaultSwiftCompartmentId"` +} + +func (m NamespaceMetadata) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_lifecycle_policy.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_lifecycle_policy.go new file mode 100644 index 000000000..76d4338a0 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_lifecycle_policy.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ObjectLifecyclePolicy The collection of lifecycle policy rules that together form the object lifecycle policy of a given bucket. +type ObjectLifecyclePolicy struct { + + // The date and time the object lifecycle policy was created, as described in + // RFC 3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // The live lifecycle policy on the bucket. + // For an example of this value, see the + // PutObjectLifecyclePolicy API documentation (https://docs.cloud.oracle.com/iaas/api/#/en/objectstorage/20160918/ObjectLifecyclePolicy/PutObjectLifecyclePolicy). + Items []ObjectLifecycleRule `mandatory:"false" json:"items"` +} + +func (m ObjectLifecyclePolicy) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_lifecycle_rule.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_lifecycle_rule.go new file mode 100644 index 000000000..108372dce --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_lifecycle_rule.go @@ -0,0 +1,85 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ObjectLifecycleRule To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type ObjectLifecycleRule struct { + + // The name of the lifecycle rule to be applied. + Name *string `mandatory:"true" json:"name"` + + // The action of the object lifecycle policy rule. + // Rules using the action 'ARCHIVE' move objects from Standard and InfrequentAccess storage tiers + // into the Archive storage tier (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). + // Rules using the action 'INFREQUENT_ACCESS' move objects from Standard storage tier into the + // Infrequent Access Storage tier. Objects that are already in InfrequentAccess tier or in Archive + // tier are left untouched. + // Rules using the action 'DELETE' permanently delete objects from buckets. + // Rules using 'ABORT' abort the uncommitted multipart-uploads and permanently delete their parts from buckets. + Action *string `mandatory:"true" json:"action"` + + // Specifies the age of objects to apply the rule to. The timeAmount is interpreted in units defined by the + // timeUnit parameter, and is calculated in relation to each object's Last-Modified time. + TimeAmount *int64 `mandatory:"true" json:"timeAmount"` + + // The unit that should be used to interpret timeAmount. Days are defined as starting and ending at midnight UTC. + // Years are defined as 365.2425 days long and likewise round up to the next midnight UTC. + TimeUnit ObjectLifecycleRuleTimeUnitEnum `mandatory:"true" json:"timeUnit"` + + // A Boolean that determines whether this rule is currently enabled. + IsEnabled *bool `mandatory:"true" json:"isEnabled"` + + // The target of the object lifecycle policy rule. The values of target can be either "objects", + // "multipart-uploads" or "previous-object-versions". + // This field when declared as "objects" is used to specify ARCHIVE, INFREQUENT_ACCESS + // or DELETE rule for objects. + // This field when declared as "previous-object-versions" is used to specify ARCHIVE, + // INFREQUENT_ACCESS or DELETE rule for previous versions of existing objects. + // This field when declared as "multipart-uploads" is used to specify the ABORT (only) rule for + // uncommitted multipart-uploads. + Target *string `mandatory:"false" json:"target"` + + ObjectNameFilter *ObjectNameFilter `mandatory:"false" json:"objectNameFilter"` +} + +func (m ObjectLifecycleRule) String() string { + return common.PointerString(m) +} + +// ObjectLifecycleRuleTimeUnitEnum Enum with underlying type: string +type ObjectLifecycleRuleTimeUnitEnum string + +// Set of constants representing the allowable values for ObjectLifecycleRuleTimeUnitEnum +const ( + ObjectLifecycleRuleTimeUnitDays ObjectLifecycleRuleTimeUnitEnum = "DAYS" + ObjectLifecycleRuleTimeUnitYears ObjectLifecycleRuleTimeUnitEnum = "YEARS" +) + +var mappingObjectLifecycleRuleTimeUnit = map[string]ObjectLifecycleRuleTimeUnitEnum{ + "DAYS": ObjectLifecycleRuleTimeUnitDays, + "YEARS": ObjectLifecycleRuleTimeUnitYears, +} + +// GetObjectLifecycleRuleTimeUnitEnumValues Enumerates the set of values for ObjectLifecycleRuleTimeUnitEnum +func GetObjectLifecycleRuleTimeUnitEnumValues() []ObjectLifecycleRuleTimeUnitEnum { + values := make([]ObjectLifecycleRuleTimeUnitEnum, 0) + for _, v := range mappingObjectLifecycleRuleTimeUnit { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_name_filter.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_name_filter.go new file mode 100644 index 000000000..a449574ee --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_name_filter.go @@ -0,0 +1,70 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ObjectNameFilter A filter that compares object names to a set of prefixes or patterns to determine if a rule applies to a +// given object. The filter can contain include glob patterns, exclude glob patterns and inclusion prefixes. +// The inclusion prefixes property is kept for backward compatibility. It is recommended to use inclusion patterns +// instead of prefixes. Exclusions take precedence over inclusions. +type ObjectNameFilter struct { + + // An array of glob patterns to match the object names to include. An empty array includes all objects in the + // bucket. Exclusion patterns take precedence over inclusion patterns. + // A Glob pattern is a sequence of characters to match text. Any character that appears in the pattern, other + // than the special pattern characters described below, matches itself. + // Glob patterns must be between 1 and 1024 characters. + // The special pattern characters have the following meanings: + // \ Escapes the following character + // * Matches any string of characters. + // ? Matches any single character . + // [...] Matches a group of characters. A group of characters can be: + // A set of characters, for example: [Zafg9@]. This matches any character in the brackets. + // A range of characters, for example: [a-z]. This matches any character in the range. + // [a-f] is equivalent to [abcdef]. + // For character ranges only the CHARACTER-CHARACTER pattern is supported. + // [ab-yz] is not valid + // [a-mn-z] is not valid + // Character ranges can not start with ^ or : + // To include a '-' in the range, make it the first or last character. + InclusionPatterns []string `mandatory:"false" json:"inclusionPatterns"` + + // An array of glob patterns to match the object names to exclude. An empty array is ignored. Exclusion + // patterns take precedence over inclusion patterns. + // A Glob pattern is a sequence of characters to match text. Any character that appears in the pattern, other + // than the special pattern characters described below, matches itself. + // Glob patterns must be between 1 and 1024 characters. + // The special pattern characters have the following meanings: + // \ Escapes the following character + // * Matches any string of characters. + // ? Matches any single character . + // [...] Matches a group of characters. A group of characters can be: + // A set of characters, for example: [Zafg9@]. This matches any character in the brackets. + // A range of characters, for example: [a-z]. This matches any character in the range. + // [a-f] is equivalent to [abcdef]. + // For character ranges only the CHARACTER-CHARACTER pattern is supported. + // [ab-yz] is not valid + // [a-mn-z] is not valid + // Character ranges can not start with ^ or : + // To include a '-' in the range, make it the first or last character. + ExclusionPatterns []string `mandatory:"false" json:"exclusionPatterns"` + + // An array of object name prefixes that the rule will apply to. An empty array means to include all objects. + InclusionPrefixes []string `mandatory:"false" json:"inclusionPrefixes"` +} + +func (m ObjectNameFilter) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_summary.go new file mode 100644 index 000000000..b09de61ab --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_summary.go @@ -0,0 +1,51 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ObjectSummary To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type ObjectSummary struct { + + // The name of the object. Avoid entering confidential information. + // Example: test/object1.log + Name *string `mandatory:"true" json:"name"` + + // Size of the object in bytes. + Size *int64 `mandatory:"false" json:"size"` + + // Base64-encoded MD5 hash of the object data. + Md5 *string `mandatory:"false" json:"md5"` + + // The date and time the object was created, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.29). + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // The current entity tag (ETag) for the object. + Etag *string `mandatory:"false" json:"etag"` + + // The storage tier that the object is stored in. + StorageTier StorageTierEnum `mandatory:"false" json:"storageTier,omitempty"` + + // Archival state of an object. This field is set only for objects in Archive tier. + ArchivalState ArchivalStateEnum `mandatory:"false" json:"archivalState,omitempty"` + + // The date and time the object was modified, as described in RFC 2616 (https://tools.ietf.org/rfc/rfc2616), section 14.29. + TimeModified *common.SDKTime `mandatory:"false" json:"timeModified"` +} + +func (m ObjectSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_version_collection.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_version_collection.go new file mode 100644 index 000000000..39f12b27d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_version_collection.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ObjectVersionCollection To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type ObjectVersionCollection struct { + + // An array of object version summaries. + Items []ObjectVersionSummary `mandatory:"true" json:"items"` + + // Prefixes that are common to the results returned by the request if the request specified a delimiter. + Prefixes []string `mandatory:"false" json:"prefixes"` +} + +func (m ObjectVersionCollection) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_version_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_version_summary.go new file mode 100644 index 000000000..fdf29f4a4 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/object_version_summary.go @@ -0,0 +1,57 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ObjectVersionSummary To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type ObjectVersionSummary struct { + + // The name of the object. Avoid entering confidential information. + // Example: test/object1.log + Name *string `mandatory:"true" json:"name"` + + // The date and time the object was modified, as described in RFC 2616 (https://tools.ietf.org/rfc/rfc2616#section-14.29). + TimeModified *common.SDKTime `mandatory:"true" json:"timeModified"` + + // VersionId of the object. + VersionId *string `mandatory:"true" json:"versionId"` + + // This flag will indicate if the version is deleted or not. + IsDeleteMarker *bool `mandatory:"true" json:"isDeleteMarker"` + + // Size of the object in bytes. + Size *int64 `mandatory:"false" json:"size"` + + // Base64-encoded MD5 hash of the object data. + Md5 *string `mandatory:"false" json:"md5"` + + // The date and time the object was created, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.29). + TimeCreated *common.SDKTime `mandatory:"false" json:"timeCreated"` + + // The current entity tag (ETag) for the object. + Etag *string `mandatory:"false" json:"etag"` + + // The storage tier that the object is stored in. + StorageTier StorageTierEnum `mandatory:"false" json:"storageTier,omitempty"` + + // Archival state of an object. This field is set only for objects in Archive tier. + ArchivalState ArchivalStateEnum `mandatory:"false" json:"archivalState,omitempty"` +} + +func (m ObjectVersionSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/objectstorage_client.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/objectstorage_client.go new file mode 100644 index 000000000..24eec3ecb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/objectstorage_client.go @@ -0,0 +1,2925 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "context" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" + "github.com/oracle/oci-go-sdk/v54/common/auth" + "net/http" +) + +//ObjectStorageClient a client for ObjectStorage +type ObjectStorageClient struct { + common.BaseClient + config *common.ConfigurationProvider +} + +// NewObjectStorageClientWithConfigurationProvider Creates a new default ObjectStorage client with the given configuration provider. +// the configuration provider will be used for the default signer as well as reading the region +func NewObjectStorageClientWithConfigurationProvider(configProvider common.ConfigurationProvider) (client ObjectStorageClient, err error) { + provider, err := auth.GetGenericConfigurationProvider(configProvider) + if err != nil { + return client, err + } + baseClient, e := common.NewClientWithConfig(provider) + if e != nil { + return client, e + } + return newObjectStorageClientFromBaseClient(baseClient, provider) +} + +// NewObjectStorageClientWithOboToken Creates a new default ObjectStorage client with the given configuration provider. +// The obotoken will be added to default headers and signed; the configuration provider will be used for the signer +// as well as reading the region +func NewObjectStorageClientWithOboToken(configProvider common.ConfigurationProvider, oboToken string) (client ObjectStorageClient, err error) { + baseClient, err := common.NewClientWithOboToken(configProvider, oboToken) + if err != nil { + return client, err + } + + return newObjectStorageClientFromBaseClient(baseClient, configProvider) +} + +func newObjectStorageClientFromBaseClient(baseClient common.BaseClient, configProvider common.ConfigurationProvider) (client ObjectStorageClient, err error) { + // ObjectStorage service default circuit breaker is enabled + baseClient.Configuration.CircuitBreaker = common.NewCircuitBreaker(common.DefaultCircuitBreakerSetting()) + common.ConfigCircuitBreakerFromEnvVar(&baseClient) + common.ConfigCircuitBreakerFromGlobalVar(&baseClient) + + client = ObjectStorageClient{BaseClient: baseClient} + err = client.setConfigurationProvider(configProvider) + return +} + +// SetRegion overrides the region of this client. +func (client *ObjectStorageClient) SetRegion(region string) { + client.Host = common.StringToRegion(region).EndpointForTemplate("objectstorage", "https://objectstorage.{region}.{secondLevelDomain}") +} + +// SetConfigurationProvider sets the configuration provider including the region, returns an error if is not valid +func (client *ObjectStorageClient) setConfigurationProvider(configProvider common.ConfigurationProvider) error { + if ok, err := common.IsConfigurationProviderValid(configProvider); !ok { + return err + } + + // Error has been checked already + region, _ := configProvider.Region() + client.SetRegion(region) + client.config = &configProvider + return nil +} + +// ConfigurationProvider the ConfigurationProvider used in this client, or null if none set +func (client *ObjectStorageClient) ConfigurationProvider() *common.ConfigurationProvider { + return client.config +} + +// AbortMultipartUpload Aborts an in-progress multipart upload and deletes all parts that have been uploaded. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/AbortMultipartUpload.go.html to see an example of how to use AbortMultipartUpload API. +func (client ObjectStorageClient) AbortMultipartUpload(ctx context.Context, request AbortMultipartUploadRequest) (response AbortMultipartUploadResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.abortMultipartUpload, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = AbortMultipartUploadResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = AbortMultipartUploadResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(AbortMultipartUploadResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into AbortMultipartUploadResponse") + } + return +} + +// abortMultipartUpload implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) abortMultipartUpload(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/n/{namespaceName}/b/{bucketName}/u/{objectName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response AbortMultipartUploadResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CancelWorkRequest Cancels a work request. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CancelWorkRequest.go.html to see an example of how to use CancelWorkRequest API. +func (client ObjectStorageClient) CancelWorkRequest(ctx context.Context, request CancelWorkRequestRequest) (response CancelWorkRequestResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.cancelWorkRequest, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CancelWorkRequestResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CancelWorkRequestResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CancelWorkRequestResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CancelWorkRequestResponse") + } + return +} + +// cancelWorkRequest implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) cancelWorkRequest(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/workRequests/{workRequestId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CancelWorkRequestResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CommitMultipartUpload Commits a multipart upload, which involves checking part numbers and entity tags (ETags) of the parts, to create an aggregate object. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CommitMultipartUpload.go.html to see an example of how to use CommitMultipartUpload API. +func (client ObjectStorageClient) CommitMultipartUpload(ctx context.Context, request CommitMultipartUploadRequest) (response CommitMultipartUploadResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.commitMultipartUpload, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CommitMultipartUploadResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CommitMultipartUploadResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CommitMultipartUploadResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CommitMultipartUploadResponse") + } + return +} + +// commitMultipartUpload implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) commitMultipartUpload(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/n/{namespaceName}/b/{bucketName}/u/{objectName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CommitMultipartUploadResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CopyObject Creates a request to copy an object within a region or to another region. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CopyObject.go.html to see an example of how to use CopyObject API. +func (client ObjectStorageClient) CopyObject(ctx context.Context, request CopyObjectRequest) (response CopyObjectResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.copyObject, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CopyObjectResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CopyObjectResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CopyObjectResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CopyObjectResponse") + } + return +} + +// copyObject implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) copyObject(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/n/{namespaceName}/b/{bucketName}/actions/copyObject", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CopyObjectResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateBucket Creates a bucket in the given namespace with a bucket name and optional user-defined metadata. Avoid entering +// confidential information in bucket names. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CreateBucket.go.html to see an example of how to use CreateBucket API. +func (client ObjectStorageClient) CreateBucket(ctx context.Context, request CreateBucketRequest) (response CreateBucketResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.createBucket, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateBucketResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateBucketResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateBucketResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateBucketResponse") + } + return +} + +// createBucket implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) createBucket(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/n/{namespaceName}/b", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateBucketResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateMultipartUpload Starts a new multipart upload to a specific object in the given bucket in the given namespace. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CreateMultipartUpload.go.html to see an example of how to use CreateMultipartUpload API. +func (client ObjectStorageClient) CreateMultipartUpload(ctx context.Context, request CreateMultipartUploadRequest) (response CreateMultipartUploadResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.createMultipartUpload, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateMultipartUploadResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateMultipartUploadResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateMultipartUploadResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateMultipartUploadResponse") + } + return +} + +// createMultipartUpload implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) createMultipartUpload(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/n/{namespaceName}/b/{bucketName}/u", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateMultipartUploadResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreatePreauthenticatedRequest Creates a pre-authenticated request specific to the bucket. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CreatePreauthenticatedRequest.go.html to see an example of how to use CreatePreauthenticatedRequest API. +func (client ObjectStorageClient) CreatePreauthenticatedRequest(ctx context.Context, request CreatePreauthenticatedRequestRequest) (response CreatePreauthenticatedRequestResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.createPreauthenticatedRequest, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreatePreauthenticatedRequestResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreatePreauthenticatedRequestResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreatePreauthenticatedRequestResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreatePreauthenticatedRequestResponse") + } + return +} + +// createPreauthenticatedRequest implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) createPreauthenticatedRequest(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/n/{namespaceName}/b/{bucketName}/p", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreatePreauthenticatedRequestResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateReplicationPolicy Creates a replication policy for the specified bucket. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CreateReplicationPolicy.go.html to see an example of how to use CreateReplicationPolicy API. +func (client ObjectStorageClient) CreateReplicationPolicy(ctx context.Context, request CreateReplicationPolicyRequest) (response CreateReplicationPolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.createReplicationPolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateReplicationPolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateReplicationPolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateReplicationPolicyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateReplicationPolicyResponse") + } + return +} + +// createReplicationPolicy implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) createReplicationPolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/n/{namespaceName}/b/{bucketName}/replicationPolicies", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateReplicationPolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// CreateRetentionRule Creates a new retention rule in the specified bucket. The new rule will take effect typically within 30 seconds. +// Note that a maximum of 100 rules are supported on a bucket. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/CreateRetentionRule.go.html to see an example of how to use CreateRetentionRule API. +func (client ObjectStorageClient) CreateRetentionRule(ctx context.Context, request CreateRetentionRuleRequest) (response CreateRetentionRuleResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.createRetentionRule, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = CreateRetentionRuleResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = CreateRetentionRuleResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(CreateRetentionRuleResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into CreateRetentionRuleResponse") + } + return +} + +// createRetentionRule implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) createRetentionRule(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/n/{namespaceName}/b/{bucketName}/retentionRules", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response CreateRetentionRuleResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteBucket Deletes a bucket if the bucket is already empty. If the bucket is not empty, use +// DeleteObject first. In addition, +// you cannot delete a bucket that has a multipart upload in progress or a pre-authenticated +// request associated with that bucket. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/DeleteBucket.go.html to see an example of how to use DeleteBucket API. +func (client ObjectStorageClient) DeleteBucket(ctx context.Context, request DeleteBucketRequest) (response DeleteBucketResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteBucket, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteBucketResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteBucketResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteBucketResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteBucketResponse") + } + return +} + +// deleteBucket implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) deleteBucket(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/n/{namespaceName}/b/{bucketName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteBucketResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteObject Deletes an object. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/DeleteObject.go.html to see an example of how to use DeleteObject API. +func (client ObjectStorageClient) DeleteObject(ctx context.Context, request DeleteObjectRequest) (response DeleteObjectResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteObject, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteObjectResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteObjectResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteObjectResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteObjectResponse") + } + return +} + +// deleteObject implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) deleteObject(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/n/{namespaceName}/b/{bucketName}/o/{objectName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteObjectResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteObjectLifecyclePolicy Deletes the object lifecycle policy for the bucket. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/DeleteObjectLifecyclePolicy.go.html to see an example of how to use DeleteObjectLifecyclePolicy API. +func (client ObjectStorageClient) DeleteObjectLifecyclePolicy(ctx context.Context, request DeleteObjectLifecyclePolicyRequest) (response DeleteObjectLifecyclePolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteObjectLifecyclePolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteObjectLifecyclePolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteObjectLifecyclePolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteObjectLifecyclePolicyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteObjectLifecyclePolicyResponse") + } + return +} + +// deleteObjectLifecyclePolicy implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) deleteObjectLifecyclePolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/n/{namespaceName}/b/{bucketName}/l", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteObjectLifecyclePolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeletePreauthenticatedRequest Deletes the pre-authenticated request for the bucket. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/DeletePreauthenticatedRequest.go.html to see an example of how to use DeletePreauthenticatedRequest API. +func (client ObjectStorageClient) DeletePreauthenticatedRequest(ctx context.Context, request DeletePreauthenticatedRequestRequest) (response DeletePreauthenticatedRequestResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deletePreauthenticatedRequest, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeletePreauthenticatedRequestResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeletePreauthenticatedRequestResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeletePreauthenticatedRequestResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeletePreauthenticatedRequestResponse") + } + return +} + +// deletePreauthenticatedRequest implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) deletePreauthenticatedRequest(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/n/{namespaceName}/b/{bucketName}/p/{parId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeletePreauthenticatedRequestResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteReplicationPolicy Deletes the replication policy associated with the source bucket. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/DeleteReplicationPolicy.go.html to see an example of how to use DeleteReplicationPolicy API. +func (client ObjectStorageClient) DeleteReplicationPolicy(ctx context.Context, request DeleteReplicationPolicyRequest) (response DeleteReplicationPolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteReplicationPolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteReplicationPolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteReplicationPolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteReplicationPolicyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteReplicationPolicyResponse") + } + return +} + +// deleteReplicationPolicy implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) deleteReplicationPolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/n/{namespaceName}/b/{bucketName}/replicationPolicies/{replicationId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteReplicationPolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// DeleteRetentionRule Deletes the specified rule. The deletion takes effect typically within 30 seconds. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/DeleteRetentionRule.go.html to see an example of how to use DeleteRetentionRule API. +func (client ObjectStorageClient) DeleteRetentionRule(ctx context.Context, request DeleteRetentionRuleRequest) (response DeleteRetentionRuleResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.deleteRetentionRule, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = DeleteRetentionRuleResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = DeleteRetentionRuleResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(DeleteRetentionRuleResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into DeleteRetentionRuleResponse") + } + return +} + +// deleteRetentionRule implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) deleteRetentionRule(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodDelete, "/n/{namespaceName}/b/{bucketName}/retentionRules/{retentionRuleId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response DeleteRetentionRuleResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetBucket Gets the current representation of the given bucket in the given Object Storage namespace. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetBucket.go.html to see an example of how to use GetBucket API. +func (client ObjectStorageClient) GetBucket(ctx context.Context, request GetBucketRequest) (response GetBucketResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getBucket, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetBucketResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetBucketResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetBucketResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetBucketResponse") + } + return +} + +// getBucket implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) getBucket(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}/b/{bucketName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetBucketResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetNamespace Each Oracle Cloud Infrastructure tenant is assigned one unique and uneditable Object Storage namespace. The namespace +// is a system-generated string assigned during account creation. For some older tenancies, the namespace string may be +// the tenancy name in all lower-case letters. You cannot edit a namespace. +// GetNamespace returns the name of the Object Storage namespace for the user making the request. +// If an optional compartmentId query parameter is provided, GetNamespace returns the namespace name of the corresponding +// tenancy, provided the user has access to it. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetNamespace.go.html to see an example of how to use GetNamespace API. +func (client ObjectStorageClient) GetNamespace(ctx context.Context, request GetNamespaceRequest) (response GetNamespaceResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getNamespace, policy) + if err != nil { + if ociResponse != nil { + response = GetNamespaceResponse{RawResponse: ociResponse.HTTPResponse()} + } + return + } + if convertedResponse, ok := ociResponse.(GetNamespaceResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetNamespaceResponse") + } + return +} + +// getNamespace implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) getNamespace(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetNamespaceResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetNamespaceMetadata Gets the metadata for the Object Storage namespace, which contains defaultS3CompartmentId and +// defaultSwiftCompartmentId. +// Any user with the OBJECTSTORAGE_NAMESPACE_READ permission will be able to see the current metadata. If you are +// not authorized, talk to an administrator. If you are an administrator who needs to write policies +// to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetNamespaceMetadata.go.html to see an example of how to use GetNamespaceMetadata API. +func (client ObjectStorageClient) GetNamespaceMetadata(ctx context.Context, request GetNamespaceMetadataRequest) (response GetNamespaceMetadataResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getNamespaceMetadata, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetNamespaceMetadataResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetNamespaceMetadataResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetNamespaceMetadataResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetNamespaceMetadataResponse") + } + return +} + +// getNamespaceMetadata implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) getNamespaceMetadata(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetNamespaceMetadataResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetObject Gets the metadata and body of an object. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetObject.go.html to see an example of how to use GetObject API. +func (client ObjectStorageClient) GetObject(ctx context.Context, request GetObjectRequest) (response GetObjectResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getObject, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetObjectResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetObjectResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetObjectResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetObjectResponse") + } + return +} + +// getObject implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) getObject(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}/b/{bucketName}/o/{objectName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetObjectResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetObjectLifecyclePolicy Gets the object lifecycle policy for the bucket. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetObjectLifecyclePolicy.go.html to see an example of how to use GetObjectLifecyclePolicy API. +func (client ObjectStorageClient) GetObjectLifecyclePolicy(ctx context.Context, request GetObjectLifecyclePolicyRequest) (response GetObjectLifecyclePolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getObjectLifecyclePolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetObjectLifecyclePolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetObjectLifecyclePolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetObjectLifecyclePolicyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetObjectLifecyclePolicyResponse") + } + return +} + +// getObjectLifecyclePolicy implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) getObjectLifecyclePolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}/b/{bucketName}/l", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetObjectLifecyclePolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetPreauthenticatedRequest Gets the pre-authenticated request for the bucket. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetPreauthenticatedRequest.go.html to see an example of how to use GetPreauthenticatedRequest API. +func (client ObjectStorageClient) GetPreauthenticatedRequest(ctx context.Context, request GetPreauthenticatedRequestRequest) (response GetPreauthenticatedRequestResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getPreauthenticatedRequest, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetPreauthenticatedRequestResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetPreauthenticatedRequestResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetPreauthenticatedRequestResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetPreauthenticatedRequestResponse") + } + return +} + +// getPreauthenticatedRequest implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) getPreauthenticatedRequest(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}/b/{bucketName}/p/{parId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetPreauthenticatedRequestResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetReplicationPolicy Get the replication policy. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetReplicationPolicy.go.html to see an example of how to use GetReplicationPolicy API. +func (client ObjectStorageClient) GetReplicationPolicy(ctx context.Context, request GetReplicationPolicyRequest) (response GetReplicationPolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getReplicationPolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetReplicationPolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetReplicationPolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetReplicationPolicyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetReplicationPolicyResponse") + } + return +} + +// getReplicationPolicy implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) getReplicationPolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}/b/{bucketName}/replicationPolicies/{replicationId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetReplicationPolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetRetentionRule Get the specified retention rule. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetRetentionRule.go.html to see an example of how to use GetRetentionRule API. +func (client ObjectStorageClient) GetRetentionRule(ctx context.Context, request GetRetentionRuleRequest) (response GetRetentionRuleResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getRetentionRule, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetRetentionRuleResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetRetentionRuleResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetRetentionRuleResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetRetentionRuleResponse") + } + return +} + +// getRetentionRule implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) getRetentionRule(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}/b/{bucketName}/retentionRules/{retentionRuleId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetRetentionRuleResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// GetWorkRequest Gets the status of the work request for the given ID. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/GetWorkRequest.go.html to see an example of how to use GetWorkRequest API. +func (client ObjectStorageClient) GetWorkRequest(ctx context.Context, request GetWorkRequestRequest) (response GetWorkRequestResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getWorkRequest, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetWorkRequestResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetWorkRequestResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetWorkRequestResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetWorkRequestResponse") + } + return +} + +// getWorkRequest implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) getWorkRequest(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/workRequests/{workRequestId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetWorkRequestResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// HeadBucket Efficiently checks to see if a bucket exists and gets the current entity tag (ETag) for the bucket. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/HeadBucket.go.html to see an example of how to use HeadBucket API. +func (client ObjectStorageClient) HeadBucket(ctx context.Context, request HeadBucketRequest) (response HeadBucketResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.headBucket, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = HeadBucketResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = HeadBucketResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(HeadBucketResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into HeadBucketResponse") + } + return +} + +// headBucket implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) headBucket(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodHead, "/n/{namespaceName}/b/{bucketName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response HeadBucketResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// HeadObject Gets the user-defined metadata and entity tag (ETag) for an object. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/HeadObject.go.html to see an example of how to use HeadObject API. +func (client ObjectStorageClient) HeadObject(ctx context.Context, request HeadObjectRequest) (response HeadObjectResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.headObject, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = HeadObjectResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = HeadObjectResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(HeadObjectResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into HeadObjectResponse") + } + return +} + +// headObject implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) headObject(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodHead, "/n/{namespaceName}/b/{bucketName}/o/{objectName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response HeadObjectResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListBuckets Gets a list of all BucketSummary items in a compartment. A BucketSummary contains only summary fields for the bucket +// and does not contain fields like the user-defined metadata. +// ListBuckets returns a BucketSummary containing at most 1000 buckets. To paginate through more buckets, use the returned +// `opc-next-page` value with the `page` request parameter. +// To use this and other API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListBuckets.go.html to see an example of how to use ListBuckets API. +func (client ObjectStorageClient) ListBuckets(ctx context.Context, request ListBucketsRequest) (response ListBucketsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listBuckets, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListBucketsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListBucketsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListBucketsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListBucketsResponse") + } + return +} + +// listBuckets implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) listBuckets(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}/b", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListBucketsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListMultipartUploadParts Lists the parts of an in-progress multipart upload. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListMultipartUploadParts.go.html to see an example of how to use ListMultipartUploadParts API. +func (client ObjectStorageClient) ListMultipartUploadParts(ctx context.Context, request ListMultipartUploadPartsRequest) (response ListMultipartUploadPartsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listMultipartUploadParts, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListMultipartUploadPartsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListMultipartUploadPartsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListMultipartUploadPartsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListMultipartUploadPartsResponse") + } + return +} + +// listMultipartUploadParts implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) listMultipartUploadParts(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}/b/{bucketName}/u/{objectName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListMultipartUploadPartsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListMultipartUploads Lists all of the in-progress multipart uploads for the given bucket in the given Object Storage namespace. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListMultipartUploads.go.html to see an example of how to use ListMultipartUploads API. +func (client ObjectStorageClient) ListMultipartUploads(ctx context.Context, request ListMultipartUploadsRequest) (response ListMultipartUploadsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listMultipartUploads, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListMultipartUploadsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListMultipartUploadsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListMultipartUploadsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListMultipartUploadsResponse") + } + return +} + +// listMultipartUploads implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) listMultipartUploads(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}/b/{bucketName}/u", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListMultipartUploadsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListObjectVersions Lists the object versions in a bucket. +// ListObjectVersions returns an ObjectVersionCollection containing at most 1000 object versions. To paginate through +// more object versions, use the returned `opc-next-page` value with the `page` request parameter. +// To use this and other API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListObjectVersions.go.html to see an example of how to use ListObjectVersions API. +func (client ObjectStorageClient) ListObjectVersions(ctx context.Context, request ListObjectVersionsRequest) (response ListObjectVersionsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listObjectVersions, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListObjectVersionsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListObjectVersionsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListObjectVersionsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListObjectVersionsResponse") + } + return +} + +// listObjectVersions implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) listObjectVersions(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}/b/{bucketName}/objectversions", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListObjectVersionsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListObjects Lists the objects in a bucket. By default, ListObjects returns object names only. See the `fields` +// parameter for other fields that you can optionally include in ListObjects response. +// ListObjects returns at most 1000 objects. To paginate through more objects, use the returned 'nextStartWith' +// value with the 'start' parameter. To filter which objects ListObjects returns, use the 'start' and 'end' +// parameters. +// To use this and other API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListObjects.go.html to see an example of how to use ListObjects API. +func (client ObjectStorageClient) ListObjects(ctx context.Context, request ListObjectsRequest) (response ListObjectsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listObjects, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListObjectsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListObjectsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListObjectsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListObjectsResponse") + } + return +} + +// listObjects implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) listObjects(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}/b/{bucketName}/o", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListObjectsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListPreauthenticatedRequests Lists pre-authenticated requests for the bucket. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListPreauthenticatedRequests.go.html to see an example of how to use ListPreauthenticatedRequests API. +func (client ObjectStorageClient) ListPreauthenticatedRequests(ctx context.Context, request ListPreauthenticatedRequestsRequest) (response ListPreauthenticatedRequestsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listPreauthenticatedRequests, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListPreauthenticatedRequestsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListPreauthenticatedRequestsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListPreauthenticatedRequestsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListPreauthenticatedRequestsResponse") + } + return +} + +// listPreauthenticatedRequests implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) listPreauthenticatedRequests(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}/b/{bucketName}/p", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListPreauthenticatedRequestsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListReplicationPolicies List the replication policies associated with a bucket. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListReplicationPolicies.go.html to see an example of how to use ListReplicationPolicies API. +func (client ObjectStorageClient) ListReplicationPolicies(ctx context.Context, request ListReplicationPoliciesRequest) (response ListReplicationPoliciesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listReplicationPolicies, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListReplicationPoliciesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListReplicationPoliciesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListReplicationPoliciesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListReplicationPoliciesResponse") + } + return +} + +// listReplicationPolicies implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) listReplicationPolicies(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}/b/{bucketName}/replicationPolicies", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListReplicationPoliciesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListReplicationSources List the replication sources of a destination bucket. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListReplicationSources.go.html to see an example of how to use ListReplicationSources API. +func (client ObjectStorageClient) ListReplicationSources(ctx context.Context, request ListReplicationSourcesRequest) (response ListReplicationSourcesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listReplicationSources, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListReplicationSourcesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListReplicationSourcesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListReplicationSourcesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListReplicationSourcesResponse") + } + return +} + +// listReplicationSources implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) listReplicationSources(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}/b/{bucketName}/replicationSources", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListReplicationSourcesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListRetentionRules List the retention rules for a bucket. The retention rules are sorted based on creation time, +// with the most recently created retention rule returned first. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListRetentionRules.go.html to see an example of how to use ListRetentionRules API. +func (client ObjectStorageClient) ListRetentionRules(ctx context.Context, request ListRetentionRulesRequest) (response ListRetentionRulesResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listRetentionRules, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListRetentionRulesResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListRetentionRulesResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListRetentionRulesResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListRetentionRulesResponse") + } + return +} + +// listRetentionRules implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) listRetentionRules(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/n/{namespaceName}/b/{bucketName}/retentionRules", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListRetentionRulesResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListWorkRequestErrors Lists the errors of the work request with the given ID. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListWorkRequestErrors.go.html to see an example of how to use ListWorkRequestErrors API. +func (client ObjectStorageClient) ListWorkRequestErrors(ctx context.Context, request ListWorkRequestErrorsRequest) (response ListWorkRequestErrorsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listWorkRequestErrors, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListWorkRequestErrorsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListWorkRequestErrorsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListWorkRequestErrorsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListWorkRequestErrorsResponse") + } + return +} + +// listWorkRequestErrors implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) listWorkRequestErrors(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/workRequests/{workRequestId}/errors", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListWorkRequestErrorsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListWorkRequestLogs Lists the logs of the work request with the given ID. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListWorkRequestLogs.go.html to see an example of how to use ListWorkRequestLogs API. +func (client ObjectStorageClient) ListWorkRequestLogs(ctx context.Context, request ListWorkRequestLogsRequest) (response ListWorkRequestLogsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listWorkRequestLogs, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListWorkRequestLogsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListWorkRequestLogsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListWorkRequestLogsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListWorkRequestLogsResponse") + } + return +} + +// listWorkRequestLogs implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) listWorkRequestLogs(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/workRequests/{workRequestId}/logs", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListWorkRequestLogsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListWorkRequests Lists the work requests in a compartment. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ListWorkRequests.go.html to see an example of how to use ListWorkRequests API. +func (client ObjectStorageClient) ListWorkRequests(ctx context.Context, request ListWorkRequestsRequest) (response ListWorkRequestsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listWorkRequests, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListWorkRequestsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListWorkRequestsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListWorkRequestsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListWorkRequestsResponse") + } + return +} + +// listWorkRequests implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) listWorkRequests(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/workRequests", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListWorkRequestsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// MakeBucketWritable Stops replication to the destination bucket and removes the replication policy. When the replication +// policy was created, this destination bucket became read-only except for new and changed objects replicated +// automatically from the source bucket. MakeBucketWritable removes the replication policy. This bucket is no +// longer the target for replication and is now writable, allowing users to make changes to bucket contents. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/MakeBucketWritable.go.html to see an example of how to use MakeBucketWritable API. +func (client ObjectStorageClient) MakeBucketWritable(ctx context.Context, request MakeBucketWritableRequest) (response MakeBucketWritableResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.makeBucketWritable, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = MakeBucketWritableResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = MakeBucketWritableResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(MakeBucketWritableResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into MakeBucketWritableResponse") + } + return +} + +// makeBucketWritable implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) makeBucketWritable(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/n/{namespaceName}/b/{bucketName}/actions/makeBucketWritable", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response MakeBucketWritableResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// PutObject Creates a new object or overwrites an existing object with the same name. The maximum object size allowed by +// PutObject is 50 GiB. +// See Object Names (https://docs.cloud.oracle.com/Content/Object/Tasks/managingobjects.htm#namerequirements) +// for object naming requirements. +// See Special Instructions for Object Storage PUT (https://docs.cloud.oracle.com/Content/API/Concepts/signingrequests.htm#ObjectStoragePut) +// for request signature requirements. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/PutObject.go.html to see an example of how to use PutObject API. +func (client ObjectStorageClient) PutObject(ctx context.Context, request PutObjectRequest) (response PutObjectResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.putObject, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = PutObjectResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = PutObjectResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(PutObjectResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into PutObjectResponse") + } + return +} + +// putObject implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) putObject(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + if !common.IsEnvVarFalse(common.UsingExpectHeaderEnvVar) { + extraHeaders["Expect"] = "100-continue" + } + httpRequest, err := request.HTTPRequest(http.MethodPut, "/n/{namespaceName}/b/{bucketName}/o/{objectName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response PutObjectResponse + var httpResponse *http.Response + var customSigner common.HTTPRequestSigner + excludeBodySigningPredicate := func(r *http.Request) bool { return false } + customSigner, err = common.NewSignerFromOCIRequestSigner(client.Signer, excludeBodySigningPredicate) + + //if there was an error overriding the signer, then use the signer from the client itself + if err != nil { + customSigner = client.Signer + } + + //Execute the request with a custom signer + httpResponse, err = client.CallWithDetails(ctx, &httpRequest, common.ClientCallDetails{Signer: customSigner}) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// PutObjectLifecyclePolicy Creates or replaces the object lifecycle policy for the bucket. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/PutObjectLifecyclePolicy.go.html to see an example of how to use PutObjectLifecyclePolicy API. +func (client ObjectStorageClient) PutObjectLifecyclePolicy(ctx context.Context, request PutObjectLifecyclePolicyRequest) (response PutObjectLifecyclePolicyResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.putObjectLifecyclePolicy, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = PutObjectLifecyclePolicyResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = PutObjectLifecyclePolicyResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(PutObjectLifecyclePolicyResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into PutObjectLifecyclePolicyResponse") + } + return +} + +// putObjectLifecyclePolicy implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) putObjectLifecyclePolicy(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/n/{namespaceName}/b/{bucketName}/l", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response PutObjectLifecyclePolicyResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ReencryptBucket Re-encrypts the unique data encryption key that encrypts each object written to the bucket by using the most recent +// version of the master encryption key assigned to the bucket. (All data encryption keys are encrypted by a master +// encryption key. Master encryption keys are assigned to buckets and managed by Oracle by default, but you can assign +// a key that you created and control through the Oracle Cloud Infrastructure Key Management service.) The kmsKeyId property +// of the bucket determines which master encryption key is assigned to the bucket. If you assigned a different Key Management +// master encryption key to the bucket, you can call this API to re-encrypt all data encryption keys with the newly +// assigned key. Similarly, you might want to re-encrypt all data encryption keys if the assigned key has been rotated to +// a new key version since objects were last added to the bucket. If you call this API and there is no kmsKeyId associated +// with the bucket, the call will fail. +// Calling this API starts a work request task to re-encrypt the data encryption key of all objects in the bucket. Only +// objects created before the time of the API call will be re-encrypted. The call can take a long time, depending on how many +// objects are in the bucket and how big they are. This API returns a work request ID that you can use to retrieve the status +// of the work request task. +// All the versions of objects will be re-encrypted whether versioning is enabled or suspended at the bucket. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ReencryptBucket.go.html to see an example of how to use ReencryptBucket API. +func (client ObjectStorageClient) ReencryptBucket(ctx context.Context, request ReencryptBucketRequest) (response ReencryptBucketResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.reencryptBucket, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ReencryptBucketResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ReencryptBucketResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ReencryptBucketResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ReencryptBucketResponse") + } + return +} + +// reencryptBucket implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) reencryptBucket(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/n/{namespaceName}/b/{bucketName}/actions/reencrypt", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ReencryptBucketResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ReencryptObject Re-encrypts the data encryption keys that encrypt the object and its chunks. By default, when you create a bucket, the Object Storage +// service manages the master encryption key used to encrypt each object's data encryption keys. The encryption mechanism that you specify for +// the bucket applies to the objects it contains. +// You can alternatively employ one of these encryption strategies for an object: +// - You can assign a key that you created and control through the Oracle Cloud Infrastructure Vault service. +// - You can encrypt an object using your own encryption key. The key you supply is known as a customer-provided encryption key (SSE-C). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ReencryptObject.go.html to see an example of how to use ReencryptObject API. +func (client ObjectStorageClient) ReencryptObject(ctx context.Context, request ReencryptObjectRequest) (response ReencryptObjectResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.reencryptObject, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ReencryptObjectResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ReencryptObjectResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ReencryptObjectResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ReencryptObjectResponse") + } + return +} + +// reencryptObject implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) reencryptObject(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/n/{namespaceName}/b/{bucketName}/actions/reencrypt/{objectName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ReencryptObjectResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// RenameObject Rename an object in the given Object Storage namespace. +// See Object Names (https://docs.cloud.oracle.com/Content/Object/Tasks/managingobjects.htm#namerequirements) +// for object naming requirements. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/RenameObject.go.html to see an example of how to use RenameObject API. +func (client ObjectStorageClient) RenameObject(ctx context.Context, request RenameObjectRequest) (response RenameObjectResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.renameObject, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = RenameObjectResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = RenameObjectResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(RenameObjectResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into RenameObjectResponse") + } + return +} + +// renameObject implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) renameObject(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/n/{namespaceName}/b/{bucketName}/actions/renameObject", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response RenameObjectResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// RestoreObjects Restores one or more objects specified by the objectName parameter. +// By default objects will be restored for 24 hours. Duration can be configured using the hours parameter. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/RestoreObjects.go.html to see an example of how to use RestoreObjects API. +func (client ObjectStorageClient) RestoreObjects(ctx context.Context, request RestoreObjectsRequest) (response RestoreObjectsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.restoreObjects, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = RestoreObjectsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = RestoreObjectsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(RestoreObjectsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into RestoreObjectsResponse") + } + return +} + +// restoreObjects implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) restoreObjects(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/n/{namespaceName}/b/{bucketName}/actions/restoreObjects", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response RestoreObjectsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateBucket Performs a partial or full update of a bucket's user-defined metadata. +// Use UpdateBucket to move a bucket from one compartment to another within the same tenancy. Supply the compartmentID +// of the compartment that you want to move the bucket to. For more information about moving resources between compartments, +// see Moving Resources to a Different Compartment (https://docs.cloud.oracle.com/iaas/Content/Identity/Tasks/managingcompartments.htm#moveRes). +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/UpdateBucket.go.html to see an example of how to use UpdateBucket API. +func (client ObjectStorageClient) UpdateBucket(ctx context.Context, request UpdateBucketRequest) (response UpdateBucketResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateBucket, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateBucketResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateBucketResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateBucketResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateBucketResponse") + } + return +} + +// updateBucket implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) updateBucket(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/n/{namespaceName}/b/{bucketName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateBucketResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateNamespaceMetadata By default, buckets created using the Amazon S3 Compatibility API or the Swift API are created in the root +// compartment of the Oracle Cloud Infrastructure tenancy. +// You can change the default Swift/Amazon S3 compartmentId designation to a different compartmentId. All +// subsequent bucket creations will use the new default compartment, but no previously created +// buckets will be modified. A user must have OBJECTSTORAGE_NAMESPACE_UPDATE permission to make changes to the default +// compartments for Amazon S3 and Swift. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/UpdateNamespaceMetadata.go.html to see an example of how to use UpdateNamespaceMetadata API. +func (client ObjectStorageClient) UpdateNamespaceMetadata(ctx context.Context, request UpdateNamespaceMetadataRequest) (response UpdateNamespaceMetadataResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateNamespaceMetadata, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateNamespaceMetadataResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateNamespaceMetadataResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateNamespaceMetadataResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateNamespaceMetadataResponse") + } + return +} + +// updateNamespaceMetadata implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) updateNamespaceMetadata(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/n/{namespaceName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateNamespaceMetadataResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateObjectStorageTier Changes the storage tier of the object specified by the objectName parameter. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/UpdateObjectStorageTier.go.html to see an example of how to use UpdateObjectStorageTier API. +func (client ObjectStorageClient) UpdateObjectStorageTier(ctx context.Context, request UpdateObjectStorageTierRequest) (response UpdateObjectStorageTierResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateObjectStorageTier, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateObjectStorageTierResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateObjectStorageTierResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateObjectStorageTierResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateObjectStorageTierResponse") + } + return +} + +// updateObjectStorageTier implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) updateObjectStorageTier(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPost, "/n/{namespaceName}/b/{bucketName}/actions/updateObjectStorageTier", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateObjectStorageTierResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UpdateRetentionRule Updates the specified retention rule. Rule changes take effect typically within 30 seconds. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/UpdateRetentionRule.go.html to see an example of how to use UpdateRetentionRule API. +func (client ObjectStorageClient) UpdateRetentionRule(ctx context.Context, request UpdateRetentionRuleRequest) (response UpdateRetentionRuleResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.updateRetentionRule, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UpdateRetentionRuleResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UpdateRetentionRuleResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UpdateRetentionRuleResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UpdateRetentionRuleResponse") + } + return +} + +// updateRetentionRule implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) updateRetentionRule(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodPut, "/n/{namespaceName}/b/{bucketName}/retentionRules/{retentionRuleId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UpdateRetentionRuleResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// UploadPart Uploads a single part of a multipart upload. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/UploadPart.go.html to see an example of how to use UploadPart API. +func (client ObjectStorageClient) UploadPart(ctx context.Context, request UploadPartRequest) (response UploadPartResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.uploadPart, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = UploadPartResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = UploadPartResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(UploadPartResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into UploadPartResponse") + } + return +} + +// uploadPart implements the OCIOperation interface (enables retrying operations) +func (client ObjectStorageClient) uploadPart(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + if !common.IsEnvVarFalse(common.UsingExpectHeaderEnvVar) { + extraHeaders["Expect"] = "100-continue" + } + httpRequest, err := request.HTTPRequest(http.MethodPut, "/n/{namespaceName}/b/{bucketName}/u/{objectName}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response UploadPartResponse + var httpResponse *http.Response + var customSigner common.HTTPRequestSigner + excludeBodySigningPredicate := func(r *http.Request) bool { return false } + customSigner, err = common.NewSignerFromOCIRequestSigner(client.Signer, excludeBodySigningPredicate) + + //if there was an error overriding the signer, then use the signer from the client itself + if err != nil { + customSigner = client.Signer + } + + //Execute the request with a custom signer + httpResponse, err = client.CallWithDetails(ctx, &httpRequest, common.ClientCallDetails{Signer: customSigner}) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/pattern_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/pattern_details.go new file mode 100644 index 000000000..0c1f0e902 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/pattern_details.go @@ -0,0 +1,64 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PatternDetails Specifying inclusion and exclusion patterns. +type PatternDetails struct { + + // An array of glob patterns to match the object names to include. An empty array includes all objects in the + // bucket. Exclusion patterns take precedence over inclusion patterns. + // A Glob pattern is a sequence of characters to match text. Any character that appears in the pattern, other + // than the special pattern characters described below, matches itself. + // Glob patterns must be between 1 and 1024 characters. + // The special pattern characters have the following meanings: + // \ Escapes the following character + // * Matches any string of characters. + // ? Matches any single character . + // [...] Matches a group of characters. A group of characters can be: + // A set of characters, for example: [Zafg9@]. This matches any character in the brackets. + // A range of characters, for example: [a-z]. This matches any character in the range. + // [a-f] is equivalent to [abcdef]. + // For character ranges only the CHARACTER-CHARACTER pattern is supported. + // [ab-yz] is not valid + // [a-mn-z] is not valid + // Character ranges can not start with ^ or : + // To include a '-' in the range, make it the first or last character. + InclusionPatterns []string `mandatory:"false" json:"inclusionPatterns"` + + // An array of glob patterns to match the object names to exclude. An empty array is ignored. Exclusion + // patterns take precedence over inclusion patterns. + // A Glob pattern is a sequence of characters to match text. Any character that appears in the pattern, other + // than the special pattern characters described below, matches itself. + // Glob patterns must be between 1 and 1024 characters. + // The special pattern characters have the following meanings: + // \ Escapes the following character + // * Matches any string of characters. + // ? Matches any single character . + // [...] Matches a group of characters. A group of characters can be: + // A set of characters, for example: [Zafg9@]. This matches any character in the brackets. + // A range of characters, for example: [a-z]. This matches any character in the range. + // [a-f] is equivalent to [abcdef]. + // For character ranges only the CHARACTER-CHARACTER pattern is supported. + // [ab-yz] is not valid + // [a-mn-z] is not valid + // Character ranges can not start with ^ or : + // To include a '-' in the range, make it the first or last character. + ExclusionPatterns []string `mandatory:"false" json:"exclusionPatterns"` +} + +func (m PatternDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/preauthenticated_request.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/preauthenticated_request.go new file mode 100644 index 000000000..d2fbb2279 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/preauthenticated_request.go @@ -0,0 +1,114 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PreauthenticatedRequest Pre-authenticated requests provide a way to let users access a bucket or an object without having their own credentials. +// When you create a pre-authenticated request, a unique URL is generated. Users in your organization, partners, or third +// parties can use this URL to access the targets identified in the pre-authenticated request. +// See Using Pre-Authenticated Requests (https://docs.cloud.oracle.com/Content/Object/Tasks/usingpreauthenticatedrequests.htm). +// To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, talk to an +// administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type PreauthenticatedRequest struct { + + // The unique identifier to use when directly addressing the pre-authenticated request. + Id *string `mandatory:"true" json:"id"` + + // The user-provided name of the pre-authenticated request. + Name *string `mandatory:"true" json:"name"` + + // The URI to embed in the URL when using the pre-authenticated request. + AccessUri *string `mandatory:"true" json:"accessUri"` + + // The operation that can be performed on this resource. + AccessType PreauthenticatedRequestAccessTypeEnum `mandatory:"true" json:"accessType"` + + // The expiration date for the pre-authenticated request as per RFC 3339 (https://tools.ietf.org/html/rfc3339). After + // this date the pre-authenticated request will no longer be valid. + TimeExpires *common.SDKTime `mandatory:"true" json:"timeExpires"` + + // The date when the pre-authenticated request was created as per specification + // RFC 3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The name of the object that is being granted access to by the pre-authenticated request. Avoid entering confidential + // information. The object name can be null and if so, the pre-authenticated request grants access to the entire bucket. + // Example: test/object1.log + ObjectName *string `mandatory:"false" json:"objectName"` + + // Specifies whether a list operation is allowed on a PAR with accessType "AnyObjectRead" or "AnyObjectReadWrite". + // Deny: Prevents the user from performing a list operation. + // ListObjects: Authorizes the user to perform a list operation. + BucketListingAction PreauthenticatedRequestBucketListingActionEnum `mandatory:"false" json:"bucketListingAction,omitempty"` +} + +func (m PreauthenticatedRequest) String() string { + return common.PointerString(m) +} + +// PreauthenticatedRequestBucketListingActionEnum Enum with underlying type: string +type PreauthenticatedRequestBucketListingActionEnum string + +// Set of constants representing the allowable values for PreauthenticatedRequestBucketListingActionEnum +const ( + PreauthenticatedRequestBucketListingActionDeny PreauthenticatedRequestBucketListingActionEnum = "Deny" + PreauthenticatedRequestBucketListingActionListobjects PreauthenticatedRequestBucketListingActionEnum = "ListObjects" +) + +var mappingPreauthenticatedRequestBucketListingAction = map[string]PreauthenticatedRequestBucketListingActionEnum{ + "Deny": PreauthenticatedRequestBucketListingActionDeny, + "ListObjects": PreauthenticatedRequestBucketListingActionListobjects, +} + +// GetPreauthenticatedRequestBucketListingActionEnumValues Enumerates the set of values for PreauthenticatedRequestBucketListingActionEnum +func GetPreauthenticatedRequestBucketListingActionEnumValues() []PreauthenticatedRequestBucketListingActionEnum { + values := make([]PreauthenticatedRequestBucketListingActionEnum, 0) + for _, v := range mappingPreauthenticatedRequestBucketListingAction { + values = append(values, v) + } + return values +} + +// PreauthenticatedRequestAccessTypeEnum Enum with underlying type: string +type PreauthenticatedRequestAccessTypeEnum string + +// Set of constants representing the allowable values for PreauthenticatedRequestAccessTypeEnum +const ( + PreauthenticatedRequestAccessTypeObjectread PreauthenticatedRequestAccessTypeEnum = "ObjectRead" + PreauthenticatedRequestAccessTypeObjectwrite PreauthenticatedRequestAccessTypeEnum = "ObjectWrite" + PreauthenticatedRequestAccessTypeObjectreadwrite PreauthenticatedRequestAccessTypeEnum = "ObjectReadWrite" + PreauthenticatedRequestAccessTypeAnyobjectwrite PreauthenticatedRequestAccessTypeEnum = "AnyObjectWrite" + PreauthenticatedRequestAccessTypeAnyobjectread PreauthenticatedRequestAccessTypeEnum = "AnyObjectRead" + PreauthenticatedRequestAccessTypeAnyobjectreadwrite PreauthenticatedRequestAccessTypeEnum = "AnyObjectReadWrite" +) + +var mappingPreauthenticatedRequestAccessType = map[string]PreauthenticatedRequestAccessTypeEnum{ + "ObjectRead": PreauthenticatedRequestAccessTypeObjectread, + "ObjectWrite": PreauthenticatedRequestAccessTypeObjectwrite, + "ObjectReadWrite": PreauthenticatedRequestAccessTypeObjectreadwrite, + "AnyObjectWrite": PreauthenticatedRequestAccessTypeAnyobjectwrite, + "AnyObjectRead": PreauthenticatedRequestAccessTypeAnyobjectread, + "AnyObjectReadWrite": PreauthenticatedRequestAccessTypeAnyobjectreadwrite, +} + +// GetPreauthenticatedRequestAccessTypeEnumValues Enumerates the set of values for PreauthenticatedRequestAccessTypeEnum +func GetPreauthenticatedRequestAccessTypeEnumValues() []PreauthenticatedRequestAccessTypeEnum { + values := make([]PreauthenticatedRequestAccessTypeEnum, 0) + for _, v := range mappingPreauthenticatedRequestAccessType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/preauthenticated_request_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/preauthenticated_request_summary.go new file mode 100644 index 000000000..a5ddd35cc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/preauthenticated_request_summary.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PreauthenticatedRequestSummary Get summary information about pre-authenticated requests. +type PreauthenticatedRequestSummary struct { + + // The unique identifier to use when directly addressing the pre-authenticated request. + Id *string `mandatory:"true" json:"id"` + + // The user-provided name of the pre-authenticated request. + Name *string `mandatory:"true" json:"name"` + + // The operation that can be performed on this resource. + AccessType PreauthenticatedRequestSummaryAccessTypeEnum `mandatory:"true" json:"accessType"` + + // The expiration date for the pre-authenticated request as per RFC 3339 (https://tools.ietf.org/html/rfc3339). After this date the pre-authenticated request will no longer be valid. + TimeExpires *common.SDKTime `mandatory:"true" json:"timeExpires"` + + // The date when the pre-authenticated request was created as per RFC 3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The name of object that is being granted access to by the pre-authenticated request. This can be null and if it is, + // the pre-authenticated request grants access to the entire bucket. + ObjectName *string `mandatory:"false" json:"objectName"` + + // Specifies whether a list operation is allowed on a PAR with accessType "AnyObjectRead" or "AnyObjectReadWrite". + // Deny: Prevents the user from performing a list operation. + // ListObjects: Authorizes the user to perform a list operation. + BucketListingAction PreauthenticatedRequestBucketListingActionEnum `mandatory:"false" json:"bucketListingAction,omitempty"` +} + +func (m PreauthenticatedRequestSummary) String() string { + return common.PointerString(m) +} + +// PreauthenticatedRequestSummaryAccessTypeEnum Enum with underlying type: string +type PreauthenticatedRequestSummaryAccessTypeEnum string + +// Set of constants representing the allowable values for PreauthenticatedRequestSummaryAccessTypeEnum +const ( + PreauthenticatedRequestSummaryAccessTypeObjectread PreauthenticatedRequestSummaryAccessTypeEnum = "ObjectRead" + PreauthenticatedRequestSummaryAccessTypeObjectwrite PreauthenticatedRequestSummaryAccessTypeEnum = "ObjectWrite" + PreauthenticatedRequestSummaryAccessTypeObjectreadwrite PreauthenticatedRequestSummaryAccessTypeEnum = "ObjectReadWrite" + PreauthenticatedRequestSummaryAccessTypeAnyobjectwrite PreauthenticatedRequestSummaryAccessTypeEnum = "AnyObjectWrite" + PreauthenticatedRequestSummaryAccessTypeAnyobjectread PreauthenticatedRequestSummaryAccessTypeEnum = "AnyObjectRead" + PreauthenticatedRequestSummaryAccessTypeAnyobjectreadwrite PreauthenticatedRequestSummaryAccessTypeEnum = "AnyObjectReadWrite" +) + +var mappingPreauthenticatedRequestSummaryAccessType = map[string]PreauthenticatedRequestSummaryAccessTypeEnum{ + "ObjectRead": PreauthenticatedRequestSummaryAccessTypeObjectread, + "ObjectWrite": PreauthenticatedRequestSummaryAccessTypeObjectwrite, + "ObjectReadWrite": PreauthenticatedRequestSummaryAccessTypeObjectreadwrite, + "AnyObjectWrite": PreauthenticatedRequestSummaryAccessTypeAnyobjectwrite, + "AnyObjectRead": PreauthenticatedRequestSummaryAccessTypeAnyobjectread, + "AnyObjectReadWrite": PreauthenticatedRequestSummaryAccessTypeAnyobjectreadwrite, +} + +// GetPreauthenticatedRequestSummaryAccessTypeEnumValues Enumerates the set of values for PreauthenticatedRequestSummaryAccessTypeEnum +func GetPreauthenticatedRequestSummaryAccessTypeEnumValues() []PreauthenticatedRequestSummaryAccessTypeEnum { + values := make([]PreauthenticatedRequestSummaryAccessTypeEnum, 0) + for _, v := range mappingPreauthenticatedRequestSummaryAccessType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/put_object_lifecycle_policy_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/put_object_lifecycle_policy_details.go new file mode 100644 index 000000000..e4159ef94 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/put_object_lifecycle_policy_details.go @@ -0,0 +1,27 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// PutObjectLifecyclePolicyDetails Creates a new object lifecycle policy for a bucket. +type PutObjectLifecyclePolicyDetails struct { + + // The bucket's set of lifecycle policy rules. + Items []ObjectLifecycleRule `mandatory:"false" json:"items"` +} + +func (m PutObjectLifecyclePolicyDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/put_object_lifecycle_policy_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/put_object_lifecycle_policy_request_response.go new file mode 100644 index 000000000..c4f0850e6 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/put_object_lifecycle_policy_request_response.go @@ -0,0 +1,95 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// PutObjectLifecyclePolicyRequest wrapper for the PutObjectLifecyclePolicy operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/PutObjectLifecyclePolicy.go.html to see an example of how to use PutObjectLifecyclePolicyRequest. +type PutObjectLifecyclePolicyRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The lifecycle policy to apply to the bucket. + PutObjectLifecyclePolicyDetails `contributesTo:"body"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // The entity tag (ETag) to match with the ETag of an existing resource. If the specified ETag matches the ETag of + // the existing resource, GET and HEAD requests will return the resource and PUT and POST requests will upload + // the resource. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // The entity tag (ETag) to avoid matching. The only valid value is '*', which indicates that the request should + // fail if the resource already exists. + IfNoneMatch *string `mandatory:"false" contributesTo:"header" name:"if-none-match"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request PutObjectLifecyclePolicyRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request PutObjectLifecyclePolicyRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request PutObjectLifecyclePolicyRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request PutObjectLifecyclePolicyRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// PutObjectLifecyclePolicyResponse wrapper for the PutObjectLifecyclePolicy operation +type PutObjectLifecyclePolicyResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The ObjectLifecyclePolicy instance + ObjectLifecyclePolicy `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, + // provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // The entity tag (ETag) for the object lifecycle policy. + ETag *string `presentIn:"header" name:"etag"` +} + +func (response PutObjectLifecyclePolicyResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response PutObjectLifecyclePolicyResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/put_object_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/put_object_request_response.go new file mode 100644 index 000000000..12569c33c --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/put_object_request_response.go @@ -0,0 +1,206 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "io" + "net/http" +) + +// PutObjectRequest wrapper for the PutObject operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/PutObject.go.html to see an example of how to use PutObjectRequest. +type PutObjectRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The name of the object. Avoid entering confidential information. + // Example: `test/object1.log` + ObjectName *string `mandatory:"true" contributesTo:"path" name:"objectName"` + + // The content length of the body. + ContentLength *int64 `mandatory:"false" contributesTo:"header" name:"Content-Length"` + + // The object to upload to the object store. + PutObjectBody io.ReadCloser `mandatory:"true" contributesTo:"body" encoding:"binary"` + + // The entity tag (ETag) to match with the ETag of an existing resource. If the specified ETag matches the ETag of + // the existing resource, GET and HEAD requests will return the resource and PUT and POST requests will upload + // the resource. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // The entity tag (ETag) to avoid matching. The only valid value is '*', which indicates that the request should + // fail if the resource already exists. + IfNoneMatch *string `mandatory:"false" contributesTo:"header" name:"if-none-match"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // 100-continue + Expect *string `mandatory:"false" contributesTo:"header" name:"Expect"` + + // The optional base-64 header that defines the encoded MD5 hash of the body. If the optional Content-MD5 header is present, Object + // Storage performs an integrity check on the body of the HTTP request by computing the MD5 hash for the body and comparing it to the + // MD5 hash supplied in the header. If the two hashes do not match, the object is rejected and an HTTP-400 Unmatched Content MD5 error + // is returned with the message: + // "The computed MD5 of the request body (ACTUAL_MD5) does not match the Content-MD5 header (HEADER_MD5)" + ContentMD5 *string `mandatory:"false" contributesTo:"header" name:"Content-MD5"` + + // The optional Content-Type header that defines the standard MIME type format of the object. Content type defaults to + // 'application/octet-stream' if not specified in the PutObject call. Specifying values for this header has no effect + // on Object Storage behavior. Programs that read the object determine what to do based on the value provided. For example, + // you could use this header to identify and perform special operations on text only objects. + ContentType *string `mandatory:"false" contributesTo:"header" name:"Content-Type"` + + // The optional Content-Language header that defines the content language of the object to upload. Specifying + // values for this header has no effect on Object Storage behavior. Programs that read the object determine what + // to do based on the value provided. For example, you could use this header to identify and differentiate objects + // based on a particular language. + ContentLanguage *string `mandatory:"false" contributesTo:"header" name:"Content-Language"` + + // The optional Content-Encoding header that defines the content encodings that were applied to the object to + // upload. Specifying values for this header has no effect on Object Storage behavior. Programs that read the + // object determine what to do based on the value provided. For example, you could use this header to determine + // what decoding mechanisms need to be applied to obtain the media-type specified by the Content-Type header of + // the object. + ContentEncoding *string `mandatory:"false" contributesTo:"header" name:"Content-Encoding"` + + // The optional Content-Disposition header that defines presentational information for the object to be + // returned in GetObject and HeadObject responses. Specifying values for this header has no effect on Object + // Storage behavior. Programs that read the object determine what to do based on the value provided. + // For example, you could use this header to let users download objects with custom filenames in a browser. + ContentDisposition *string `mandatory:"false" contributesTo:"header" name:"Content-Disposition"` + + // The optional Cache-Control header that defines the caching behavior value to be returned in GetObject and + // HeadObject responses. Specifying values for this header has no effect on Object Storage behavior. Programs + // that read the object determine what to do based on the value provided. + // For example, you could use this header to identify objects that require caching restrictions. + CacheControl *string `mandatory:"false" contributesTo:"header" name:"Cache-Control"` + + // The optional header that specifies "AES256" as the encryption algorithm. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerAlgorithm *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-algorithm"` + + // The optional header that specifies the base64-encoded 256-bit encryption key to use to encrypt or + // decrypt the data. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerKey *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-key"` + + // The optional header that specifies the base64-encoded SHA256 hash of the encryption key. This + // value is used to check the integrity of the encryption key. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerKeySha256 *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-key-sha256"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of a master encryption key used to call the Key + // Management service to generate a data encryption key or to encrypt or decrypt a data encryption key. + OpcSseKmsKeyId *string `mandatory:"false" contributesTo:"header" name:"opc-sse-kms-key-id"` + + // The storage tier that the object should be stored in. If not specified, the object will be stored in + // the same storage tier as the bucket. + StorageTier PutObjectStorageTierEnum `mandatory:"false" contributesTo:"header" name:"storage-tier"` + + // Optional user-defined metadata key and value. + OpcMeta map[string]string `mandatory:"false" contributesTo:"header-collection" prefix:"opc-meta-"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request PutObjectRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request PutObjectRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + httpRequest, err := common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) + if err == nil && binaryRequestBody.Seekable() { + common.UpdateRequestBinaryBody(&httpRequest, binaryRequestBody) + } + return httpRequest, err +} + +// BinaryRequestBody implements the OCIRequest interface +func (request PutObjectRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + rsc := common.NewOCIReadSeekCloser(request.PutObjectBody) + if rsc.Seekable() { + return rsc, true + } + return nil, true + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request PutObjectRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// PutObjectResponse wrapper for the PutObject operation +type PutObjectResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The base-64 encoded MD5 hash of the request body as computed by the server. + OpcContentMd5 *string `presentIn:"header" name:"opc-content-md5"` + + // The entity tag (ETag) for the object. + ETag *string `presentIn:"header" name:"etag"` + + // The time the object was modified, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.29). + LastModified *common.SDKTime `presentIn:"header" name:"last-modified"` + + // VersionId of the newly created object + VersionId *string `presentIn:"header" name:"version-id"` +} + +func (response PutObjectResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response PutObjectResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// PutObjectStorageTierEnum Enum with underlying type: string +type PutObjectStorageTierEnum string + +// Set of constants representing the allowable values for PutObjectStorageTierEnum +const ( + PutObjectStorageTierStandard PutObjectStorageTierEnum = "Standard" + PutObjectStorageTierInfrequentaccess PutObjectStorageTierEnum = "InfrequentAccess" + PutObjectStorageTierArchive PutObjectStorageTierEnum = "Archive" +) + +var mappingPutObjectStorageTier = map[string]PutObjectStorageTierEnum{ + "Standard": PutObjectStorageTierStandard, + "InfrequentAccess": PutObjectStorageTierInfrequentaccess, + "Archive": PutObjectStorageTierArchive, +} + +// GetPutObjectStorageTierEnumValues Enumerates the set of values for PutObjectStorageTierEnum +func GetPutObjectStorageTierEnumValues() []PutObjectStorageTierEnum { + values := make([]PutObjectStorageTierEnum, 0) + for _, v := range mappingPutObjectStorageTier { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/reencrypt_bucket_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/reencrypt_bucket_request_response.go new file mode 100644 index 000000000..422653467 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/reencrypt_bucket_request_response.go @@ -0,0 +1,81 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ReencryptBucketRequest wrapper for the ReencryptBucket operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ReencryptBucket.go.html to see an example of how to use ReencryptBucketRequest. +type ReencryptBucketRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ReencryptBucketRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ReencryptBucketRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ReencryptBucketRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ReencryptBucketRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ReencryptBucketResponse wrapper for the ReencryptBucket operation +type ReencryptBucketResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Unique Oracle-assigned identifier for the asynchronous request. If you need to contact Oracle about a + // particular request, provide this request ID. + OpcWorkRequestId *string `presentIn:"header" name:"opc-work-request-id"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ReencryptBucketResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ReencryptBucketResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/reencrypt_object_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/reencrypt_object_details.go new file mode 100644 index 000000000..0974887fc --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/reencrypt_object_details.go @@ -0,0 +1,42 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ReencryptObjectDetails The details used to re-encrypt the data encryption keys associated with an object. +// You can only specify either a kmsKeyId or an sseCustomerKey in the request payload, not both. +// If the request payload is empty, the object is encrypted using the encryption key assigned to the +// bucket. The bucket encryption mechanism can either be a master encryption key managed by Oracle or the Vault service. +// - The sseCustomerKey field specifies the customer-provided encryption key (SSE-C) that will be used to re-encrypt the data encryption keys of the +// object and its chunks. +// - The sourceSSECustomerKey field specifies information about the customer-provided encryption key that is currently +// associated with the object source. Specify a value for the sourceSSECustomerKey only if the object +// is encrypted with a customer-provided encryption key. +type ReencryptObjectDetails struct { + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the master encryption key used to call the Vault + // service to re-encrypt the data encryption keys associated with the object and its chunks. If the kmsKeyId value is + // empty, whether null or an empty string, the API will perform re-encryption by using the kmsKeyId associated with the + // bucket or the master encryption key managed by Oracle, depending on the bucket encryption mechanism. + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` + + SseCustomerKey *SseCustomerKeyDetails `mandatory:"false" json:"sseCustomerKey"` + + SourceSseCustomerKey *SseCustomerKeyDetails `mandatory:"false" json:"sourceSseCustomerKey"` +} + +func (m ReencryptObjectDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/reencrypt_object_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/reencrypt_object_request_response.go new file mode 100644 index 000000000..8459f6513 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/reencrypt_object_request_response.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ReencryptObjectRequest wrapper for the ReencryptObject operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/ReencryptObject.go.html to see an example of how to use ReencryptObjectRequest. +type ReencryptObjectRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The name of the object. Avoid entering confidential information. + // Example: `test/object1.log` + ObjectName *string `mandatory:"true" contributesTo:"path" name:"objectName"` + + // Request object for re-encrypting the data encryption key associated with an object. + ReencryptObjectDetails `contributesTo:"body"` + + // VersionId used to identify a particular version of the object + VersionId *string `mandatory:"false" contributesTo:"query" name:"versionId"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ReencryptObjectRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ReencryptObjectRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ReencryptObjectRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ReencryptObjectRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ReencryptObjectResponse wrapper for the ReencryptObject operation +type ReencryptObjectResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ReencryptObjectResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ReencryptObjectResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/rename_object_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/rename_object_details.go new file mode 100644 index 000000000..b6a6117b7 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/rename_object_details.go @@ -0,0 +1,42 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RenameObjectDetails To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type RenameObjectDetails struct { + + // The name of the source object to be renamed. + SourceName *string `mandatory:"true" json:"sourceName"` + + // The new name of the source object. Avoid entering confidential information. + NewName *string `mandatory:"true" json:"newName"` + + // The if-match entity tag (ETag) of the source object. + SrcObjIfMatchETag *string `mandatory:"false" json:"srcObjIfMatchETag"` + + // The if-match entity tag (ETag) of the new object. + NewObjIfMatchETag *string `mandatory:"false" json:"newObjIfMatchETag"` + + // The if-none-match entity tag (ETag) of the new object. The only valid value is '*', which indicates + // request should fail if the new object already exists. + NewObjIfNoneMatchETag *string `mandatory:"false" json:"newObjIfNoneMatchETag"` +} + +func (m RenameObjectDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/rename_object_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/rename_object_request_response.go new file mode 100644 index 000000000..7b41bb1d1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/rename_object_request_response.go @@ -0,0 +1,89 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// RenameObjectRequest wrapper for the RenameObject operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/RenameObject.go.html to see an example of how to use RenameObjectRequest. +type RenameObjectRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The sourceName and newName of rename operation. Avoid entering confidential information. + RenameObjectDetails `contributesTo:"body"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request RenameObjectRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request RenameObjectRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request RenameObjectRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request RenameObjectRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// RenameObjectResponse wrapper for the RenameObject operation +type RenameObjectResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The entity tag (ETag) for the object. + ETag *string `presentIn:"header" name:"etag"` + + // The time the object was modified, as described in RFC 2616 (https://tools.ietf.org/html/rfc2616#section-14.29). + LastModified *common.SDKTime `presentIn:"header" name:"last-modified"` + + // VersionId of the renamed object + VersionId *string `presentIn:"header" name:"version-id"` +} + +func (response RenameObjectResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response RenameObjectResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/replication_policy.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/replication_policy.go new file mode 100644 index 000000000..f34862799 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/replication_policy.go @@ -0,0 +1,73 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ReplicationPolicy The details of a replication policy. +type ReplicationPolicy struct { + + // The id of the replication policy. + Id *string `mandatory:"true" json:"id"` + + // The name of the policy. + Name *string `mandatory:"true" json:"name"` + + // The destination region to replicate to, for example "us-ashburn-1". + DestinationRegionName *string `mandatory:"true" json:"destinationRegionName"` + + // The bucket to replicate to in the destination region. Replication policy creation does not automatically + // create a destination bucket. Create the destination bucket before creating the policy. + DestinationBucketName *string `mandatory:"true" json:"destinationBucketName"` + + // The date when the replication policy was created as per RFC 3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // Changes made to the source bucket before this time has been replicated. + TimeLastSync *common.SDKTime `mandatory:"true" json:"timeLastSync"` + + // The replication status of the policy. If the status is CLIENT_ERROR, once the user fixes the issue + // described in the status message, the status will become ACTIVE. + Status ReplicationPolicyStatusEnum `mandatory:"true" json:"status"` + + // A human-readable description of the status. + StatusMessage *string `mandatory:"true" json:"statusMessage"` +} + +func (m ReplicationPolicy) String() string { + return common.PointerString(m) +} + +// ReplicationPolicyStatusEnum Enum with underlying type: string +type ReplicationPolicyStatusEnum string + +// Set of constants representing the allowable values for ReplicationPolicyStatusEnum +const ( + ReplicationPolicyStatusActive ReplicationPolicyStatusEnum = "ACTIVE" + ReplicationPolicyStatusClientError ReplicationPolicyStatusEnum = "CLIENT_ERROR" +) + +var mappingReplicationPolicyStatus = map[string]ReplicationPolicyStatusEnum{ + "ACTIVE": ReplicationPolicyStatusActive, + "CLIENT_ERROR": ReplicationPolicyStatusClientError, +} + +// GetReplicationPolicyStatusEnumValues Enumerates the set of values for ReplicationPolicyStatusEnum +func GetReplicationPolicyStatusEnumValues() []ReplicationPolicyStatusEnum { + values := make([]ReplicationPolicyStatusEnum, 0) + for _, v := range mappingReplicationPolicyStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/replication_policy_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/replication_policy_summary.go new file mode 100644 index 000000000..8153b1269 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/replication_policy_summary.go @@ -0,0 +1,73 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ReplicationPolicySummary The summary of a replication policy. +type ReplicationPolicySummary struct { + + // The id of the replication policy. + Id *string `mandatory:"true" json:"id"` + + // The name of the policy. + Name *string `mandatory:"true" json:"name"` + + // The destination region to replicate to, for example "us-ashburn-1". + DestinationRegionName *string `mandatory:"true" json:"destinationRegionName"` + + // The bucket to replicate to in the destination region. Replication policy creation does not automatically + // create a destination bucket. Create the destination bucket before creating the policy. + DestinationBucketName *string `mandatory:"true" json:"destinationBucketName"` + + // The date when the replication policy was created as per RFC 3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // Changes made to the source bucket before this time has been replicated. + TimeLastSync *common.SDKTime `mandatory:"true" json:"timeLastSync"` + + // The replication status of the policy. If the status is CLIENT_ERROR, once the user fixes the issue + // described in the status message, the status will become ACTIVE. + Status ReplicationPolicySummaryStatusEnum `mandatory:"true" json:"status"` + + // A human-readable description of the status. + StatusMessage *string `mandatory:"true" json:"statusMessage"` +} + +func (m ReplicationPolicySummary) String() string { + return common.PointerString(m) +} + +// ReplicationPolicySummaryStatusEnum Enum with underlying type: string +type ReplicationPolicySummaryStatusEnum string + +// Set of constants representing the allowable values for ReplicationPolicySummaryStatusEnum +const ( + ReplicationPolicySummaryStatusActive ReplicationPolicySummaryStatusEnum = "ACTIVE" + ReplicationPolicySummaryStatusClientError ReplicationPolicySummaryStatusEnum = "CLIENT_ERROR" +) + +var mappingReplicationPolicySummaryStatus = map[string]ReplicationPolicySummaryStatusEnum{ + "ACTIVE": ReplicationPolicySummaryStatusActive, + "CLIENT_ERROR": ReplicationPolicySummaryStatusClientError, +} + +// GetReplicationPolicySummaryStatusEnumValues Enumerates the set of values for ReplicationPolicySummaryStatusEnum +func GetReplicationPolicySummaryStatusEnumValues() []ReplicationPolicySummaryStatusEnum { + values := make([]ReplicationPolicySummaryStatusEnum, 0) + for _, v := range mappingReplicationPolicySummaryStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/replication_source.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/replication_source.go new file mode 100644 index 000000000..d996ce7a9 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/replication_source.go @@ -0,0 +1,33 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// ReplicationSource The details of a replication source bucket that replicates to a target destination bucket. +type ReplicationSource struct { + + // The name of the policy. + PolicyName *string `mandatory:"true" json:"policyName"` + + // The source region replicating data from, for example "us-ashburn-1". + SourceRegionName *string `mandatory:"true" json:"sourceRegionName"` + + // The source bucket replicating data from. + SourceBucketName *string `mandatory:"true" json:"sourceBucketName"` +} + +func (m ReplicationSource) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/restore_objects_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/restore_objects_details.go new file mode 100644 index 000000000..8a10f55fb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/restore_objects_details.go @@ -0,0 +1,34 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RestoreObjectsDetails The representation of RestoreObjectsDetails +type RestoreObjectsDetails struct { + + // An object that is in an archive storage tier and needs to be restored. + ObjectName *string `mandatory:"true" json:"objectName"` + + // The number of hours for which this object will be restored. + // By default objects will be restored for 24 hours. You can instead configure the duration using the hours parameter. + Hours *int `mandatory:"false" json:"hours"` + + // The versionId of the object to restore. Current object version is used by default. + VersionId *string `mandatory:"false" json:"versionId"` +} + +func (m RestoreObjectsDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/restore_objects_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/restore_objects_request_response.go new file mode 100644 index 000000000..54d488cf1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/restore_objects_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// RestoreObjectsRequest wrapper for the RestoreObjects operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/RestoreObjects.go.html to see an example of how to use RestoreObjectsRequest. +type RestoreObjectsRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // Request to restore objects. + RestoreObjectsDetails `contributesTo:"body"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request RestoreObjectsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request RestoreObjectsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request RestoreObjectsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request RestoreObjectsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// RestoreObjectsResponse wrapper for the RestoreObjects operation +type RestoreObjectsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response RestoreObjectsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response RestoreObjectsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule.go new file mode 100644 index 000000000..9c69c2fad --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule.go @@ -0,0 +1,45 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RetentionRule The details of a retention rule. +type RetentionRule struct { + + // Unique identifier for the retention rule. + Id *string `mandatory:"true" json:"id"` + + // User specified name for the retention rule. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The entity tag (ETag) for the retention rule. + Etag *string `mandatory:"true" json:"etag"` + + // The date and time that the retention rule was created as per RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The date and time that the retention rule was modified as per RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeModified *common.SDKTime `mandatory:"true" json:"timeModified"` + + Duration *Duration `mandatory:"false" json:"duration"` + + // The date and time as per RFC 3339 (https://tools.ietf.org/html/rfc3339) after which this rule becomes locked. + // and can only be deleted by deleting the bucket. + TimeRuleLocked *common.SDKTime `mandatory:"false" json:"timeRuleLocked"` +} + +func (m RetentionRule) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule_collection.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule_collection.go new file mode 100644 index 000000000..904c2b956 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule_collection.go @@ -0,0 +1,27 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RetentionRuleCollection Retention rule collection. +type RetentionRuleCollection struct { + + // An array of retention rule summaries. + Items []RetentionRuleSummary `mandatory:"true" json:"items"` +} + +func (m RetentionRuleCollection) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule_details.go new file mode 100644 index 000000000..8615b7f0b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule_details.go @@ -0,0 +1,36 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RetentionRuleDetails The details to create or update a retention rule. +type RetentionRuleDetails struct { + + // A user-specified name for the retention rule. Names can be helpful in identifying retention rules. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + Duration *Duration `mandatory:"false" json:"duration"` + + // The date and time as per RFC 3339 (https://tools.ietf.org/html/rfc3339) after which this rule is locked + // and can only be deleted by deleting the bucket. Once a rule is locked, only increases in the duration are + // allowed and no other properties can be changed. This property cannot be updated for rules that are in a + // locked state. Specifying it when a duration is not specified is considered an error. + TimeRuleLocked *common.SDKTime `mandatory:"false" json:"timeRuleLocked"` +} + +func (m RetentionRuleDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule_summary.go new file mode 100644 index 000000000..57c543674 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/retention_rule_summary.go @@ -0,0 +1,45 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// RetentionRuleSummary The summary of a retention rule. +type RetentionRuleSummary struct { + + // Unique identifier for the retention rule. + Id *string `mandatory:"true" json:"id"` + + // User specified name for the retention rule. + DisplayName *string `mandatory:"true" json:"displayName"` + + // The entity tag (ETag) for the retention rule. + Etag *string `mandatory:"true" json:"etag"` + + // The date and time that the retention rule was created as per RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeCreated *common.SDKTime `mandatory:"true" json:"timeCreated"` + + // The date and time that the retention rule was modified as per RFC3339 (https://tools.ietf.org/html/rfc3339). + TimeModified *common.SDKTime `mandatory:"true" json:"timeModified"` + + Duration *Duration `mandatory:"false" json:"duration"` + + // The date and time as per RFC 3339 (https://tools.ietf.org/html/rfc3339) after which this rule becomes locked. + // and can only be deleted by deleting the bucket. + TimeRuleLocked *common.SDKTime `mandatory:"false" json:"timeRuleLocked"` +} + +func (m RetentionRuleSummary) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/sse_customer_key_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/sse_customer_key_details.go new file mode 100644 index 000000000..b02677e78 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/sse_customer_key_details.go @@ -0,0 +1,55 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// SseCustomerKeyDetails Specifies the details of the customer-provided encryption key (SSE-C) associated with an object. +type SseCustomerKeyDetails struct { + + // Specifies the encryption algorithm. The only supported value is "AES256". + Algorithm SseCustomerKeyDetailsAlgorithmEnum `mandatory:"true" json:"algorithm"` + + // Specifies the base64-encoded 256-bit encryption key to use to encrypt or decrypt the object data. + Key *string `mandatory:"true" json:"key"` + + // Specifies the base64-encoded SHA256 hash of the encryption key. This value is used to check the integrity + // of the encryption key. + KeySha256 *string `mandatory:"true" json:"keySha256"` +} + +func (m SseCustomerKeyDetails) String() string { + return common.PointerString(m) +} + +// SseCustomerKeyDetailsAlgorithmEnum Enum with underlying type: string +type SseCustomerKeyDetailsAlgorithmEnum string + +// Set of constants representing the allowable values for SseCustomerKeyDetailsAlgorithmEnum +const ( + SseCustomerKeyDetailsAlgorithmAes256 SseCustomerKeyDetailsAlgorithmEnum = "AES256" +) + +var mappingSseCustomerKeyDetailsAlgorithm = map[string]SseCustomerKeyDetailsAlgorithmEnum{ + "AES256": SseCustomerKeyDetailsAlgorithmAes256, +} + +// GetSseCustomerKeyDetailsAlgorithmEnumValues Enumerates the set of values for SseCustomerKeyDetailsAlgorithmEnum +func GetSseCustomerKeyDetailsAlgorithmEnumValues() []SseCustomerKeyDetailsAlgorithmEnum { + values := make([]SseCustomerKeyDetailsAlgorithmEnum, 0) + for _, v := range mappingSseCustomerKeyDetailsAlgorithm { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/storage_tier.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/storage_tier.go new file mode 100644 index 000000000..afe62bab1 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/storage_tier.go @@ -0,0 +1,37 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +// StorageTierEnum Enum with underlying type: string +type StorageTierEnum string + +// Set of constants representing the allowable values for StorageTierEnum +const ( + StorageTierStandard StorageTierEnum = "Standard" + StorageTierInfrequentAccess StorageTierEnum = "InfrequentAccess" + StorageTierArchive StorageTierEnum = "Archive" +) + +var mappingStorageTier = map[string]StorageTierEnum{ + "Standard": StorageTierStandard, + "InfrequentAccess": StorageTierInfrequentAccess, + "Archive": StorageTierArchive, +} + +// GetStorageTierEnumValues Enumerates the set of values for StorageTierEnum +func GetStorageTierEnumValues() []StorageTierEnum { + values := make([]StorageTierEnum, 0) + for _, v := range mappingStorageTier { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/file_uploader.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/file_uploader.go new file mode 100644 index 000000000..be71fc2fd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/file_uploader.go @@ -0,0 +1,209 @@ +// Copyright (c) 2016, 2018, 2020, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package transfer + +import ( + "context" + "errors" + "fmt" + "os" + "strings" + "sync" + + "github.com/oracle/oci-go-sdk/v54/common" + "github.com/oracle/oci-go-sdk/v54/objectstorage" +) + +// FileUploader is an interface to upload a file +type FileUploader interface { + // split file into multiple parts and uploads them to blob storage, then merge + UploadFileMultiparts(ctx context.Context, request UploadFileRequest) (response UploadResponse, err error) + + // uploads a file to blob storage via PutObject API + UploadFilePutObject(ctx context.Context, request UploadFileRequest) (response UploadResponse, err error) + + // resume a file upload, use it when UploadFile failed + ResumeUploadFile(ctx context.Context, uploadID string) (response UploadResponse, err error) +} + +type fileUpload struct { + uploadID string + manifest *multipartManifest + multipartUploader multipartUploader + fileUploadReqs map[string]UploadFileRequest // save user input to resume +} + +func (fileUpload *fileUpload) UploadFileMultiparts(ctx context.Context, request UploadFileRequest) (response UploadResponse, err error) { + file, err := os.Open(request.FilePath) + defer file.Close() + if err != nil { + return + } + + fi, err := file.Stat() + if err != nil { + return + } + + fileSize := fi.Size() + + uploadID, err := fileUpload.multipartUploader.createMultipartUpload(ctx, request.UploadRequest) + + if err != nil { + return + } + fileUpload.uploadID = uploadID + + if fileUpload.fileUploadReqs == nil { + fileUpload.fileUploadReqs = make(map[string]UploadFileRequest) + } + + if fileUpload.manifest == nil { + fileUpload.manifest = &multipartManifest{parts: make(map[string]map[int]uploadPart)} + } + + // save the request for later resume if needed + fileUpload.fileUploadReqs[uploadID] = request + + // UploadFileMultiparts closes the done channel when it returns + done := make(chan struct{}) + defer close(done) + parts := fileUpload.manifest.splitFileToParts(done, *request.PartSize, request.EnableMultipartChecksumVerification, file, fileSize) + response, err = fileUpload.startConcurrentUpload(ctx, done, parts, request) + return +} + +func (fileUpload *fileUpload) UploadFilePutObject(ctx context.Context, request UploadFileRequest) (UploadResponse, error) { + response := UploadResponse{Type: SinglepartUpload} + file, err := os.Open(request.FilePath) + defer file.Close() + if err != nil { + return response, err + } + + fi, err := file.Stat() + if err != nil { + return response, err + } + + fileSize := int64(fi.Size()) + + req := objectstorage.PutObjectRequest{ + NamespaceName: request.NamespaceName, + BucketName: request.BucketName, + ObjectName: request.ObjectName, + ContentLength: common.Int64(fileSize), + PutObjectBody: file, + OpcMeta: request.Metadata, + IfMatch: request.IfMatch, + IfNoneMatch: request.IfNoneMatch, + ContentType: request.ContentType, + ContentLanguage: request.ContentLanguage, + ContentEncoding: request.ContentEncoding, + ContentMD5: request.ContentMD5, + OpcClientRequestId: request.OpcClientRequestID, + RequestMetadata: request.RequestMetadata, + StorageTier: request.StorageTier, + } + + resp, err := request.ObjectStorageClient.PutObject(ctx, req) + + if err != nil { + return response, err + } + + // set the response + response.SinglepartUploadResponse = &SinglepartUploadResponse{PutObjectResponse: resp} + return response, nil +} + +func (fileUpload *fileUpload) ResumeUploadFile(ctx context.Context, uploadID string) (UploadResponse, error) { + response := UploadResponse{Type: MultipartUpload} + if fileUpload.manifest == nil || fileUpload.manifest.parts == nil { + err := errors.New("cannot resume upload file, please call UploadFileMultiparts first") + return response, err + } + + parts := fileUpload.manifest.parts[uploadID] + + failedParts := []uploadPart{} + for _, failedPart := range parts { + if failedPart.err != nil || failedPart.etag == nil { + failedPart.err = nil // reset the previouse error to nil for resume + failedParts = append(failedParts, failedPart) + } + } + + if len(failedParts) == 0 { + err := errors.New("previous upload succeed, cannot resume") + return response, err + } + + failedPartsChannel := make(chan uploadPart, len(failedParts)) + go func() { + // close the channel after splitFile returns + defer func() { + common.Debugln("closing parts channel from failedPartsChannel") + close(failedPartsChannel) + }() + + for _, failedPart := range failedParts { + failedPartsChannel <- failedPart + } + }() + + // ResumeUploadFile closes the done channel when it returns + done := make(chan struct{}) + defer close(done) + + response, err := fileUpload.startConcurrentUpload(ctx, done, failedPartsChannel, fileUpload.fileUploadReqs[uploadID]) + return response, err +} + +func (fileUpload *fileUpload) startConcurrentUpload(ctx context.Context, done <-chan struct{}, parts <-chan uploadPart, request UploadFileRequest) (response UploadResponse, err error) { + result := make(chan uploadPart) + numUploads := *request.NumberOfGoroutines + var wg sync.WaitGroup + wg.Add(numUploads) + + // start fixed number of goroutines to upload parts + for i := 0; i < numUploads; i++ { + go func() { + fileUpload.multipartUploader.uploadParts(ctx, done, parts, result, request.UploadRequest, fileUpload.uploadID) + wg.Done() + }() + } + + go func() { + wg.Wait() + close(result) + }() + + fileUpload.manifest.updateManifest(result, fileUpload.uploadID) + // Calculate multipartMD5 once enabled multipart MD5 verification. + multipartMD5 := fileUpload.manifest.getMultipartMD5Checksum(request.EnableMultipartChecksumVerification, fileUpload.uploadID) + + resp, err := fileUpload.multipartUploader.commit(ctx, request.UploadRequest, fileUpload.manifest.parts[fileUpload.uploadID], fileUpload.uploadID) + + if err != nil { + common.Debugf("failed to commit with error: %v\n", err) + return UploadResponse{ + Type: MultipartUpload, + MultipartUploadResponse: &MultipartUploadResponse{ + isResumable: common.Bool(true), UploadID: common.String(fileUpload.uploadID)}}, + err + } + + if multipartMD5 != nil && *request.EnableMultipartChecksumVerification && strings.Compare(*resp.OpcMultipartMd5, *multipartMD5) != 0 { + err = fmt.Errorf("multipart base64 MD5 checksum verification failure, the sending opcMD5 is %s, the reveived is %s", *resp.OpcMultipartMd5, *multipartMD5) + common.Debugf("MD5 checksum error: %v\n", err) + } + + response = UploadResponse{ + Type: MultipartUpload, + MultipartUploadResponse: &MultipartUploadResponse{ + CommitMultipartUploadResponse: resp, UploadID: common.String(fileUpload.uploadID)}, + } + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/file_uploader_req_resp.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/file_uploader_req_resp.go new file mode 100644 index 000000000..829016ddd --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/file_uploader_req_resp.go @@ -0,0 +1,44 @@ +// Copyright (c) 2016, 2018, 2020, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package transfer + +import ( + "errors" + + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UploadFileRequest defines the input parameters for UploadFile method +type UploadFileRequest struct { + UploadRequest + + // The path of the file to be uploaded (includs file name) + FilePath string +} + +var errorInvalidFilePath = errors.New("filePath is required") + +const defaultFilePartSize = 128 * 1024 * 1024 // 128MB + +func (request UploadFileRequest) validate() error { + err := request.UploadRequest.validate() + + if err != nil { + return err + } + + if len(request.FilePath) == 0 { + return errorInvalidFilePath + } + + return nil +} + +func (request *UploadFileRequest) initDefaultValues() error { + if request.PartSize == nil { + request.PartSize = common.Int64(defaultFilePartSize) + } + + return request.UploadRequest.initDefaultValues() +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/multipart_manifest.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/multipart_manifest.go new file mode 100644 index 000000000..a5ff96514 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/multipart_manifest.go @@ -0,0 +1,211 @@ +// Copyright (c) 2016, 2018, 2020, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package transfer + +import ( + "bytes" + "crypto/md5" + "encoding/base64" + "io" + "os" + "strconv" + + "github.com/oracle/oci-go-sdk/v54/common" +) + +// multipartManifest provides thread-safe access to an ongoing manifest upload. +type multipartManifest struct { + // key is UploadID, define it as map since user can upload multiple times + // second key is part number + parts map[string]map[int]uploadPart +} + +type uploadPart struct { + size int64 + offset int64 + partBody []byte + partNum int + hash *string + opcMD5 *string + etag *string + err error + totalParts int +} + +// splitFileToParts starts a goroutine to read a file and break down to parts and send the parts to +// uploadPart channel. It sends the error to error chanel. If done is closed, splitFileToParts +// abandones its works. +func (manifest *multipartManifest) splitFileToParts(done <-chan struct{}, partSize int64, isChecksumEnabled *bool, file *os.File, fileSize int64) <-chan uploadPart { + + parts := make(chan uploadPart) + + // Number of parts of the file + numberOfParts := int(fileSize / partSize) + + // check for any left over bytes + remainder := fileSize % partSize + + totalParts := numberOfParts + if remainder != 0 { + totalParts = numberOfParts + 1 + } + go func() { + // close the channel after splitFile returns + defer func() { + common.Debugln("closing parts channel from splitFileParts") + close(parts) + }() + + // All buffer sizes are the same in the normal case. Offsets depend on the index. + // Second go routine should start at 100, for example, given our + // buffer size of 100. + for i := 0; i < numberOfParts; i++ { + offset := partSize * int64(i) // offset of the file, start with 0 + + buffer := make([]byte, partSize) + _, err := file.ReadAt(buffer, offset) + + part := uploadPart{ + partNum: i + 1, + size: partSize, + offset: offset, + err: err, + partBody: buffer, + totalParts: totalParts, + } + // Once enabled multipartMD5 verification, add opcMD5 for part + part.opcMD5 = getPartMD5Checksum(isChecksumEnabled, part) + + select { + case parts <- part: + case <-done: + return + } + } + + // check for any left over bytes. Add the residual number of bytes as the + // the last chunk size. + if remainder != 0 { + part := uploadPart{ + offset: int64(numberOfParts) * partSize, + partNum: numberOfParts + 1, + totalParts: totalParts, + } + + part.partBody = make([]byte, remainder) + _, err := file.ReadAt(part.partBody, part.offset) + + part.size = remainder + part.err = err + // Once enabled multipartMD5 verification, add opcMD5 for part + part.opcMD5 = getPartMD5Checksum(isChecksumEnabled, part) + + select { + case parts <- part: + case <-done: + return + } + } + }() + + return parts +} + +func (manifest multipartManifest) getMultipartMD5Checksum(isChecksumEnabled *bool, uploadID string) *string { + if isChecksumEnabled == nil || !*isChecksumEnabled { + return nil + } + + parts := manifest.parts[uploadID] + totalParts := len(parts) + var bytesBuf bytes.Buffer + for i := 1; i <= totalParts; i++ { + part := parts[i] + cipherStr, _ := base64.StdEncoding.DecodeString(*part.opcMD5) + bytesBuf.Write(cipherStr) + } + multipartMD5 := base64.StdEncoding.EncodeToString(md5Encode(bytesBuf.Bytes())) + "-" + strconv.Itoa(totalParts) + return &multipartMD5 +} + +func getPartMD5Checksum(isChecksumEnabled *bool, part uploadPart) *string { + if isChecksumEnabled == nil || !*isChecksumEnabled { + return nil + } + + var buffer bytes.Buffer + cipherStr := md5Encode(part.partBody) + opcMD5 := base64.StdEncoding.EncodeToString(cipherStr) + buffer.Write(cipherStr) + return &opcMD5 +} + +func md5Encode(data []byte) []byte { + // Each time handle 1 MiB bytes data + chunkSize := 1024 * 1024 + dataLength := len(data) + chunkNum := dataLength / chunkSize + md5Ctx := md5.New() + for i := 0; i < chunkNum; i++ { + md5Ctx.Write(data[chunkSize*i : chunkSize*(i+1)]) + } + if chunkSize*chunkNum < dataLength { + md5Ctx.Write(data[chunkSize*chunkNum : dataLength]) + } + return md5Ctx.Sum(nil) +} + +// splitStreamToParts starts a goroutine to read a stream and break down to parts and send the parts to +// uploadPart channel. It sends the error to error channel. If done is closed, splitStreamToParts +// abandons its works. +func (manifest *multipartManifest) splitStreamToParts(done <-chan struct{}, partSize int64, isChecksumEnabled *bool, reader io.Reader) <-chan uploadPart { + parts := make(chan uploadPart) + + go func() { + defer close(parts) + partNum := 1 + for { + buffer := make([]byte, partSize) + numberOfBytesRead, err := io.ReadFull(reader, buffer) + + // ignore io.ErrUnexpectedEOF here + if err == io.EOF { + break + } + + // If the number of bytes read is less than the initial buffer size, reduce the buffer size to match the actual content size. + // it's actually the handling of io.ErrUnexpectedEOF + if int64(numberOfBytesRead) < partSize { + buffer = buffer[:numberOfBytesRead] + } + + part := uploadPart{ + partNum: partNum, + size: int64(numberOfBytesRead), + err: nil, + partBody: buffer, + } + // Once enabled multipartMD5 verification, add opcMD5 for part + part.opcMD5 = getPartMD5Checksum(isChecksumEnabled, part) + partNum++ + select { + case parts <- part: + case <-done: + return + } + } + }() + + return parts +} + +// update the result in manifest +func (manifest *multipartManifest) updateManifest(result <-chan uploadPart, uploadID string) { + if manifest.parts[uploadID] == nil { + manifest.parts[uploadID] = make(map[int]uploadPart) + } + for r := range result { + manifest.parts[uploadID][r.partNum] = r + } +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/mutipart_uploader.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/mutipart_uploader.go new file mode 100644 index 000000000..4a5acb347 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/mutipart_uploader.go @@ -0,0 +1,153 @@ +// Copyright (c) 2016, 2018, 2020, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package transfer + +import ( + "bytes" + "context" + "io/ioutil" + + "github.com/oracle/oci-go-sdk/v54/common" + "github.com/oracle/oci-go-sdk/v54/objectstorage" +) + +// multipartUploader is an interface wrap the methods talk to object storage service +type multipartUploader interface { + createMultipartUpload(ctx context.Context, request UploadRequest) (string, error) + uploadParts(ctx context.Context, done <-chan struct{}, parts <-chan uploadPart, result chan<- uploadPart, request UploadRequest, uploadID string) + uploadPart(ctx context.Context, request UploadRequest, part uploadPart, uploadID string) (objectstorage.UploadPartResponse, error) + commit(ctx context.Context, request UploadRequest, parts map[int]uploadPart, uploadID string) (resp objectstorage.CommitMultipartUploadResponse, err error) +} + +// multipartUpload implements multipartUploader interface +type multipartUpload struct{} + +// createMultipartUpload creates a new multipart upload in Object Storage and return the uploadId +func (uploader *multipartUpload) createMultipartUpload(ctx context.Context, request UploadRequest) (string, error) { + multipartUploadRequest := objectstorage.CreateMultipartUploadRequest{ + NamespaceName: request.NamespaceName, + BucketName: request.BucketName, + IfMatch: request.IfMatch, + IfNoneMatch: request.IfNoneMatch, + OpcClientRequestId: request.OpcClientRequestID, + } + + multipartUploadRequest.Object = request.ObjectName + multipartUploadRequest.ContentType = request.ContentType + multipartUploadRequest.ContentEncoding = request.ContentEncoding + multipartUploadRequest.ContentLanguage = request.ContentLanguage + multipartUploadRequest.Metadata = request.Metadata + switch request.StorageTier { + case objectstorage.PutObjectStorageTierStandard: + multipartUploadRequest.StorageTier = objectstorage.StorageTierStandard + case objectstorage.PutObjectStorageTierArchive: + multipartUploadRequest.StorageTier = objectstorage.StorageTierArchive + case objectstorage.PutObjectStorageTierInfrequentaccess: + multipartUploadRequest.StorageTier = objectstorage.StorageTierInfrequentAccess + } + + resp, err := request.ObjectStorageClient.CreateMultipartUpload(ctx, multipartUploadRequest) + if err == nil { + return *resp.UploadId, nil + } + return "", err +} + +func (uploader *multipartUpload) uploadParts(ctx context.Context, done <-chan struct{}, parts <-chan uploadPart, result chan<- uploadPart, request UploadRequest, uploadID string) { + // loop through the part from parts channel created by splitFileParts method + for part := range parts { + if part.err != nil { + // ignore this part which contains error from split function + result <- part + return + } + + resp, err := uploader.uploadPart(ctx, request, part, uploadID) + if err != nil { + common.Debugf("upload error %v\n", err) + part.err = err + } else { + part.partBody = nil + } + part.etag = resp.ETag + select { + case result <- part: + // Invoke the callBack after upload of each Part + if nil != request.CallBack { + uploadedPart := MultiPartUploadPart{ + PartNum: part.partNum, + TotalParts: part.totalParts, + Offset: part.offset, + Hash: part.hash, + Err: part.err, + OpcMD5: part.opcMD5} + + request.CallBack(uploadedPart) + } + common.Debugf("uploadParts resp %v, %v\n", part.partNum, resp.ETag) + case <-done: + common.Debugln("uploadParts received Done") + return + } + } +} + +// send request to upload part to object storage +func (uploader *multipartUpload) uploadPart(ctx context.Context, request UploadRequest, part uploadPart, uploadID string) (objectstorage.UploadPartResponse, error) { + req := objectstorage.UploadPartRequest{ + NamespaceName: request.NamespaceName, + BucketName: request.BucketName, + ObjectName: request.ObjectName, + UploadId: common.String(uploadID), + UploadPartNum: common.Int(part.partNum), + UploadPartBody: ioutil.NopCloser(bytes.NewReader(part.partBody)), + ContentLength: common.Int64(part.size), + IfMatch: request.IfMatch, + IfNoneMatch: request.IfNoneMatch, + OpcClientRequestId: request.OpcClientRequestID, + RequestMetadata: request.RequestMetadata, + ContentMD5: part.opcMD5, + } + + resp, err := request.ObjectStorageClient.UploadPart(ctx, req) + + return resp, err +} + +// commits the multipart upload +func (uploader *multipartUpload) commit(ctx context.Context, request UploadRequest, parts map[int]uploadPart, uploadID string) (resp objectstorage.CommitMultipartUploadResponse, err error) { + req := objectstorage.CommitMultipartUploadRequest{ + NamespaceName: request.NamespaceName, + BucketName: request.BucketName, + ObjectName: request.ObjectName, + UploadId: common.String(uploadID), + IfMatch: request.IfMatch, + IfNoneMatch: request.IfNoneMatch, + OpcClientRequestId: request.OpcClientRequestID, + RequestMetadata: request.RequestMetadata, + } + + partsToCommit := []objectstorage.CommitMultipartUploadPartDetails{} + + for _, part := range parts { + if part.etag != nil { + detail := objectstorage.CommitMultipartUploadPartDetails{ + Etag: part.etag, + PartNum: common.Int(part.partNum), + } + + // update the parts to commit + partsToCommit = append(partsToCommit, detail) + } else { + // some parts failed, return error for resume + common.Debugf("uploadPart has error: %v\n", part.err) + err = part.err + return + } + } + + req.PartsToCommit = partsToCommit + resp, err = request.ObjectStorageClient.CommitMultipartUpload(ctx, req) + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/stream_uploader.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/stream_uploader.go new file mode 100644 index 000000000..08e4354fa --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/stream_uploader.go @@ -0,0 +1,90 @@ +// Copyright (c) 2016, 2018, 2020, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package transfer + +import ( + "context" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" + "strings" + "sync" +) + +// StreamUploader is an interface for upload a stream +type StreamUploader interface { + // uploads a stream to blob storage + UploadStream(ctx context.Context, request UploadStreamRequest) (response UploadResponse, err error) +} + +type streamUpload struct { + uploadID string + manifest *multipartManifest + multipartUploader multipartUploader + request UploadStreamRequest +} + +func (streamUpload *streamUpload) UploadStream(ctx context.Context, request UploadStreamRequest) (response UploadResponse, err error) { + + uploadID, err := streamUpload.multipartUploader.createMultipartUpload(ctx, request.UploadRequest) + + if err != nil { + return UploadResponse{}, err + } + streamUpload.uploadID = uploadID + + if streamUpload.manifest == nil { + streamUpload.manifest = &multipartManifest{parts: make(map[string]map[int]uploadPart)} + } + + // UploadFileMultipart closes the done channel when it returns + done := make(chan struct{}) + defer close(done) + parts := streamUpload.manifest.splitStreamToParts(done, *request.PartSize, request.EnableMultipartChecksumVerification, request.StreamReader) + + return streamUpload.startConcurrentUpload(ctx, done, parts, request) +} + +func (streamUpload *streamUpload) startConcurrentUpload(ctx context.Context, done <-chan struct{}, parts <-chan uploadPart, request UploadStreamRequest) (response UploadResponse, err error) { + result := make(chan uploadPart) + numUploads := *request.NumberOfGoroutines + var wg sync.WaitGroup + wg.Add(numUploads) + + // start fixed number of goroutines to upload parts + for i := 0; i < numUploads; i++ { + go func() { + streamUpload.multipartUploader.uploadParts(ctx, done, parts, result, request.UploadRequest, streamUpload.uploadID) + wg.Done() + }() + } + + go func() { + wg.Wait() + close(result) + }() + + streamUpload.manifest.updateManifest(result, streamUpload.uploadID) + // Calculate multipartMD5 once enabled multipart MD5 verification. + multipartMD5 := streamUpload.manifest.getMultipartMD5Checksum(request.EnableMultipartChecksumVerification, streamUpload.uploadID) + + resp, err := streamUpload.multipartUploader.commit(ctx, request.UploadRequest, streamUpload.manifest.parts[streamUpload.uploadID], streamUpload.uploadID) + + if err != nil { + common.Debugf("failed to commit with error: %v\n", err) + return UploadResponse{ + Type: MultipartUpload, + MultipartUploadResponse: &MultipartUploadResponse{UploadID: common.String(streamUpload.uploadID)}}, + err + } + if multipartMD5 != nil && *request.EnableMultipartChecksumVerification && strings.Compare(*resp.OpcMultipartMd5, *multipartMD5) != 0 { + err = fmt.Errorf("multipart base64 MD5 checksum verification failure, the sending opcMD5 is %s, the reveived is %s", *resp.OpcMultipartMd5, *multipartMD5) + common.Debugf("MD5 checksum error: %v\n", err) + } + + response = UploadResponse{ + Type: MultipartUpload, + MultipartUploadResponse: &MultipartUploadResponse{CommitMultipartUploadResponse: resp}, + } + return +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/stream_uploader_req_resp.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/stream_uploader_req_resp.go new file mode 100644 index 000000000..04fb63156 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/stream_uploader_req_resp.go @@ -0,0 +1,57 @@ +// Copyright (c) 2016, 2018, 2020, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package transfer + +import ( + "errors" + "github.com/oracle/oci-go-sdk/v54/common" + "io" + "reflect" +) + +// UploadStreamRequest defines the input parameters for UploadFile method +type UploadStreamRequest struct { + UploadRequest + + // The reader of input stream + StreamReader io.Reader +} + +var errorInvalidStream = errors.New("uploadStream is required") + +const defaultStreamPartSize = 10 * 1024 * 1024 // 10MB + +func (request UploadStreamRequest) validate() error { + err := request.UploadRequest.validate() + + if err != nil { + return err + } + + if isNil(request.StreamReader) { + return errorInvalidStream + } + + return nil +} + +func isNil(i interface{}) bool { + if i == nil { + return true + } + kind := reflect.TypeOf(i).Kind() + switch kind { + case reflect.Ptr, reflect.Map, reflect.Array, reflect.Chan, reflect.Slice: + return reflect.ValueOf(i).IsNil() + } + return false +} + +func (request *UploadStreamRequest) initDefaultValues() error { + if request.PartSize == nil { + request.PartSize = common.Int64(defaultStreamPartSize) + } + + return request.UploadRequest.initDefaultValues() +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/upload_manager.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/upload_manager.go new file mode 100644 index 000000000..776fbfe7d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/upload_manager.go @@ -0,0 +1,179 @@ +// Copyright (c) 2016, 2018, 2020, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +// Package transfer simplifies interaction with the Object Storage service by abstracting away the method used +// to upload objects. Depending on the configuration parameters, UploadManager may choose to do a single +// put_object request, or break up the upload into multiple parts and utilize multi-part uploads. +// +// An advantage of using multi-part uploads is the ability to retry individual failed parts, as well as being +// able to upload parts in parallel to reduce upload time. +// +// To use this package, you must be authorized in an IAM policy. If you're not authorized, talk to an administrator. +package transfer + +import ( + "bytes" + "context" + "errors" + "github.com/oracle/oci-go-sdk/v54/common" + "github.com/oracle/oci-go-sdk/v54/objectstorage" + "io" + "net/http" + "os" + "strings" +) + +// UploadManager is the interface that groups the upload methods +type UploadManager struct { + FileUploader FileUploader + StreamUploader StreamUploader +} + +var ( + errorInvalidStreamUploader = errors.New("streamUploader is required, use NewUploadManager for default implementation") + errorInvalidFileUploader = errors.New("fileUploader is required, use NewUploadManager for default implementation") +) + +// NewUploadManager return a pointer to UploadManager +func NewUploadManager() *UploadManager { + return &UploadManager{ + FileUploader: &fileUpload{multipartUploader: &multipartUpload{}}, + StreamUploader: &streamUpload{multipartUploader: &multipartUpload{}}, + } +} + +// UploadFile uploads an object to Object Storage. Depending on the options provided and the +// size of the object, the object may be uploaded in multiple parts or just an signle object. +func (uploadManager *UploadManager) UploadFile(ctx context.Context, request UploadFileRequest) (response UploadResponse, err error) { + if err = request.validate(); err != nil { + return + } + + if err = request.initDefaultValues(); err != nil { + return + } + + if uploadManager.FileUploader == nil { + err = errorInvalidFileUploader + return + } + + file, err := os.Open(request.FilePath) + defer file.Close() + + if err != nil { + return + } + + fi, err := file.Stat() + if err != nil { + return + } + + fileSize := fi.Size() + + // parallel upload disabled by user or the file size smaller than or equal to partSize + // use UploadFilePutObject + if !*request.AllowMultipartUploads || + fileSize <= *request.PartSize { + response, err = uploadManager.FileUploader.UploadFilePutObject(ctx, request) + return + } + + response, err = uploadManager.FileUploader.UploadFileMultiparts(ctx, request) + return +} + +// ResumeUploadFile resumes a multipart file upload. +func (uploadManager *UploadManager) ResumeUploadFile(ctx context.Context, uploadID string) (response UploadResponse, err error) { + if len(strings.TrimSpace(uploadID)) == 0 { + err = errors.New("uploadID is required to resume a multipart file upload") + return + } + response, err = uploadManager.FileUploader.ResumeUploadFile(ctx, uploadID) + return +} + +// UploadStream uploads streaming data to Object Storage. If the stream is non-empty, this will always perform a +// multipart upload, splitting parts based on the part size (10 MiB if none specified). If the stream is empty, +// this will upload a single empty object to Object Storage. +// Stream uploads are not currently resumable. +func (uploadManager *UploadManager) UploadStream(ctx context.Context, request UploadStreamRequest) (response UploadResponse, err error) { + if err = request.validate(); err != nil { + return + } + + if err = request.initDefaultValues(); err != nil { + return + } + + if uploadManager.StreamUploader == nil { + err = errorInvalidStreamUploader + return + } + //check if the stream is empty + if isZeroLength(request.StreamReader) { + return uploadEmptyStream(ctx, request) + } + + response, err = uploadManager.StreamUploader.UploadStream(ctx, request) + return +} + +func isZeroLength(streamReader io.Reader) bool { + switch v := streamReader.(type) { + case *bytes.Buffer: + return v.Len() == 0 + case *bytes.Reader: + return v.Len() == 0 + case *strings.Reader: + return v.Len() == 0 + case *os.File: + fi, err := v.Stat() + if err != nil { + return false + } + return fi.Size() == 0 + default: + return false + } + return false +} + +func uploadEmptyStream(ctx context.Context, request UploadStreamRequest) (response UploadResponse, err error) { + putObjReq := objectstorage.PutObjectRequest{ + NamespaceName: request.UploadRequest.NamespaceName, + BucketName: request.UploadRequest.BucketName, + ObjectName: request.UploadRequest.ObjectName, + ContentLength: new(int64), + PutObjectBody: http.NoBody, + OpcMeta: request.UploadRequest.Metadata, + IfMatch: request.UploadRequest.IfMatch, + IfNoneMatch: request.UploadRequest.IfNoneMatch, + ContentType: request.UploadRequest.ContentType, + ContentLanguage: request.UploadRequest.ContentLanguage, + ContentEncoding: request.UploadRequest.ContentEncoding, + ContentMD5: request.UploadRequest.ContentMD5, + OpcClientRequestId: request.UploadRequest.OpcClientRequestID, + RequestMetadata: request.UploadRequest.RequestMetadata, + } + putObjResp, err := request.UploadRequest.ObjectStorageClient.PutObject(ctx, putObjReq) + spUploadResp := SinglepartUploadResponse{putObjResp} + return UploadResponse{SinglepartUpload, &spUploadResp, nil}, err +} + +func getUploadManagerRetryPolicy() *common.RetryPolicy { + attempts := uint(3) + retryOnAllNon200ResponseCodes := func(r common.OCIOperationResponse) bool { + return !(r.Error == nil && 199 < r.Response.HTTPResponse().StatusCode && r.Response.HTTPResponse().StatusCode < 300) + } + + policy := common.NewRetryPolicyWithOptions( + // since this retries on ANY non-2xx response, we don't need special handling for eventual consistency + common.ReplaceWithValuesFromRetryPolicy(common.DefaultRetryPolicyWithoutEventualConsistency()), + common.WithMaximumNumberAttempts(attempts), + common.WithShouldRetryOperation(retryOnAllNon200ResponseCodes), + ) + + return &policy +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/upload_manager_req_resp.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/upload_manager_req_resp.go new file mode 100644 index 000000000..8a5be031a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/transfer/upload_manager_req_resp.go @@ -0,0 +1,241 @@ +// Copyright (c) 2016, 2018, 2020, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +package transfer + +import ( + "errors" + "net/http" + + "github.com/oracle/oci-go-sdk/v54/common" + "github.com/oracle/oci-go-sdk/v54/objectstorage" +) + +// requestValidator validate user's input and assign default values if not defined +type requestValidator interface { + // validate inputs, return error if request is not valid + validate() error + + // assign default values + assignDefaultValues() error +} + +// UploadRequest defines the input parameters for UploadFile method +type UploadRequest struct { + // The top-level namespace used for the request. + NamespaceName *string `mandatory:"true"` + + // The name of the bucket. Avoid entering confidential information. Example: my-new-bucket1 + BucketName *string `mandatory:"true"` + + // The name of the object. Avoid entering confidential information. Example: test/object1.log + ObjectName *string `mandatory:"true"` + + // [Optional] Override the default part size of 128 MiB, value is in bytes. + // The max part size is 50GiB + PartSize *int64 `mandatory:"false"` + + // [Optional] Whether or not this UploadManager supports performing mulitpart uploads. Defaults to True. + AllowMultipartUploads *bool `mandatory:"false"` + + // [Optional] Whether or not this UploadManager supports uploading individual parts of a multipart upload in parallel. + // This setting has no effect on uploads that are performed using a single put_object call. Defaults to True. + AllowParrallelUploads *bool `mandatory:"false"` + + // The number of go routines for uploading individual parts of a multipart upload. + // This setting is only used if allow_parallel_uploads is set to True. Defaults to 5. + // The upper bounds of the number is 10,000. + NumberOfGoroutines *int `mandatory:"false"` + + // A configured object storage client to use for interacting with the Object Storage service. + // Default timeout is 60s which includes the time for reading the body. + // Default timeout doesn't work for big file size and big part size(once upload each part longer than 60s), need to manually update timeout to support big file upload. + ObjectStorageClient *objectstorage.ObjectStorageClient `mandatory:"false"` + + // [Optional] The entity tag of the object to match. + IfMatch *string `mandatory:"false"` + + // [Optional] The entity tag of the object to avoid matching. The only valid value is ‘*’, + // which indicates that the request should fail if the object already exists. + IfNoneMatch *string `mandatory:"false"` + + // [Optional] The base-64 encoded MD5 hash of the body. This parameter is only used if the object is uploaded in a single part. + ContentMD5 *string `mandatory:"false"` + + // [Optional] The content type of the object to upload. + ContentType *string `mandatory:"false"` + + // [Optional] The content language of the object to upload. + ContentLanguage *string `mandatory:"false"` + + // [Optional] The content encoding of the object to upload. + ContentEncoding *string `mandatory:"false"` + + // [Optional] Arbitrary string keys and values for the user-defined metadata for the object. + // Keys must be in "opc-meta-*" format. + Metadata map[string]string `mandatory:"false"` + + // [Optional] The client request ID for tracing. + OpcClientRequestID *string `mandatory:"false"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata + + // [Optional] The storage tier of the object to upload. If not specified, the storage tier is + // defaulted to 'Standard' + StorageTier objectstorage.PutObjectStorageTierEnum `mandatory:"false"` + + // [Optional] Callback API that can be invoked during multiPartUploads + CallBack UploadCallBack `mandatory:"false"` + + // [Optional] Whether or not this UploadManager supports performing multipart uploads md5 checksum verification. Defaults to False. + EnableMultipartChecksumVerification *bool `mandatory:"false"` +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UploadRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +var ( + errorInvalidNamespace = errors.New("namespaceName is required") + errorInvalidBucketName = errors.New("bucketName is required") + errorInvalidObjectName = errors.New("objectName is required") +) + +const defaultNumberOfGoroutines = 5 // increase the value might cause 409 error form service and client timeout + +func (request UploadRequest) validate() error { + if request.NamespaceName == nil { + return errorInvalidNamespace + } + + if request.BucketName == nil { + return errorInvalidBucketName + } + + if request.ObjectName == nil { + return errorInvalidObjectName + } + + return nil +} + +func (request *UploadRequest) initDefaultValues() error { + if request.ObjectStorageClient == nil { + client, err := objectstorage.NewObjectStorageClientWithConfigurationProvider(common.DefaultConfigProvider()) + + // default timeout is 60s which includes the time for reading the body + // default timeout doesn't work for big file, here will use the default + // 0s which means no timeout + client.HTTPClient = &http.Client{} + + if err != nil { + return err + } + + request.ObjectStorageClient = &client + } + + if request.NumberOfGoroutines == nil || + *request.NumberOfGoroutines <= 0 { + request.NumberOfGoroutines = common.Int(defaultNumberOfGoroutines) + } + + if request.AllowMultipartUploads == nil { + request.AllowMultipartUploads = common.Bool(true) + } + + if request.AllowParrallelUploads == nil { + request.AllowParrallelUploads = common.Bool(true) + } + + if !*request.AllowParrallelUploads { + request.NumberOfGoroutines = common.Int(1) // one go routine for upload + } + + if request.RetryPolicy() == nil { + // default retry policy + request.RequestMetadata = common.RequestMetadata{RetryPolicy: getUploadManagerDefaultRetryPolicy()} + } + + return nil +} + +// UploadResponseType with underlying type: string +type UploadResponseType string + +// Set of constants representing the allowable values for VolumeAttachmentLifecycleState +const ( + MultipartUpload UploadResponseType = "MULTIPARTUPLOAD" + SinglepartUpload UploadResponseType = "SINGLEPARTUPLOAD" +) + +// UploadResponse is the response from commitMultipart or the putObject API operation. +type UploadResponse struct { + + // Polymorphic response type indicates the response type + Type UploadResponseType + + // response for putObject API response (single part upload), will be nil if the operation is multiPart upload + *SinglepartUploadResponse + + // response for commitMultipart API response (multipart upload), will be nil if the operation is singlePart upload + *MultipartUploadResponse +} + +// IsResumable is a function to check is previous failed upload resumable or not +func (resp UploadResponse) IsResumable() bool { + if resp.Type == SinglepartUpload { + return false + } + + return *resp.MultipartUploadResponse.isResumable +} + +// SinglepartUploadResponse is the response from putObject API operation. +type SinglepartUploadResponse struct { + objectstorage.PutObjectResponse +} + +// MultipartUploadResponse is the response from commitMultipart API operation. +type MultipartUploadResponse struct { + objectstorage.CommitMultipartUploadResponse + + // The upload ID for a multipart upload. + UploadID *string + + // The value indicates is the operation IsResumable or not, call the resume function if is true + isResumable *bool +} + +func getUploadManagerDefaultRetryPolicy() *common.RetryPolicy { + attempts := uint(3) + retryOnAllNon200ResponseCodes := func(r common.OCIOperationResponse) bool { + return !(r.Error == nil && 199 < r.Response.HTTPResponse().StatusCode && r.Response.HTTPResponse().StatusCode < 300) + } + + policy := common.NewRetryPolicyWithOptions( + common.WithMaximumNumberAttempts(attempts), + common.WithShouldRetryOperation(retryOnAllNon200ResponseCodes)) + + return &policy +} + +// +// MultiPartUploadPart holds the details of Part that is uploaded +// +type MultiPartUploadPart struct { + PartNum int + TotalParts int + Size int64 + Offset int64 + Hash *string + OpcMD5 *string + Etag *string + Err error +} + +// UploadCallBack API that gets invoked after a Part is successuly uploaded +type UploadCallBack func(multiPartUploadPart MultiPartUploadPart) diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_bucket_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_bucket_details.go new file mode 100644 index 000000000..73a825feb --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_bucket_details.go @@ -0,0 +1,125 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateBucketDetails To use any of the API operations, you must be authorized in an IAM policy. If you are not authorized, +// talk to an administrator. If you are an administrator who needs to write policies to give users access, see +// Getting Started with Policies (https://docs.cloud.oracle.com/Content/Identity/Concepts/policygetstarted.htm). +type UpdateBucketDetails struct { + + // The Object Storage namespace in which the bucket lives. + Namespace *string `mandatory:"false" json:"namespace"` + + // The compartmentId for the compartment to move the bucket to. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + // The name of the bucket. Valid characters are uppercase or lowercase letters, numbers, hyphens, underscores, and periods. + // Bucket names must be unique within an Object Storage namespace. Avoid entering confidential information. + // Example: my-new-bucket1 + Name *string `mandatory:"false" json:"name"` + + // Arbitrary string, up to 4KB, of keys and values for user-defined metadata. + Metadata map[string]string `mandatory:"false" json:"metadata"` + + // The type of public access enabled on this bucket. A bucket is set to `NoPublicAccess` by default, which only allows an + // authenticated caller to access the bucket and its contents. When `ObjectRead` is enabled on the bucket, public access + // is allowed for the `GetObject`, `HeadObject`, and `ListObjects` operations. When `ObjectReadWithoutList` is enabled + // on the bucket, public access is allowed for the `GetObject` and `HeadObject` operations. + PublicAccessType UpdateBucketDetailsPublicAccessTypeEnum `mandatory:"false" json:"publicAccessType,omitempty"` + + // Whether or not events are emitted for object state changes in this bucket. By default, `objectEventsEnabled` is + // set to `false`. Set `objectEventsEnabled` to `true` to emit events for object state changes. For more information + // about events, see Overview of Events (https://docs.cloud.oracle.com/Content/Events/Concepts/eventsoverview.htm). + ObjectEventsEnabled *bool `mandatory:"false" json:"objectEventsEnabled"` + + // Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Department": "Finance"}` + FreeformTags map[string]string `mandatory:"false" json:"freeformTags"` + + // Defined tags for this resource. Each key is predefined and scoped to a namespace. + // For more information, see Resource Tags (https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm). + // Example: `{"Operations": {"CostCenter": "42"}} + DefinedTags map[string]map[string]interface{} `mandatory:"false" json:"definedTags"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the Key Management master encryption key to associate + // with the specified bucket. If this value is empty, the Update operation will remove the associated key, if + // there is one, from the bucket. (The bucket will continue to be encrypted, but with an encryption key managed + // by Oracle.) + KmsKeyId *string `mandatory:"false" json:"kmsKeyId"` + + // The versioning status on the bucket. If in state `Enabled`, multiple versions of the same object can be kept in the bucket. + // When the object is overwritten or deleted, previous versions will still be available. When versioning is `Suspended`, the previous versions will still remain but new versions will no longer be created when overwitten or deleted. + // Versioning cannot be disabled on a bucket once enabled. + Versioning UpdateBucketDetailsVersioningEnum `mandatory:"false" json:"versioning,omitempty"` + + // The auto tiering status on the bucket. If in state `InfrequentAccess`, objects are transitioned + // automatically between the 'Standard' and 'InfrequentAccess' tiers based on the access pattern of the objects. + // When auto tiering is `Disabled`, there will be no automatic transitions between storage tiers. + AutoTiering BucketAutoTieringEnum `mandatory:"false" json:"autoTiering,omitempty"` +} + +func (m UpdateBucketDetails) String() string { + return common.PointerString(m) +} + +// UpdateBucketDetailsPublicAccessTypeEnum Enum with underlying type: string +type UpdateBucketDetailsPublicAccessTypeEnum string + +// Set of constants representing the allowable values for UpdateBucketDetailsPublicAccessTypeEnum +const ( + UpdateBucketDetailsPublicAccessTypeNopublicaccess UpdateBucketDetailsPublicAccessTypeEnum = "NoPublicAccess" + UpdateBucketDetailsPublicAccessTypeObjectread UpdateBucketDetailsPublicAccessTypeEnum = "ObjectRead" + UpdateBucketDetailsPublicAccessTypeObjectreadwithoutlist UpdateBucketDetailsPublicAccessTypeEnum = "ObjectReadWithoutList" +) + +var mappingUpdateBucketDetailsPublicAccessType = map[string]UpdateBucketDetailsPublicAccessTypeEnum{ + "NoPublicAccess": UpdateBucketDetailsPublicAccessTypeNopublicaccess, + "ObjectRead": UpdateBucketDetailsPublicAccessTypeObjectread, + "ObjectReadWithoutList": UpdateBucketDetailsPublicAccessTypeObjectreadwithoutlist, +} + +// GetUpdateBucketDetailsPublicAccessTypeEnumValues Enumerates the set of values for UpdateBucketDetailsPublicAccessTypeEnum +func GetUpdateBucketDetailsPublicAccessTypeEnumValues() []UpdateBucketDetailsPublicAccessTypeEnum { + values := make([]UpdateBucketDetailsPublicAccessTypeEnum, 0) + for _, v := range mappingUpdateBucketDetailsPublicAccessType { + values = append(values, v) + } + return values +} + +// UpdateBucketDetailsVersioningEnum Enum with underlying type: string +type UpdateBucketDetailsVersioningEnum string + +// Set of constants representing the allowable values for UpdateBucketDetailsVersioningEnum +const ( + UpdateBucketDetailsVersioningEnabled UpdateBucketDetailsVersioningEnum = "Enabled" + UpdateBucketDetailsVersioningSuspended UpdateBucketDetailsVersioningEnum = "Suspended" +) + +var mappingUpdateBucketDetailsVersioning = map[string]UpdateBucketDetailsVersioningEnum{ + "Enabled": UpdateBucketDetailsVersioningEnabled, + "Suspended": UpdateBucketDetailsVersioningSuspended, +} + +// GetUpdateBucketDetailsVersioningEnumValues Enumerates the set of values for UpdateBucketDetailsVersioningEnum +func GetUpdateBucketDetailsVersioningEnumValues() []UpdateBucketDetailsVersioningEnum { + values := make([]UpdateBucketDetailsVersioningEnum, 0) + for _, v := range mappingUpdateBucketDetailsVersioning { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_bucket_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_bucket_request_response.go new file mode 100644 index 000000000..ed4f55538 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_bucket_request_response.go @@ -0,0 +1,91 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateBucketRequest wrapper for the UpdateBucket operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/UpdateBucket.go.html to see an example of how to use UpdateBucketRequest. +type UpdateBucketRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // Request object for updating a bucket. + UpdateBucketDetails `contributesTo:"body"` + + // The entity tag (ETag) to match with the ETag of an existing resource. If the specified ETag matches the ETag of + // the existing resource, GET and HEAD requests will return the resource and PUT and POST requests will upload + // the resource. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateBucketRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateBucketRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateBucketRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateBucketRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateBucketResponse wrapper for the UpdateBucket operation +type UpdateBucketResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The Bucket instance + Bucket `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The entity tag (ETag) for the updated bucket. + ETag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateBucketResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateBucketResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_namespace_metadata_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_namespace_metadata_details.go new file mode 100644 index 000000000..abb7d3613 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_namespace_metadata_details.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateNamespaceMetadataDetails UpdateNamespaceMetadataDetails is used to update the NamespaceMetadata. To update NamespaceMetadata, a user +// must have OBJECTSTORAGE_NAMESPACE_UPDATE permission. +type UpdateNamespaceMetadataDetails struct { + + // The updated compartment id for use by an S3 client, if this field is set. + DefaultS3CompartmentId *string `mandatory:"false" json:"defaultS3CompartmentId"` + + // The updated compartment id for use by a Swift client, if this field is set. + DefaultSwiftCompartmentId *string `mandatory:"false" json:"defaultSwiftCompartmentId"` +} + +func (m UpdateNamespaceMetadataDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_namespace_metadata_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_namespace_metadata_request_response.go new file mode 100644 index 000000000..cb6b93f07 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_namespace_metadata_request_response.go @@ -0,0 +1,79 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateNamespaceMetadataRequest wrapper for the UpdateNamespaceMetadata operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/UpdateNamespaceMetadata.go.html to see an example of how to use UpdateNamespaceMetadataRequest. +type UpdateNamespaceMetadataRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // Request object for update NamespaceMetadata. + UpdateNamespaceMetadataDetails `contributesTo:"body"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateNamespaceMetadataRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateNamespaceMetadataRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateNamespaceMetadataRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateNamespaceMetadataRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateNamespaceMetadataResponse wrapper for the UpdateNamespaceMetadata operation +type UpdateNamespaceMetadataResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The NamespaceMetadata instance + NamespaceMetadata `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateNamespaceMetadataResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateNamespaceMetadataResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_object_storage_tier_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_object_storage_tier_details.go new file mode 100644 index 000000000..bcc4cf532 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_object_storage_tier_details.go @@ -0,0 +1,37 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateObjectStorageTierDetails To change the storage tier of an object, we specify the object name and the desired +// storage tier in the body. Objects can be moved between Standard and InfrequentAccess +// tiers and from Standard or InfrequentAccess tier to Archive tier. If a version id is +// specified, only the specified version of the object is moved to a different storage +// tier, else the current version is used. +type UpdateObjectStorageTierDetails struct { + + // An object for which the storage tier needs to be changed. + ObjectName *string `mandatory:"true" json:"objectName"` + + // The storage tier that the object should be moved to. + StorageTier StorageTierEnum `mandatory:"true" json:"storageTier"` + + // The versionId of the object. Current object version is used by default. + VersionId *string `mandatory:"false" json:"versionId"` +} + +func (m UpdateObjectStorageTierDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_object_storage_tier_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_object_storage_tier_request_response.go new file mode 100644 index 000000000..053cdd708 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_object_storage_tier_request_response.go @@ -0,0 +1,80 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateObjectStorageTierRequest wrapper for the UpdateObjectStorageTier operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/UpdateObjectStorageTier.go.html to see an example of how to use UpdateObjectStorageTierRequest. +type UpdateObjectStorageTierRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The object name and the desired storage tier. + UpdateObjectStorageTierDetails `contributesTo:"body"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateObjectStorageTierRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateObjectStorageTierRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateObjectStorageTierRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateObjectStorageTierRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateObjectStorageTierResponse wrapper for the UpdateObjectStorageTier operation +type UpdateObjectStorageTierResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response UpdateObjectStorageTierResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateObjectStorageTierResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_retention_rule_details.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_retention_rule_details.go new file mode 100644 index 000000000..0cde67dc2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_retention_rule_details.go @@ -0,0 +1,36 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// UpdateRetentionRuleDetails The details to update a retention rule. +type UpdateRetentionRuleDetails struct { + + // A user-specified name for the retention rule. Names can be helpful in identifying retention rules. + // Avoid entering confidential information. + DisplayName *string `mandatory:"false" json:"displayName"` + + Duration *Duration `mandatory:"false" json:"duration"` + + // The date and time as per RFC 3339 (https://tools.ietf.org/html/rfc3339) after which this rule is locked + // and can only be deleted by deleting the bucket. Once a rule is locked, only increases in the duration are + // allowed and no other properties can be changed. This property cannot be updated for rules that are in a + // locked state. Specifying it when a duration is not specified is considered an error. + TimeRuleLocked *common.SDKTime `mandatory:"false" json:"timeRuleLocked"` +} + +func (m UpdateRetentionRuleDetails) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_retention_rule_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_retention_rule_request_response.go new file mode 100644 index 000000000..cf8372a3d --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/update_retention_rule_request_response.go @@ -0,0 +1,94 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// UpdateRetentionRuleRequest wrapper for the UpdateRetentionRule operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/UpdateRetentionRule.go.html to see an example of how to use UpdateRetentionRuleRequest. +type UpdateRetentionRuleRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The ID of the retention rule. + RetentionRuleId *string `mandatory:"true" contributesTo:"path" name:"retentionRuleId"` + + // Request object for updating the retention rule. + UpdateRetentionRuleDetails `contributesTo:"body"` + + // The entity tag (ETag) to match with the ETag of an existing resource. If the specified ETag matches the ETag of + // the existing resource, GET and HEAD requests will return the resource and PUT and POST requests will upload + // the resource. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UpdateRetentionRuleRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UpdateRetentionRuleRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UpdateRetentionRuleRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UpdateRetentionRuleRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UpdateRetentionRuleResponse wrapper for the UpdateRetentionRule operation +type UpdateRetentionRuleResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The RetentionRule instance + RetentionRule `presentIn:"body"` + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The entity tag (ETag) for the retention rule that was updated. + Etag *string `presentIn:"header" name:"etag"` +} + +func (response UpdateRetentionRuleResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UpdateRetentionRuleResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/upload_part_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/upload_part_request_response.go new file mode 100644 index 000000000..5992cab73 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/upload_part_request_response.go @@ -0,0 +1,143 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "io" + "net/http" +) + +// UploadPartRequest wrapper for the UploadPart operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/objectstorage/UploadPart.go.html to see an example of how to use UploadPartRequest. +type UploadPartRequest struct { + + // The Object Storage namespace used for the request. + NamespaceName *string `mandatory:"true" contributesTo:"path" name:"namespaceName"` + + // The name of the bucket. Avoid entering confidential information. + // Example: `my-new-bucket1` + BucketName *string `mandatory:"true" contributesTo:"path" name:"bucketName"` + + // The name of the object. Avoid entering confidential information. + // Example: `test/object1.log` + ObjectName *string `mandatory:"true" contributesTo:"path" name:"objectName"` + + // The upload ID for a multipart upload. + UploadId *string `mandatory:"true" contributesTo:"query" name:"uploadId"` + + // The part number that identifies the object part currently being uploaded. + UploadPartNum *int `mandatory:"true" contributesTo:"query" name:"uploadPartNum"` + + // The content length of the body. + ContentLength *int64 `mandatory:"false" contributesTo:"header" name:"Content-Length"` + + // The part being uploaded to the Object Storage service. + UploadPartBody io.ReadCloser `mandatory:"true" contributesTo:"body" encoding:"binary"` + + // The client request ID for tracing. + OpcClientRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-client-request-id"` + + // The entity tag (ETag) to match with the ETag of an existing resource. If the specified ETag matches the ETag of + // the existing resource, GET and HEAD requests will return the resource and PUT and POST requests will upload + // the resource. + IfMatch *string `mandatory:"false" contributesTo:"header" name:"if-match"` + + // The entity tag (ETag) to avoid matching. The only valid value is '*', which indicates that the request should + // fail if the resource already exists. + IfNoneMatch *string `mandatory:"false" contributesTo:"header" name:"if-none-match"` + + // 100-continue + Expect *string `mandatory:"false" contributesTo:"header" name:"Expect"` + + // The optional base-64 header that defines the encoded MD5 hash of the body. If the optional Content-MD5 header is present, Object + // Storage performs an integrity check on the body of the HTTP request by computing the MD5 hash for the body and comparing it to the + // MD5 hash supplied in the header. If the two hashes do not match, the object is rejected and an HTTP-400 Unmatched Content MD5 error + // is returned with the message: + // "The computed MD5 of the request body (ACTUAL_MD5) does not match the Content-MD5 header (HEADER_MD5)" + ContentMD5 *string `mandatory:"false" contributesTo:"header" name:"Content-MD5"` + + // The optional header that specifies "AES256" as the encryption algorithm. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerAlgorithm *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-algorithm"` + + // The optional header that specifies the base64-encoded 256-bit encryption key to use to encrypt or + // decrypt the data. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerKey *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-key"` + + // The optional header that specifies the base64-encoded SHA256 hash of the encryption key. This + // value is used to check the integrity of the encryption key. For more information, see + // Using Your Own Keys for Server-Side Encryption (https://docs.cloud.oracle.com/Content/Object/Tasks/usingyourencryptionkeys.htm). + OpcSseCustomerKeySha256 *string `mandatory:"false" contributesTo:"header" name:"opc-sse-customer-key-sha256"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of a master encryption key used to call the Key + // Management service to generate a data encryption key or to encrypt or decrypt a data encryption key. + OpcSseKmsKeyId *string `mandatory:"false" contributesTo:"header" name:"opc-sse-kms-key-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request UploadPartRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request UploadPartRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + httpRequest, err := common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) + if err == nil && binaryRequestBody.Seekable() { + common.UpdateRequestBinaryBody(&httpRequest, binaryRequestBody) + } + return httpRequest, err +} + +// BinaryRequestBody implements the OCIRequest interface +func (request UploadPartRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + rsc := common.NewOCIReadSeekCloser(request.UploadPartBody) + if rsc.Seekable() { + return rsc, true + } + return nil, true + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request UploadPartRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// UploadPartResponse wrapper for the UploadPart operation +type UploadPartResponse struct { + + // The underlying http response + RawResponse *http.Response + + // Echoes back the value passed in the opc-client-request-id header, for use by clients when debugging. + OpcClientRequestId *string `presentIn:"header" name:"opc-client-request-id"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular + // request, provide this request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` + + // The base64-encoded MD5 hash of the request body, as computed by the server. + OpcContentMd5 *string `presentIn:"header" name:"opc-content-md5"` + + // The entity tag (ETag) for the object. + ETag *string `presentIn:"header" name:"etag"` +} + +func (response UploadPartResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response UploadPartResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request.go new file mode 100644 index 000000000..369250caf --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request.go @@ -0,0 +1,111 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// WorkRequest A description of workRequest status. +type WorkRequest struct { + + // The type of work request. + OperationType WorkRequestOperationTypeEnum `mandatory:"false" json:"operationType,omitempty"` + + // The status of the specified work request. + Status WorkRequestStatusEnum `mandatory:"false" json:"status,omitempty"` + + // The id of the work request. + Id *string `mandatory:"false" json:"id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the compartment that contains the work request. Work + // requests are scoped to the same compartment as the resource the work request affects. + // If the work request affects multiple resources and those resources are not in the same compartment, the OCID of + // the primary resource is used. For example, you can copy an object in a bucket in one compartment to a bucket in + // another compartment. In this case, the OCID of the source compartment is used. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + Resources []WorkRequestResource `mandatory:"false" json:"resources"` + + // Percentage of the work request completed. + PercentComplete *float32 `mandatory:"false" json:"percentComplete"` + + // The date and time the work request was created, as described in + // RFC 3339 (https://tools.ietf.org/html/rfc3339). + TimeAccepted *common.SDKTime `mandatory:"false" json:"timeAccepted"` + + // The date and time the work request was started, as described in + // RFC 3339 (https://tools.ietf.org/html/rfc3339). + TimeStarted *common.SDKTime `mandatory:"false" json:"timeStarted"` + + // The date and time the work request was finished, as described in + // RFC 3339 (https://tools.ietf.org/html/rfc3339). + TimeFinished *common.SDKTime `mandatory:"false" json:"timeFinished"` +} + +func (m WorkRequest) String() string { + return common.PointerString(m) +} + +// WorkRequestOperationTypeEnum Enum with underlying type: string +type WorkRequestOperationTypeEnum string + +// Set of constants representing the allowable values for WorkRequestOperationTypeEnum +const ( + WorkRequestOperationTypeCopyObject WorkRequestOperationTypeEnum = "COPY_OBJECT" + WorkRequestOperationTypeReencrypt WorkRequestOperationTypeEnum = "REENCRYPT" +) + +var mappingWorkRequestOperationType = map[string]WorkRequestOperationTypeEnum{ + "COPY_OBJECT": WorkRequestOperationTypeCopyObject, + "REENCRYPT": WorkRequestOperationTypeReencrypt, +} + +// GetWorkRequestOperationTypeEnumValues Enumerates the set of values for WorkRequestOperationTypeEnum +func GetWorkRequestOperationTypeEnumValues() []WorkRequestOperationTypeEnum { + values := make([]WorkRequestOperationTypeEnum, 0) + for _, v := range mappingWorkRequestOperationType { + values = append(values, v) + } + return values +} + +// WorkRequestStatusEnum Enum with underlying type: string +type WorkRequestStatusEnum string + +// Set of constants representing the allowable values for WorkRequestStatusEnum +const ( + WorkRequestStatusAccepted WorkRequestStatusEnum = "ACCEPTED" + WorkRequestStatusInProgress WorkRequestStatusEnum = "IN_PROGRESS" + WorkRequestStatusFailed WorkRequestStatusEnum = "FAILED" + WorkRequestStatusCompleted WorkRequestStatusEnum = "COMPLETED" + WorkRequestStatusCanceling WorkRequestStatusEnum = "CANCELING" + WorkRequestStatusCanceled WorkRequestStatusEnum = "CANCELED" +) + +var mappingWorkRequestStatus = map[string]WorkRequestStatusEnum{ + "ACCEPTED": WorkRequestStatusAccepted, + "IN_PROGRESS": WorkRequestStatusInProgress, + "FAILED": WorkRequestStatusFailed, + "COMPLETED": WorkRequestStatusCompleted, + "CANCELING": WorkRequestStatusCanceling, + "CANCELED": WorkRequestStatusCanceled, +} + +// GetWorkRequestStatusEnumValues Enumerates the set of values for WorkRequestStatusEnum +func GetWorkRequestStatusEnumValues() []WorkRequestStatusEnum { + values := make([]WorkRequestStatusEnum, 0) + for _, v := range mappingWorkRequestStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_error.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_error.go new file mode 100644 index 000000000..99a59010b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_error.go @@ -0,0 +1,34 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// WorkRequestError The representation of WorkRequestError +type WorkRequestError struct { + + // A machine-usable code for the error that occurred. For the list of error codes, + // see API Errors (https://docs.cloud.oracle.com/Content/API/References/apierrors.htm). + Code *string `mandatory:"false" json:"code"` + + // A human-readable description of the issue that produced the error. + Message *string `mandatory:"false" json:"message"` + + // The time the error occurred. + Timestamp *common.SDKTime `mandatory:"false" json:"timestamp"` +} + +func (m WorkRequestError) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_log_entry.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_log_entry.go new file mode 100644 index 000000000..160fa0b1a --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_log_entry.go @@ -0,0 +1,31 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// WorkRequestLogEntry The representation of WorkRequestLogEntry +type WorkRequestLogEntry struct { + + // Human-readable log message. + Message *string `mandatory:"false" json:"message"` + + // The date and time the log message was written, as described in + // RFC 3339 (https://tools.ietf.org/html/rfc3339). + Timestamp *common.SDKTime `mandatory:"false" json:"timestamp"` +} + +func (m WorkRequestLogEntry) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_resource.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_resource.go new file mode 100644 index 000000000..6541ce9d5 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_resource.go @@ -0,0 +1,72 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// WorkRequestResource The representation of WorkRequestResource +type WorkRequestResource struct { + + // The status of the work request. + ActionType WorkRequestResourceActionTypeEnum `mandatory:"false" json:"actionType,omitempty"` + + // The resource type the work request affects. + EntityType *string `mandatory:"false" json:"entityType"` + + // The resource type identifier. + Identifier *string `mandatory:"false" json:"identifier"` + + // The URI path that you can use for a GET request to access the resource metadata. + EntityUri *string `mandatory:"false" json:"entityUri"` + + // The metadata of the resource. + Metadata map[string]string `mandatory:"false" json:"metadata"` +} + +func (m WorkRequestResource) String() string { + return common.PointerString(m) +} + +// WorkRequestResourceActionTypeEnum Enum with underlying type: string +type WorkRequestResourceActionTypeEnum string + +// Set of constants representing the allowable values for WorkRequestResourceActionTypeEnum +const ( + WorkRequestResourceActionTypeCreated WorkRequestResourceActionTypeEnum = "CREATED" + WorkRequestResourceActionTypeUpdated WorkRequestResourceActionTypeEnum = "UPDATED" + WorkRequestResourceActionTypeDeleted WorkRequestResourceActionTypeEnum = "DELETED" + WorkRequestResourceActionTypeRelated WorkRequestResourceActionTypeEnum = "RELATED" + WorkRequestResourceActionTypeInProgress WorkRequestResourceActionTypeEnum = "IN_PROGRESS" + WorkRequestResourceActionTypeRead WorkRequestResourceActionTypeEnum = "READ" + WorkRequestResourceActionTypeWritten WorkRequestResourceActionTypeEnum = "WRITTEN" +) + +var mappingWorkRequestResourceActionType = map[string]WorkRequestResourceActionTypeEnum{ + "CREATED": WorkRequestResourceActionTypeCreated, + "UPDATED": WorkRequestResourceActionTypeUpdated, + "DELETED": WorkRequestResourceActionTypeDeleted, + "RELATED": WorkRequestResourceActionTypeRelated, + "IN_PROGRESS": WorkRequestResourceActionTypeInProgress, + "READ": WorkRequestResourceActionTypeRead, + "WRITTEN": WorkRequestResourceActionTypeWritten, +} + +// GetWorkRequestResourceActionTypeEnumValues Enumerates the set of values for WorkRequestResourceActionTypeEnum +func GetWorkRequestResourceActionTypeEnumValues() []WorkRequestResourceActionTypeEnum { + values := make([]WorkRequestResourceActionTypeEnum, 0) + for _, v := range mappingWorkRequestResourceActionType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_resource_metadata_key.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_resource_metadata_key.go new file mode 100644 index 000000000..77c1ae99f --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_resource_metadata_key.go @@ -0,0 +1,39 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +// WorkRequestResourceMetadataKeyEnum Enum with underlying type: string +type WorkRequestResourceMetadataKeyEnum string + +// Set of constants representing the allowable values for WorkRequestResourceMetadataKeyEnum +const ( + WorkRequestResourceMetadataKeyRegion WorkRequestResourceMetadataKeyEnum = "REGION" + WorkRequestResourceMetadataKeyNamespace WorkRequestResourceMetadataKeyEnum = "NAMESPACE" + WorkRequestResourceMetadataKeyBucket WorkRequestResourceMetadataKeyEnum = "BUCKET" + WorkRequestResourceMetadataKeyObject WorkRequestResourceMetadataKeyEnum = "OBJECT" +) + +var mappingWorkRequestResourceMetadataKey = map[string]WorkRequestResourceMetadataKeyEnum{ + "REGION": WorkRequestResourceMetadataKeyRegion, + "NAMESPACE": WorkRequestResourceMetadataKeyNamespace, + "BUCKET": WorkRequestResourceMetadataKeyBucket, + "OBJECT": WorkRequestResourceMetadataKeyObject, +} + +// GetWorkRequestResourceMetadataKeyEnumValues Enumerates the set of values for WorkRequestResourceMetadataKeyEnum +func GetWorkRequestResourceMetadataKeyEnumValues() []WorkRequestResourceMetadataKeyEnum { + values := make([]WorkRequestResourceMetadataKeyEnum, 0) + for _, v := range mappingWorkRequestResourceMetadataKey { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_summary.go new file mode 100644 index 000000000..acecf65e8 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/objectstorage/work_request_summary.go @@ -0,0 +1,111 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Object Storage Service API +// +// Common set of Object Storage and Archive Storage APIs for managing buckets, objects, and related resources. +// For more information, see Overview of Object Storage (https://docs.cloud.oracle.com/Content/Object/Concepts/objectstorageoverview.htm) and +// Overview of Archive Storage (https://docs.cloud.oracle.com/Content/Archive/Concepts/archivestorageoverview.htm). +// + +package objectstorage + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// WorkRequestSummary A summary of the status of a work request. +type WorkRequestSummary struct { + + // The type of work request. + OperationType WorkRequestSummaryOperationTypeEnum `mandatory:"false" json:"operationType,omitempty"` + + // The status of a specified work request. + Status WorkRequestSummaryStatusEnum `mandatory:"false" json:"status,omitempty"` + + // The id of the work request. + Id *string `mandatory:"false" json:"id"` + + // The OCID (https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm) of the compartment that contains the work request. Work + // requests are scoped to the same compartment as the resource the work request affects. + // If the work request affects multiple resources and those resources are not in the same compartment, the OCID of + // the primary resource is used. For example, you can copy an object in a bucket in one compartment to a bucket in + // another compartment. In this case, the OCID of the source compartment is used. + CompartmentId *string `mandatory:"false" json:"compartmentId"` + + Resources []WorkRequestResource `mandatory:"false" json:"resources"` + + // Percentage of the work request completed. + PercentComplete *float32 `mandatory:"false" json:"percentComplete"` + + // The date and time the work request was created, as described in + // RFC 3339 (https://tools.ietf.org/html/rfc3339). + TimeAccepted *common.SDKTime `mandatory:"false" json:"timeAccepted"` + + // The date and time the work request was started, as described in + // RFC 3339 (https://tools.ietf.org/html/rfc3339). + TimeStarted *common.SDKTime `mandatory:"false" json:"timeStarted"` + + // The date and time the work request was finished, as described in + // RFC 3339 (https://tools.ietf.org/html/rfc3339). + TimeFinished *common.SDKTime `mandatory:"false" json:"timeFinished"` +} + +func (m WorkRequestSummary) String() string { + return common.PointerString(m) +} + +// WorkRequestSummaryOperationTypeEnum Enum with underlying type: string +type WorkRequestSummaryOperationTypeEnum string + +// Set of constants representing the allowable values for WorkRequestSummaryOperationTypeEnum +const ( + WorkRequestSummaryOperationTypeCopyObject WorkRequestSummaryOperationTypeEnum = "COPY_OBJECT" + WorkRequestSummaryOperationTypeReencrypt WorkRequestSummaryOperationTypeEnum = "REENCRYPT" +) + +var mappingWorkRequestSummaryOperationType = map[string]WorkRequestSummaryOperationTypeEnum{ + "COPY_OBJECT": WorkRequestSummaryOperationTypeCopyObject, + "REENCRYPT": WorkRequestSummaryOperationTypeReencrypt, +} + +// GetWorkRequestSummaryOperationTypeEnumValues Enumerates the set of values for WorkRequestSummaryOperationTypeEnum +func GetWorkRequestSummaryOperationTypeEnumValues() []WorkRequestSummaryOperationTypeEnum { + values := make([]WorkRequestSummaryOperationTypeEnum, 0) + for _, v := range mappingWorkRequestSummaryOperationType { + values = append(values, v) + } + return values +} + +// WorkRequestSummaryStatusEnum Enum with underlying type: string +type WorkRequestSummaryStatusEnum string + +// Set of constants representing the allowable values for WorkRequestSummaryStatusEnum +const ( + WorkRequestSummaryStatusAccepted WorkRequestSummaryStatusEnum = "ACCEPTED" + WorkRequestSummaryStatusInProgress WorkRequestSummaryStatusEnum = "IN_PROGRESS" + WorkRequestSummaryStatusFailed WorkRequestSummaryStatusEnum = "FAILED" + WorkRequestSummaryStatusCompleted WorkRequestSummaryStatusEnum = "COMPLETED" + WorkRequestSummaryStatusCanceling WorkRequestSummaryStatusEnum = "CANCELING" + WorkRequestSummaryStatusCanceled WorkRequestSummaryStatusEnum = "CANCELED" +) + +var mappingWorkRequestSummaryStatus = map[string]WorkRequestSummaryStatusEnum{ + "ACCEPTED": WorkRequestSummaryStatusAccepted, + "IN_PROGRESS": WorkRequestSummaryStatusInProgress, + "FAILED": WorkRequestSummaryStatusFailed, + "COMPLETED": WorkRequestSummaryStatusCompleted, + "CANCELING": WorkRequestSummaryStatusCanceling, + "CANCELED": WorkRequestSummaryStatusCanceled, +} + +// GetWorkRequestSummaryStatusEnumValues Enumerates the set of values for WorkRequestSummaryStatusEnum +func GetWorkRequestSummaryStatusEnumValues() []WorkRequestSummaryStatusEnum { + values := make([]WorkRequestSummaryStatusEnum, 0) + for _, v := range mappingWorkRequestSummaryStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/get_work_request_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/get_work_request_request_response.go new file mode 100644 index 000000000..d9fbc27ca --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/get_work_request_request_response.go @@ -0,0 +1,74 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package workrequests + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// GetWorkRequestRequest wrapper for the GetWorkRequest operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/workrequests/GetWorkRequest.go.html to see an example of how to use GetWorkRequestRequest. +type GetWorkRequestRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the work request. + WorkRequestId *string `mandatory:"true" contributesTo:"path" name:"workRequestId"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request GetWorkRequestRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request GetWorkRequestRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request GetWorkRequestRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request GetWorkRequestRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// GetWorkRequestResponse wrapper for the GetWorkRequest operation +type GetWorkRequestResponse struct { + + // The underlying http response + RawResponse *http.Response + + // The WorkRequest instance + WorkRequest `presentIn:"body"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response GetWorkRequestResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response GetWorkRequestResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/list_work_request_errors_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/list_work_request_errors_request_response.go new file mode 100644 index 000000000..c10cdd2d2 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/list_work_request_errors_request_response.go @@ -0,0 +1,115 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package workrequests + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListWorkRequestErrorsRequest wrapper for the ListWorkRequestErrors operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/workrequests/ListWorkRequestErrors.go.html to see an example of how to use ListWorkRequestErrorsRequest. +type ListWorkRequestErrorsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the work request. + WorkRequestId *string `mandatory:"true" contributesTo:"path" name:"workRequestId"` + + // For list pagination. The maximum number of results per page, or items to return in a + // paginated "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the + // previous "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). + SortOrder ListWorkRequestErrorsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListWorkRequestErrorsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListWorkRequestErrorsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListWorkRequestErrorsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListWorkRequestErrorsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListWorkRequestErrorsResponse wrapper for the ListWorkRequestErrors operation +type ListWorkRequestErrorsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []WorkRequestError instances + Items []WorkRequestError `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages of + // results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListWorkRequestErrorsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListWorkRequestErrorsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListWorkRequestErrorsSortOrderEnum Enum with underlying type: string +type ListWorkRequestErrorsSortOrderEnum string + +// Set of constants representing the allowable values for ListWorkRequestErrorsSortOrderEnum +const ( + ListWorkRequestErrorsSortOrderAsc ListWorkRequestErrorsSortOrderEnum = "ASC" + ListWorkRequestErrorsSortOrderDesc ListWorkRequestErrorsSortOrderEnum = "DESC" +) + +var mappingListWorkRequestErrorsSortOrder = map[string]ListWorkRequestErrorsSortOrderEnum{ + "ASC": ListWorkRequestErrorsSortOrderAsc, + "DESC": ListWorkRequestErrorsSortOrderDesc, +} + +// GetListWorkRequestErrorsSortOrderEnumValues Enumerates the set of values for ListWorkRequestErrorsSortOrderEnum +func GetListWorkRequestErrorsSortOrderEnumValues() []ListWorkRequestErrorsSortOrderEnum { + values := make([]ListWorkRequestErrorsSortOrderEnum, 0) + for _, v := range mappingListWorkRequestErrorsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/list_work_request_logs_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/list_work_request_logs_request_response.go new file mode 100644 index 000000000..bb0ec190b --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/list_work_request_logs_request_response.go @@ -0,0 +1,115 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package workrequests + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListWorkRequestLogsRequest wrapper for the ListWorkRequestLogs operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/workrequests/ListWorkRequestLogs.go.html to see an example of how to use ListWorkRequestLogsRequest. +type ListWorkRequestLogsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the work request. + WorkRequestId *string `mandatory:"true" contributesTo:"path" name:"workRequestId"` + + // For list pagination. The maximum number of results per page, or items to return in a + // paginated "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the + // previous "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // The sort order to use, either ascending (`ASC`) or descending (`DESC`). + SortOrder ListWorkRequestLogsSortOrderEnum `mandatory:"false" contributesTo:"query" name:"sortOrder" omitEmpty:"true"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListWorkRequestLogsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListWorkRequestLogsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListWorkRequestLogsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListWorkRequestLogsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListWorkRequestLogsResponse wrapper for the ListWorkRequestLogs operation +type ListWorkRequestLogsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []WorkRequestLogEntry instances + Items []WorkRequestLogEntry `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages of + // results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListWorkRequestLogsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListWorkRequestLogsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} + +// ListWorkRequestLogsSortOrderEnum Enum with underlying type: string +type ListWorkRequestLogsSortOrderEnum string + +// Set of constants representing the allowable values for ListWorkRequestLogsSortOrderEnum +const ( + ListWorkRequestLogsSortOrderAsc ListWorkRequestLogsSortOrderEnum = "ASC" + ListWorkRequestLogsSortOrderDesc ListWorkRequestLogsSortOrderEnum = "DESC" +) + +var mappingListWorkRequestLogsSortOrder = map[string]ListWorkRequestLogsSortOrderEnum{ + "ASC": ListWorkRequestLogsSortOrderAsc, + "DESC": ListWorkRequestLogsSortOrderDesc, +} + +// GetListWorkRequestLogsSortOrderEnumValues Enumerates the set of values for ListWorkRequestLogsSortOrderEnum +func GetListWorkRequestLogsSortOrderEnumValues() []ListWorkRequestLogsSortOrderEnum { + values := make([]ListWorkRequestLogsSortOrderEnum, 0) + for _, v := range mappingListWorkRequestLogsSortOrder { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/list_work_requests_request_response.go b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/list_work_requests_request_response.go new file mode 100644 index 000000000..d8656b47e --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/list_work_requests_request_response.go @@ -0,0 +1,92 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +package workrequests + +import ( + "github.com/oracle/oci-go-sdk/v54/common" + "net/http" +) + +// ListWorkRequestsRequest wrapper for the ListWorkRequests operation +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/workrequests/ListWorkRequests.go.html to see an example of how to use ListWorkRequestsRequest. +type ListWorkRequestsRequest struct { + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment. + CompartmentId *string `mandatory:"true" contributesTo:"query" name:"compartmentId"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the resource. + ResourceId *string `mandatory:"false" contributesTo:"query" name:"resourceId"` + + // For list pagination. The maximum number of results per page, or items to return in a + // paginated "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Limit *int `mandatory:"false" contributesTo:"query" name:"limit"` + + // For list pagination. The value of the `opc-next-page` response header from the + // previous "List" call. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + Page *string `mandatory:"false" contributesTo:"query" name:"page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `mandatory:"false" contributesTo:"header" name:"opc-request-id"` + + // Metadata about the request. This information will not be transmitted to the service, but + // represents information that the SDK will consume to drive retry behavior. + RequestMetadata common.RequestMetadata +} + +func (request ListWorkRequestsRequest) String() string { + return common.PointerString(request) +} + +// HTTPRequest implements the OCIRequest interface +func (request ListWorkRequestsRequest) HTTPRequest(method, path string, binaryRequestBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (http.Request, error) { + + return common.MakeDefaultHTTPRequestWithTaggedStructAndExtraHeaders(method, path, request, extraHeaders) +} + +// BinaryRequestBody implements the OCIRequest interface +func (request ListWorkRequestsRequest) BinaryRequestBody() (*common.OCIReadSeekCloser, bool) { + + return nil, false + +} + +// RetryPolicy implements the OCIRetryableRequest interface. This retrieves the specified retry policy. +func (request ListWorkRequestsRequest) RetryPolicy() *common.RetryPolicy { + return request.RequestMetadata.RetryPolicy +} + +// ListWorkRequestsResponse wrapper for the ListWorkRequests operation +type ListWorkRequestsResponse struct { + + // The underlying http response + RawResponse *http.Response + + // A list of []WorkRequestSummary instances + Items []WorkRequestSummary `presentIn:"body"` + + // For list pagination. When this header appears in the response, additional pages of + // results remain. For important details about how pagination works, see + // List Pagination (https://docs.cloud.oracle.com/iaas/Content/API/Concepts/usingapi.htm#nine). + OpcNextPage *string `presentIn:"header" name:"opc-next-page"` + + // Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a + // particular request, please provide the request ID. + OpcRequestId *string `presentIn:"header" name:"opc-request-id"` +} + +func (response ListWorkRequestsResponse) String() string { + return common.PointerString(response) +} + +// HTTPResponse implements the OCIResponse interface +func (response ListWorkRequestsResponse) HTTPResponse() *http.Response { + return response.RawResponse +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request.go b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request.go new file mode 100644 index 000000000..e4b19c414 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request.go @@ -0,0 +1,87 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Work Requests API +// +// Many of the API operations that you use to create and configure Compute resources do not take effect +// immediately. In these cases, the operation spawns an asynchronous workflow to fulfill the request. +// Work requests provide visibility into the status of these in-progress, long-running workflows. +// For more information about work requests and the operations that spawn work requests, see +// Viewing the State of a Compute Work Request (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/viewingworkrequestcompute.htm). +// + +package workrequests + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// WorkRequest An asynchronous work request. +type WorkRequest struct { + + // The asynchronous operation tracked by this work request. + OperationType *string `mandatory:"true" json:"operationType"` + + // The status of the work request. + Status WorkRequestStatusEnum `mandatory:"true" json:"status"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the work request. + Id *string `mandatory:"true" json:"id"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment + // that contains the work request. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The resources that are affected by this work request. + Resources []WorkRequestResource `mandatory:"true" json:"resources"` + + // The percentage complete of the operation tracked by this work request. + PercentComplete *float32 `mandatory:"true" json:"percentComplete"` + + // The date and time the work request was created, in the format defined by RFC3339. + TimeAccepted *common.SDKTime `mandatory:"true" json:"timeAccepted"` + + // The date and time the work request transitioned from `ACCEPTED` to `IN_PROGRESS`, + // in the format defined by RFC3339. + TimeStarted *common.SDKTime `mandatory:"false" json:"timeStarted"` + + // The date and time the work request reached a terminal state, either `FAILED` or `SUCCEEDED`. + // Format is defined by RFC3339. + TimeFinished *common.SDKTime `mandatory:"false" json:"timeFinished"` +} + +func (m WorkRequest) String() string { + return common.PointerString(m) +} + +// WorkRequestStatusEnum Enum with underlying type: string +type WorkRequestStatusEnum string + +// Set of constants representing the allowable values for WorkRequestStatusEnum +const ( + WorkRequestStatusAccepted WorkRequestStatusEnum = "ACCEPTED" + WorkRequestStatusInProgress WorkRequestStatusEnum = "IN_PROGRESS" + WorkRequestStatusFailed WorkRequestStatusEnum = "FAILED" + WorkRequestStatusSucceeded WorkRequestStatusEnum = "SUCCEEDED" + WorkRequestStatusCanceling WorkRequestStatusEnum = "CANCELING" + WorkRequestStatusCanceled WorkRequestStatusEnum = "CANCELED" +) + +var mappingWorkRequestStatus = map[string]WorkRequestStatusEnum{ + "ACCEPTED": WorkRequestStatusAccepted, + "IN_PROGRESS": WorkRequestStatusInProgress, + "FAILED": WorkRequestStatusFailed, + "SUCCEEDED": WorkRequestStatusSucceeded, + "CANCELING": WorkRequestStatusCanceling, + "CANCELED": WorkRequestStatusCanceled, +} + +// GetWorkRequestStatusEnumValues Enumerates the set of values for WorkRequestStatusEnum +func GetWorkRequestStatusEnumValues() []WorkRequestStatusEnum { + values := make([]WorkRequestStatusEnum, 0) + for _, v := range mappingWorkRequestStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_error.go b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_error.go new file mode 100644 index 000000000..e4dfe9061 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_error.go @@ -0,0 +1,35 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Work Requests API +// +// Many of the API operations that you use to create and configure Compute resources do not take effect +// immediately. In these cases, the operation spawns an asynchronous workflow to fulfill the request. +// Work requests provide visibility into the status of these in-progress, long-running workflows. +// For more information about work requests and the operations that spawn work requests, see +// Viewing the State of a Compute Work Request (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/viewingworkrequestcompute.htm). +// + +package workrequests + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// WorkRequestError An error encountered while executing an operation that is tracked by a work request. +type WorkRequestError struct { + + // A machine-usable code for the error that occured. + Code *string `mandatory:"true" json:"code"` + + // A human-readable error string. + Message *string `mandatory:"true" json:"message"` + + // The date and time the error occurred. + Timestamp *common.SDKTime `mandatory:"true" json:"timestamp"` +} + +func (m WorkRequestError) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_log_entry.go b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_log_entry.go new file mode 100644 index 000000000..5b6546522 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_log_entry.go @@ -0,0 +1,32 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Work Requests API +// +// Many of the API operations that you use to create and configure Compute resources do not take effect +// immediately. In these cases, the operation spawns an asynchronous workflow to fulfill the request. +// Work requests provide visibility into the status of these in-progress, long-running workflows. +// For more information about work requests and the operations that spawn work requests, see +// Viewing the State of a Compute Work Request (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/viewingworkrequestcompute.htm). +// + +package workrequests + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// WorkRequestLogEntry A log message from executing an operation that is tracked by a work request. +type WorkRequestLogEntry struct { + + // A human-readable log message. + Message *string `mandatory:"true" json:"message"` + + // The date and time the log message was written. + Timestamp *common.SDKTime `mandatory:"true" json:"timestamp"` +} + +func (m WorkRequestLogEntry) String() string { + return common.PointerString(m) +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_resource.go b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_resource.go new file mode 100644 index 000000000..679a68272 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_resource.go @@ -0,0 +1,70 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Work Requests API +// +// Many of the API operations that you use to create and configure Compute resources do not take effect +// immediately. In these cases, the operation spawns an asynchronous workflow to fulfill the request. +// Work requests provide visibility into the status of these in-progress, long-running workflows. +// For more information about work requests and the operations that spawn work requests, see +// Viewing the State of a Compute Work Request (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/viewingworkrequestcompute.htm). +// + +package workrequests + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// WorkRequestResource A resource that is created or operated on by an asynchronous operation that is tracked by +// a work request. +type WorkRequestResource struct { + + // The way in which this resource was affected by the operation that spawned the work + // request. + ActionType WorkRequestResourceActionTypeEnum `mandatory:"true" json:"actionType"` + + // The resource type the work request affects. + EntityType *string `mandatory:"true" json:"entityType"` + + // An OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) or other unique identifier for the + // resource. + Identifier *string `mandatory:"true" json:"identifier"` + + // The URI path that you can use for a GET request to access the resource metadata. + EntityUri *string `mandatory:"false" json:"entityUri"` +} + +func (m WorkRequestResource) String() string { + return common.PointerString(m) +} + +// WorkRequestResourceActionTypeEnum Enum with underlying type: string +type WorkRequestResourceActionTypeEnum string + +// Set of constants representing the allowable values for WorkRequestResourceActionTypeEnum +const ( + WorkRequestResourceActionTypeCreated WorkRequestResourceActionTypeEnum = "CREATED" + WorkRequestResourceActionTypeUpdated WorkRequestResourceActionTypeEnum = "UPDATED" + WorkRequestResourceActionTypeDeleted WorkRequestResourceActionTypeEnum = "DELETED" + WorkRequestResourceActionTypeRelated WorkRequestResourceActionTypeEnum = "RELATED" + WorkRequestResourceActionTypeInProgress WorkRequestResourceActionTypeEnum = "IN_PROGRESS" +) + +var mappingWorkRequestResourceActionType = map[string]WorkRequestResourceActionTypeEnum{ + "CREATED": WorkRequestResourceActionTypeCreated, + "UPDATED": WorkRequestResourceActionTypeUpdated, + "DELETED": WorkRequestResourceActionTypeDeleted, + "RELATED": WorkRequestResourceActionTypeRelated, + "IN_PROGRESS": WorkRequestResourceActionTypeInProgress, +} + +// GetWorkRequestResourceActionTypeEnumValues Enumerates the set of values for WorkRequestResourceActionTypeEnum +func GetWorkRequestResourceActionTypeEnumValues() []WorkRequestResourceActionTypeEnum { + values := make([]WorkRequestResourceActionTypeEnum, 0) + for _, v := range mappingWorkRequestResourceActionType { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_summary.go b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_summary.go new file mode 100644 index 000000000..d0b7cce47 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/work_request_summary.go @@ -0,0 +1,84 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Work Requests API +// +// Many of the API operations that you use to create and configure Compute resources do not take effect +// immediately. In these cases, the operation spawns an asynchronous workflow to fulfill the request. +// Work requests provide visibility into the status of these in-progress, long-running workflows. +// For more information about work requests and the operations that spawn work requests, see +// Viewing the State of a Compute Work Request (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/viewingworkrequestcompute.htm). +// + +package workrequests + +import ( + "github.com/oracle/oci-go-sdk/v54/common" +) + +// WorkRequestSummary A summary of the status of a work request. +type WorkRequestSummary struct { + + // The asynchronous operation tracked by this work request. + OperationType *string `mandatory:"true" json:"operationType"` + + // The status of the work request. + Status WorkRequestSummaryStatusEnum `mandatory:"true" json:"status"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the work request. + Id *string `mandatory:"true" json:"id"` + + // The OCID (https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing + // this work request. + CompartmentId *string `mandatory:"true" json:"compartmentId"` + + // The percentage complete of the operation tracked by this work request. + PercentComplete *float32 `mandatory:"true" json:"percentComplete"` + + // The date and time the work request was created, in the format defined by RFC3339. + TimeAccepted *common.SDKTime `mandatory:"true" json:"timeAccepted"` + + // The date and time the work request transitioned from `ACCEPTED` to `IN_PROGRESS`, in + // the format defined by RFC3339. + TimeStarted *common.SDKTime `mandatory:"false" json:"timeStarted"` + + // The date and time the work request reached a terminal state, either `FAILED` or `SUCCEEDED`. + // Format is defined by RFC3339. + TimeFinished *common.SDKTime `mandatory:"false" json:"timeFinished"` +} + +func (m WorkRequestSummary) String() string { + return common.PointerString(m) +} + +// WorkRequestSummaryStatusEnum Enum with underlying type: string +type WorkRequestSummaryStatusEnum string + +// Set of constants representing the allowable values for WorkRequestSummaryStatusEnum +const ( + WorkRequestSummaryStatusAccepted WorkRequestSummaryStatusEnum = "ACCEPTED" + WorkRequestSummaryStatusInProgress WorkRequestSummaryStatusEnum = "IN_PROGRESS" + WorkRequestSummaryStatusFailed WorkRequestSummaryStatusEnum = "FAILED" + WorkRequestSummaryStatusSucceeded WorkRequestSummaryStatusEnum = "SUCCEEDED" + WorkRequestSummaryStatusCanceling WorkRequestSummaryStatusEnum = "CANCELING" + WorkRequestSummaryStatusCanceled WorkRequestSummaryStatusEnum = "CANCELED" +) + +var mappingWorkRequestSummaryStatus = map[string]WorkRequestSummaryStatusEnum{ + "ACCEPTED": WorkRequestSummaryStatusAccepted, + "IN_PROGRESS": WorkRequestSummaryStatusInProgress, + "FAILED": WorkRequestSummaryStatusFailed, + "SUCCEEDED": WorkRequestSummaryStatusSucceeded, + "CANCELING": WorkRequestSummaryStatusCanceling, + "CANCELED": WorkRequestSummaryStatusCanceled, +} + +// GetWorkRequestSummaryStatusEnumValues Enumerates the set of values for WorkRequestSummaryStatusEnum +func GetWorkRequestSummaryStatusEnumValues() []WorkRequestSummaryStatusEnum { + values := make([]WorkRequestSummaryStatusEnum, 0) + for _, v := range mappingWorkRequestSummaryStatus { + values = append(values, v) + } + return values +} diff --git a/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/workrequests_workrequest_client.go b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/workrequests_workrequest_client.go new file mode 100644 index 000000000..2bc7f4f04 --- /dev/null +++ b/vendor/github.com/oracle/oci-go-sdk/v54/workrequests/workrequests_workrequest_client.go @@ -0,0 +1,309 @@ +// Copyright (c) 2016, 2018, 2021, Oracle and/or its affiliates. All rights reserved. +// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. +// Code generated. DO NOT EDIT. + +// Work Requests API +// +// Many of the API operations that you use to create and configure Compute resources do not take effect +// immediately. In these cases, the operation spawns an asynchronous workflow to fulfill the request. +// Work requests provide visibility into the status of these in-progress, long-running workflows. +// For more information about work requests and the operations that spawn work requests, see +// Viewing the State of a Compute Work Request (https://docs.cloud.oracle.com/iaas/Content/Compute/Tasks/viewingworkrequestcompute.htm). +// + +package workrequests + +import ( + "context" + "fmt" + "github.com/oracle/oci-go-sdk/v54/common" + "github.com/oracle/oci-go-sdk/v54/common/auth" + "net/http" +) + +//WorkRequestClient a client for WorkRequest +type WorkRequestClient struct { + common.BaseClient + config *common.ConfigurationProvider +} + +// NewWorkRequestClientWithConfigurationProvider Creates a new default WorkRequest client with the given configuration provider. +// the configuration provider will be used for the default signer as well as reading the region +func NewWorkRequestClientWithConfigurationProvider(configProvider common.ConfigurationProvider) (client WorkRequestClient, err error) { + provider, err := auth.GetGenericConfigurationProvider(configProvider) + if err != nil { + return client, err + } + baseClient, e := common.NewClientWithConfig(provider) + if e != nil { + return client, e + } + return newWorkRequestClientFromBaseClient(baseClient, provider) +} + +// NewWorkRequestClientWithOboToken Creates a new default WorkRequest client with the given configuration provider. +// The obotoken will be added to default headers and signed; the configuration provider will be used for the signer +// as well as reading the region +func NewWorkRequestClientWithOboToken(configProvider common.ConfigurationProvider, oboToken string) (client WorkRequestClient, err error) { + baseClient, err := common.NewClientWithOboToken(configProvider, oboToken) + if err != nil { + return client, err + } + + return newWorkRequestClientFromBaseClient(baseClient, configProvider) +} + +func newWorkRequestClientFromBaseClient(baseClient common.BaseClient, configProvider common.ConfigurationProvider) (client WorkRequestClient, err error) { + // WorkRequest service default circuit breaker is enabled + baseClient.Configuration.CircuitBreaker = common.NewCircuitBreaker(common.DefaultCircuitBreakerSetting()) + common.ConfigCircuitBreakerFromEnvVar(&baseClient) + common.ConfigCircuitBreakerFromGlobalVar(&baseClient) + + client = WorkRequestClient{BaseClient: baseClient} + client.BasePath = "20160918" + err = client.setConfigurationProvider(configProvider) + return +} + +// SetRegion overrides the region of this client. +func (client *WorkRequestClient) SetRegion(region string) { + client.Host = common.StringToRegion(region).EndpointForTemplate("workrequests", "https://iaas.{region}.{secondLevelDomain}") +} + +// SetConfigurationProvider sets the configuration provider including the region, returns an error if is not valid +func (client *WorkRequestClient) setConfigurationProvider(configProvider common.ConfigurationProvider) error { + if ok, err := common.IsConfigurationProviderValid(configProvider); !ok { + return err + } + + // Error has been checked already + region, _ := configProvider.Region() + client.SetRegion(region) + client.config = &configProvider + return nil +} + +// ConfigurationProvider the ConfigurationProvider used in this client, or null if none set +func (client *WorkRequestClient) ConfigurationProvider() *common.ConfigurationProvider { + return client.config +} + +// GetWorkRequest Gets the details of a work request. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/workrequests/GetWorkRequest.go.html to see an example of how to use GetWorkRequest API. +func (client WorkRequestClient) GetWorkRequest(ctx context.Context, request GetWorkRequestRequest) (response GetWorkRequestResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.getWorkRequest, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = GetWorkRequestResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = GetWorkRequestResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(GetWorkRequestResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into GetWorkRequestResponse") + } + return +} + +// getWorkRequest implements the OCIOperation interface (enables retrying operations) +func (client WorkRequestClient) getWorkRequest(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/workRequests/{workRequestId}", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response GetWorkRequestResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListWorkRequestErrors Gets the errors for a work request. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/workrequests/ListWorkRequestErrors.go.html to see an example of how to use ListWorkRequestErrors API. +func (client WorkRequestClient) ListWorkRequestErrors(ctx context.Context, request ListWorkRequestErrorsRequest) (response ListWorkRequestErrorsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listWorkRequestErrors, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListWorkRequestErrorsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListWorkRequestErrorsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListWorkRequestErrorsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListWorkRequestErrorsResponse") + } + return +} + +// listWorkRequestErrors implements the OCIOperation interface (enables retrying operations) +func (client WorkRequestClient) listWorkRequestErrors(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/workRequests/{workRequestId}/errors", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListWorkRequestErrorsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListWorkRequestLogs Gets the logs for a work request. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/workrequests/ListWorkRequestLogs.go.html to see an example of how to use ListWorkRequestLogs API. +func (client WorkRequestClient) ListWorkRequestLogs(ctx context.Context, request ListWorkRequestLogsRequest) (response ListWorkRequestLogsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listWorkRequestLogs, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListWorkRequestLogsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListWorkRequestLogsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListWorkRequestLogsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListWorkRequestLogsResponse") + } + return +} + +// listWorkRequestLogs implements the OCIOperation interface (enables retrying operations) +func (client WorkRequestClient) listWorkRequestLogs(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/workRequests/{workRequestId}/logs", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListWorkRequestLogsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} + +// ListWorkRequests Lists the work requests in a compartment or for a specified resource. +// +// See also +// +// Click https://docs.cloud.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/workrequests/ListWorkRequests.go.html to see an example of how to use ListWorkRequests API. +func (client WorkRequestClient) ListWorkRequests(ctx context.Context, request ListWorkRequestsRequest) (response ListWorkRequestsResponse, err error) { + var ociResponse common.OCIResponse + policy := common.NoRetryPolicy() + if client.RetryPolicy() != nil { + policy = *client.RetryPolicy() + } + if request.RetryPolicy() != nil { + policy = *request.RetryPolicy() + } + ociResponse, err = common.Retry(ctx, request, client.listWorkRequests, policy) + if err != nil { + if ociResponse != nil { + if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil { + opcRequestId := httpResponse.Header.Get("opc-request-id") + response = ListWorkRequestsResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId} + } else { + response = ListWorkRequestsResponse{} + } + } + return + } + if convertedResponse, ok := ociResponse.(ListWorkRequestsResponse); ok { + response = convertedResponse + } else { + err = fmt.Errorf("failed to convert OCIResponse into ListWorkRequestsResponse") + } + return +} + +// listWorkRequests implements the OCIOperation interface (enables retrying operations) +func (client WorkRequestClient) listWorkRequests(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) { + + httpRequest, err := request.HTTPRequest(http.MethodGet, "/workRequests", binaryReqBody, extraHeaders) + if err != nil { + return nil, err + } + + var response ListWorkRequestsResponse + var httpResponse *http.Response + httpResponse, err = client.Call(ctx, &httpRequest) + defer common.CloseBodyIfValid(httpResponse) + response.RawResponse = httpResponse + if err != nil { + return response, err + } + + err = common.UnmarshalResponse(httpResponse, &response) + return response, err +} diff --git a/vendor/github.com/sony/gobreaker/.travis.yml b/vendor/github.com/sony/gobreaker/.travis.yml new file mode 100644 index 000000000..1531637b6 --- /dev/null +++ b/vendor/github.com/sony/gobreaker/.travis.yml @@ -0,0 +1,15 @@ +language: go +go: + - 1.13.x + - 1.14.x + - 1.15.x +sudo: false +before_install: + - go get -u golang.org/x/lint/golint + - go get github.com/axw/gocov/gocov + - go get github.com/mattn/goveralls +script: + - test -z "`gofmt -l .`" + - test -z "`golint ./...`" + - $GOPATH/bin/goveralls -service=travis-ci + - cd example && go build -o http_breaker && ./http_breaker diff --git a/vendor/github.com/sony/gobreaker/LICENSE b/vendor/github.com/sony/gobreaker/LICENSE new file mode 100644 index 000000000..81795bf64 --- /dev/null +++ b/vendor/github.com/sony/gobreaker/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright 2015 Sony Corporation + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/github.com/sony/gobreaker/README.md b/vendor/github.com/sony/gobreaker/README.md new file mode 100644 index 000000000..ce7d7a77e --- /dev/null +++ b/vendor/github.com/sony/gobreaker/README.md @@ -0,0 +1,128 @@ +gobreaker +========= + +[![GoDoc](https://godoc.org/github.com/sony/gobreaker?status.svg)](http://godoc.org/github.com/sony/gobreaker) +[![Build Status](https://travis-ci.org/sony/gobreaker.svg?branch=master)](https://travis-ci.org/sony/gobreaker) +[![Coverage Status](https://coveralls.io/repos/sony/gobreaker/badge.svg?branch=master&service=github)](https://coveralls.io/github/sony/gobreaker?branch=master) + +[gobreaker][repo-url] implements the [Circuit Breaker pattern](https://msdn.microsoft.com/en-us/library/dn589784.aspx) in Go. + +Installation +------------ + +``` +go get github.com/sony/gobreaker +``` + +Usage +----- + +The struct `CircuitBreaker` is a state machine to prevent sending requests that are likely to fail. +The function `NewCircuitBreaker` creates a new `CircuitBreaker`. + +```go +func NewCircuitBreaker(st Settings) *CircuitBreaker +``` + +You can configure `CircuitBreaker` by the struct `Settings`: + +```go +type Settings struct { + Name string + MaxRequests uint32 + Interval time.Duration + Timeout time.Duration + ReadyToTrip func(counts Counts) bool + OnStateChange func(name string, from State, to State) +} +``` + +- `Name` is the name of the `CircuitBreaker`. + +- `MaxRequests` is the maximum number of requests allowed to pass through + when the `CircuitBreaker` is half-open. + If `MaxRequests` is 0, `CircuitBreaker` allows only 1 request. + +- `Interval` is the cyclic period of the closed state + for `CircuitBreaker` to clear the internal `Counts`, described later in this section. + If `Interval` is 0, `CircuitBreaker` doesn't clear the internal `Counts` during the closed state. + +- `Timeout` is the period of the open state, + after which the state of `CircuitBreaker` becomes half-open. + If `Timeout` is 0, the timeout value of `CircuitBreaker` is set to 60 seconds. + +- `ReadyToTrip` is called with a copy of `Counts` whenever a request fails in the closed state. + If `ReadyToTrip` returns true, `CircuitBreaker` will be placed into the open state. + If `ReadyToTrip` is `nil`, default `ReadyToTrip` is used. + Default `ReadyToTrip` returns true when the number of consecutive failures is more than 5. + +- `OnStateChange` is called whenever the state of `CircuitBreaker` changes. + +The struct `Counts` holds the numbers of requests and their successes/failures: + +```go +type Counts struct { + Requests uint32 + TotalSuccesses uint32 + TotalFailures uint32 + ConsecutiveSuccesses uint32 + ConsecutiveFailures uint32 +} +``` + +`CircuitBreaker` clears the internal `Counts` either +on the change of the state or at the closed-state intervals. +`Counts` ignores the results of the requests sent before clearing. + +`CircuitBreaker` can wrap any function to send a request: + +```go +func (cb *CircuitBreaker) Execute(req func() (interface{}, error)) (interface{}, error) +``` + +The method `Execute` runs the given request if `CircuitBreaker` accepts it. +`Execute` returns an error instantly if `CircuitBreaker` rejects the request. +Otherwise, `Execute` returns the result of the request. +If a panic occurs in the request, `CircuitBreaker` handles it as an error +and causes the same panic again. + +Example +------- + +```go +var cb *breaker.CircuitBreaker + +func Get(url string) ([]byte, error) { + body, err := cb.Execute(func() (interface{}, error) { + resp, err := http.Get(url) + if err != nil { + return nil, err + } + + defer resp.Body.Close() + body, err := ioutil.ReadAll(resp.Body) + if err != nil { + return nil, err + } + + return body, nil + }) + if err != nil { + return nil, err + } + + return body.([]byte), nil +} +``` + +See [example](https://github.com/sony/gobreaker/blob/master/example) for details. + +License +------- + +The MIT License (MIT) + +See [LICENSE](https://github.com/sony/gobreaker/blob/master/LICENSE) for details. + + +[repo-url]: https://github.com/sony/gobreaker diff --git a/vendor/github.com/sony/gobreaker/go.mod b/vendor/github.com/sony/gobreaker/go.mod new file mode 100644 index 000000000..4367bedbd --- /dev/null +++ b/vendor/github.com/sony/gobreaker/go.mod @@ -0,0 +1,5 @@ +module github.com/sony/gobreaker + +go 1.12 + +require github.com/stretchr/testify v1.3.0 diff --git a/vendor/github.com/sony/gobreaker/go.sum b/vendor/github.com/sony/gobreaker/go.sum new file mode 100644 index 000000000..4347755af --- /dev/null +++ b/vendor/github.com/sony/gobreaker/go.sum @@ -0,0 +1,7 @@ +github.com/davecgh/go-spew v1.1.0 h1:ZDRjVQ15GmhC3fiQ8ni8+OwkZQO4DARzQgrnXU1Liz8= +github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= +github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= +github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= +github.com/stretchr/testify v1.3.0 h1:TivCn/peBQ7UY8ooIcPgZFpTNSz0Q2U6UrFlUfqbe0Q= +github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= diff --git a/vendor/github.com/sony/gobreaker/gobreaker.go b/vendor/github.com/sony/gobreaker/gobreaker.go new file mode 100644 index 000000000..5a464198e --- /dev/null +++ b/vendor/github.com/sony/gobreaker/gobreaker.go @@ -0,0 +1,380 @@ +// Package gobreaker implements the Circuit Breaker pattern. +// See https://msdn.microsoft.com/en-us/library/dn589784.aspx. +package gobreaker + +import ( + "errors" + "fmt" + "sync" + "time" +) + +// State is a type that represents a state of CircuitBreaker. +type State int + +// These constants are states of CircuitBreaker. +const ( + StateClosed State = iota + StateHalfOpen + StateOpen +) + +var ( + // ErrTooManyRequests is returned when the CB state is half open and the requests count is over the cb maxRequests + ErrTooManyRequests = errors.New("too many requests") + // ErrOpenState is returned when the CB state is open + ErrOpenState = errors.New("circuit breaker is open") +) + +// String implements stringer interface. +func (s State) String() string { + switch s { + case StateClosed: + return "closed" + case StateHalfOpen: + return "half-open" + case StateOpen: + return "open" + default: + return fmt.Sprintf("unknown state: %d", s) + } +} + +// Counts holds the numbers of requests and their successes/failures. +// CircuitBreaker clears the internal Counts either +// on the change of the state or at the closed-state intervals. +// Counts ignores the results of the requests sent before clearing. +type Counts struct { + Requests uint32 + TotalSuccesses uint32 + TotalFailures uint32 + ConsecutiveSuccesses uint32 + ConsecutiveFailures uint32 +} + +func (c *Counts) onRequest() { + c.Requests++ +} + +func (c *Counts) onSuccess() { + c.TotalSuccesses++ + c.ConsecutiveSuccesses++ + c.ConsecutiveFailures = 0 +} + +func (c *Counts) onFailure() { + c.TotalFailures++ + c.ConsecutiveFailures++ + c.ConsecutiveSuccesses = 0 +} + +func (c *Counts) clear() { + c.Requests = 0 + c.TotalSuccesses = 0 + c.TotalFailures = 0 + c.ConsecutiveSuccesses = 0 + c.ConsecutiveFailures = 0 +} + +// Settings configures CircuitBreaker: +// +// Name is the name of the CircuitBreaker. +// +// MaxRequests is the maximum number of requests allowed to pass through +// when the CircuitBreaker is half-open. +// If MaxRequests is 0, the CircuitBreaker allows only 1 request. +// +// Interval is the cyclic period of the closed state +// for the CircuitBreaker to clear the internal Counts. +// If Interval is less than or equal to 0, the CircuitBreaker doesn't clear internal Counts during the closed state. +// +// Timeout is the period of the open state, +// after which the state of the CircuitBreaker becomes half-open. +// If Timeout is less than or equal to 0, the timeout value of the CircuitBreaker is set to 60 seconds. +// +// ReadyToTrip is called with a copy of Counts whenever a request fails in the closed state. +// If ReadyToTrip returns true, the CircuitBreaker will be placed into the open state. +// If ReadyToTrip is nil, default ReadyToTrip is used. +// Default ReadyToTrip returns true when the number of consecutive failures is more than 5. +// +// OnStateChange is called whenever the state of the CircuitBreaker changes. +// +// IsSuccessful is called with the error returned from the request, if not nil. +// If IsSuccessful returns false, the error is considered a failure, and is counted towards tripping the circuit breaker. +// If IsSuccessful returns true, the error will be returned to the caller without tripping the circuit breaker. +// If IsSuccessful is nil, default IsSuccessful is used, which returns false for all non-nil errors. +type Settings struct { + Name string + MaxRequests uint32 + Interval time.Duration + Timeout time.Duration + ReadyToTrip func(counts Counts) bool + OnStateChange func(name string, from State, to State) + IsSuccessful func(err error) bool +} + +// CircuitBreaker is a state machine to prevent sending requests that are likely to fail. +type CircuitBreaker struct { + name string + maxRequests uint32 + interval time.Duration + timeout time.Duration + readyToTrip func(counts Counts) bool + isSuccessful func(err error) bool + onStateChange func(name string, from State, to State) + + mutex sync.Mutex + state State + generation uint64 + counts Counts + expiry time.Time +} + +// TwoStepCircuitBreaker is like CircuitBreaker but instead of surrounding a function +// with the breaker functionality, it only checks whether a request can proceed and +// expects the caller to report the outcome in a separate step using a callback. +type TwoStepCircuitBreaker struct { + cb *CircuitBreaker +} + +// NewCircuitBreaker returns a new CircuitBreaker configured with the given Settings. +func NewCircuitBreaker(st Settings) *CircuitBreaker { + cb := new(CircuitBreaker) + + cb.name = st.Name + cb.onStateChange = st.OnStateChange + + if st.MaxRequests == 0 { + cb.maxRequests = 1 + } else { + cb.maxRequests = st.MaxRequests + } + + if st.Interval <= 0 { + cb.interval = defaultInterval + } else { + cb.interval = st.Interval + } + + if st.Timeout <= 0 { + cb.timeout = defaultTimeout + } else { + cb.timeout = st.Timeout + } + + if st.ReadyToTrip == nil { + cb.readyToTrip = defaultReadyToTrip + } else { + cb.readyToTrip = st.ReadyToTrip + } + + if st.IsSuccessful == nil { + cb.isSuccessful = defaultIsSuccessful + } else { + cb.isSuccessful = st.IsSuccessful + } + + cb.toNewGeneration(time.Now()) + + return cb +} + +// NewTwoStepCircuitBreaker returns a new TwoStepCircuitBreaker configured with the given Settings. +func NewTwoStepCircuitBreaker(st Settings) *TwoStepCircuitBreaker { + return &TwoStepCircuitBreaker{ + cb: NewCircuitBreaker(st), + } +} + +const defaultInterval = time.Duration(0) * time.Second +const defaultTimeout = time.Duration(60) * time.Second + +func defaultReadyToTrip(counts Counts) bool { + return counts.ConsecutiveFailures > 5 +} + +func defaultIsSuccessful(err error) bool { + return err == nil +} + +// Name returns the name of the CircuitBreaker. +func (cb *CircuitBreaker) Name() string { + return cb.name +} + +// State returns the current state of the CircuitBreaker. +func (cb *CircuitBreaker) State() State { + cb.mutex.Lock() + defer cb.mutex.Unlock() + + now := time.Now() + state, _ := cb.currentState(now) + return state +} + +// Counts returns internal counters +func (cb *CircuitBreaker) Counts() Counts { + cb.mutex.Lock() + defer cb.mutex.Unlock() + + return cb.counts +} + +// Execute runs the given request if the CircuitBreaker accepts it. +// Execute returns an error instantly if the CircuitBreaker rejects the request. +// Otherwise, Execute returns the result of the request. +// If a panic occurs in the request, the CircuitBreaker handles it as an error +// and causes the same panic again. +func (cb *CircuitBreaker) Execute(req func() (interface{}, error)) (interface{}, error) { + generation, err := cb.beforeRequest() + if err != nil { + return nil, err + } + + defer func() { + e := recover() + if e != nil { + cb.afterRequest(generation, false) + panic(e) + } + }() + + result, err := req() + cb.afterRequest(generation, cb.isSuccessful(err)) + return result, err +} + +// Name returns the name of the TwoStepCircuitBreaker. +func (tscb *TwoStepCircuitBreaker) Name() string { + return tscb.cb.Name() +} + +// State returns the current state of the TwoStepCircuitBreaker. +func (tscb *TwoStepCircuitBreaker) State() State { + return tscb.cb.State() +} + +// Counts returns internal counters +func (tscb *TwoStepCircuitBreaker) Counts() Counts { + return tscb.cb.Counts() +} + +// Allow checks if a new request can proceed. It returns a callback that should be used to +// register the success or failure in a separate step. If the circuit breaker doesn't allow +// requests, it returns an error. +func (tscb *TwoStepCircuitBreaker) Allow() (done func(success bool), err error) { + generation, err := tscb.cb.beforeRequest() + if err != nil { + return nil, err + } + + return func(success bool) { + tscb.cb.afterRequest(generation, success) + }, nil +} + +func (cb *CircuitBreaker) beforeRequest() (uint64, error) { + cb.mutex.Lock() + defer cb.mutex.Unlock() + + now := time.Now() + state, generation := cb.currentState(now) + + if state == StateOpen { + return generation, ErrOpenState + } else if state == StateHalfOpen && cb.counts.Requests >= cb.maxRequests { + return generation, ErrTooManyRequests + } + + cb.counts.onRequest() + return generation, nil +} + +func (cb *CircuitBreaker) afterRequest(before uint64, success bool) { + cb.mutex.Lock() + defer cb.mutex.Unlock() + + now := time.Now() + state, generation := cb.currentState(now) + if generation != before { + return + } + + if success { + cb.onSuccess(state, now) + } else { + cb.onFailure(state, now) + } +} + +func (cb *CircuitBreaker) onSuccess(state State, now time.Time) { + switch state { + case StateClosed: + cb.counts.onSuccess() + case StateHalfOpen: + cb.counts.onSuccess() + if cb.counts.ConsecutiveSuccesses >= cb.maxRequests { + cb.setState(StateClosed, now) + } + } +} + +func (cb *CircuitBreaker) onFailure(state State, now time.Time) { + switch state { + case StateClosed: + cb.counts.onFailure() + if cb.readyToTrip(cb.counts) { + cb.setState(StateOpen, now) + } + case StateHalfOpen: + cb.setState(StateOpen, now) + } +} + +func (cb *CircuitBreaker) currentState(now time.Time) (State, uint64) { + switch cb.state { + case StateClosed: + if !cb.expiry.IsZero() && cb.expiry.Before(now) { + cb.toNewGeneration(now) + } + case StateOpen: + if cb.expiry.Before(now) { + cb.setState(StateHalfOpen, now) + } + } + return cb.state, cb.generation +} + +func (cb *CircuitBreaker) setState(state State, now time.Time) { + if cb.state == state { + return + } + + prev := cb.state + cb.state = state + + cb.toNewGeneration(now) + + if cb.onStateChange != nil { + cb.onStateChange(cb.name, prev, state) + } +} + +func (cb *CircuitBreaker) toNewGeneration(now time.Time) { + cb.generation++ + cb.counts.clear() + + var zero time.Time + switch cb.state { + case StateClosed: + if cb.interval == 0 { + cb.expiry = zero + } else { + cb.expiry = now.Add(cb.interval) + } + case StateOpen: + cb.expiry = now.Add(cb.timeout) + default: // StateHalfOpen + cb.expiry = zero + } +} diff --git a/vendor/github.com/spf13/cobra/.gitignore b/vendor/github.com/spf13/cobra/.gitignore new file mode 100644 index 000000000..1b8c7c261 --- /dev/null +++ b/vendor/github.com/spf13/cobra/.gitignore @@ -0,0 +1,36 @@ +# Compiled Object files, Static and Dynamic libs (Shared Objects) +*.o +*.a +*.so + +# Folders +_obj +_test + +# Architecture specific extensions/prefixes +*.[568vq] +[568vq].out + +*.cgo1.go +*.cgo2.c +_cgo_defun.c +_cgo_gotypes.go +_cgo_export.* + +_testmain.go + +# Vim files https://github.com/github/gitignore/blob/master/Global/Vim.gitignore +# swap +[._]*.s[a-w][a-z] +[._]s[a-w][a-z] +# session +Session.vim +# temporary +.netrwhist +*~ +# auto-generated tag files +tags + +*.exe + +cobra.test diff --git a/vendor/github.com/spf13/cobra/.mailmap b/vendor/github.com/spf13/cobra/.mailmap new file mode 100644 index 000000000..94ec53068 --- /dev/null +++ b/vendor/github.com/spf13/cobra/.mailmap @@ -0,0 +1,3 @@ +Steve Francia +Bjørn Erik Pedersen +Fabiano Franz diff --git a/vendor/github.com/spf13/cobra/.travis.yml b/vendor/github.com/spf13/cobra/.travis.yml new file mode 100644 index 000000000..5afcb2096 --- /dev/null +++ b/vendor/github.com/spf13/cobra/.travis.yml @@ -0,0 +1,21 @@ +language: go + +matrix: + include: + - go: 1.9.4 + - go: 1.10.0 + - go: tip + allow_failures: + - go: tip + +before_install: + - mkdir -p bin + - curl -Lso bin/shellcheck https://github.com/caarlos0/shellcheck-docker/releases/download/v0.4.3/shellcheck + - chmod +x bin/shellcheck +script: + - PATH=$PATH:$PWD/bin go test -v ./... + - go build + - diff -u <(echo -n) <(gofmt -d -s .) + - if [ -z $NOVET ]; then + diff -u <(echo -n) <(go tool vet . 2>&1 | grep -vE 'ExampleCommand|bash_completions.*Fprint'); + fi diff --git a/vendor/github.com/spf13/cobra/LICENSE.txt b/vendor/github.com/spf13/cobra/LICENSE.txt new file mode 100644 index 000000000..298f0e266 --- /dev/null +++ b/vendor/github.com/spf13/cobra/LICENSE.txt @@ -0,0 +1,174 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. diff --git a/vendor/github.com/spf13/cobra/README.md b/vendor/github.com/spf13/cobra/README.md new file mode 100644 index 000000000..851fcc087 --- /dev/null +++ b/vendor/github.com/spf13/cobra/README.md @@ -0,0 +1,736 @@ +![cobra logo](https://cloud.githubusercontent.com/assets/173412/10886352/ad566232-814f-11e5-9cd0-aa101788c117.png) + +Cobra is both a library for creating powerful modern CLI applications as well as a program to generate applications and command files. + +Many of the most widely used Go projects are built using Cobra including: + +* [Kubernetes](http://kubernetes.io/) +* [Hugo](http://gohugo.io) +* [rkt](https://github.com/coreos/rkt) +* [etcd](https://github.com/coreos/etcd) +* [Moby (former Docker)](https://github.com/moby/moby) +* [Docker (distribution)](https://github.com/docker/distribution) +* [OpenShift](https://www.openshift.com/) +* [Delve](https://github.com/derekparker/delve) +* [GopherJS](http://www.gopherjs.org/) +* [CockroachDB](http://www.cockroachlabs.com/) +* [Bleve](http://www.blevesearch.com/) +* [ProjectAtomic (enterprise)](http://www.projectatomic.io/) +* [GiantSwarm's swarm](https://github.com/giantswarm/cli) +* [Nanobox](https://github.com/nanobox-io/nanobox)/[Nanopack](https://github.com/nanopack) +* [rclone](http://rclone.org/) +* [nehm](https://github.com/bogem/nehm) +* [Pouch](https://github.com/alibaba/pouch) + +[![Build Status](https://travis-ci.org/spf13/cobra.svg "Travis CI status")](https://travis-ci.org/spf13/cobra) +[![CircleCI status](https://circleci.com/gh/spf13/cobra.png?circle-token=:circle-token "CircleCI status")](https://circleci.com/gh/spf13/cobra) +[![GoDoc](https://godoc.org/github.com/spf13/cobra?status.svg)](https://godoc.org/github.com/spf13/cobra) + +# Table of Contents + +- [Overview](#overview) +- [Concepts](#concepts) + * [Commands](#commands) + * [Flags](#flags) +- [Installing](#installing) +- [Getting Started](#getting-started) + * [Using the Cobra Generator](#using-the-cobra-generator) + * [Using the Cobra Library](#using-the-cobra-library) + * [Working with Flags](#working-with-flags) + * [Positional and Custom Arguments](#positional-and-custom-arguments) + * [Example](#example) + * [Help Command](#help-command) + * [Usage Message](#usage-message) + * [PreRun and PostRun Hooks](#prerun-and-postrun-hooks) + * [Suggestions when "unknown command" happens](#suggestions-when-unknown-command-happens) + * [Generating documentation for your command](#generating-documentation-for-your-command) + * [Generating bash completions](#generating-bash-completions) +- [Contributing](#contributing) +- [License](#license) + +# Overview + +Cobra is a library providing a simple interface to create powerful modern CLI +interfaces similar to git & go tools. + +Cobra is also an application that will generate your application scaffolding to rapidly +develop a Cobra-based application. + +Cobra provides: +* Easy subcommand-based CLIs: `app server`, `app fetch`, etc. +* Fully POSIX-compliant flags (including short & long versions) +* Nested subcommands +* Global, local and cascading flags +* Easy generation of applications & commands with `cobra init appname` & `cobra add cmdname` +* Intelligent suggestions (`app srver`... did you mean `app server`?) +* Automatic help generation for commands and flags +* Automatic help flag recognition of `-h`, `--help`, etc. +* Automatically generated bash autocomplete for your application +* Automatically generated man pages for your application +* Command aliases so you can change things without breaking them +* The flexibility to define your own help, usage, etc. +* Optional tight integration with [viper](http://github.com/spf13/viper) for 12-factor apps + +# Concepts + +Cobra is built on a structure of commands, arguments & flags. + +**Commands** represent actions, **Args** are things and **Flags** are modifiers for those actions. + +The best applications will read like sentences when used. Users will know how +to use the application because they will natively understand how to use it. + +The pattern to follow is +`APPNAME VERB NOUN --ADJECTIVE.` + or +`APPNAME COMMAND ARG --FLAG` + +A few good real world examples may better illustrate this point. + +In the following example, 'server' is a command, and 'port' is a flag: + + hugo server --port=1313 + +In this command we are telling Git to clone the url bare. + + git clone URL --bare + +## Commands + +Command is the central point of the application. Each interaction that +the application supports will be contained in a Command. A command can +have children commands and optionally run an action. + +In the example above, 'server' is the command. + +[More about cobra.Command](https://godoc.org/github.com/spf13/cobra#Command) + +## Flags + +A flag is a way to modify the behavior of a command. Cobra supports +fully POSIX-compliant flags as well as the Go [flag package](https://golang.org/pkg/flag/). +A Cobra command can define flags that persist through to children commands +and flags that are only available to that command. + +In the example above, 'port' is the flag. + +Flag functionality is provided by the [pflag +library](https://github.com/spf13/pflag), a fork of the flag standard library +which maintains the same interface while adding POSIX compliance. + +# Installing +Using Cobra is easy. First, use `go get` to install the latest version +of the library. This command will install the `cobra` generator executable +along with the library and its dependencies: + + go get -u github.com/spf13/cobra/cobra + +Next, include Cobra in your application: + +```go +import "github.com/spf13/cobra" +``` + +# Getting Started + +While you are welcome to provide your own organization, typically a Cobra-based +application will follow the following organizational structure: + +``` + ▾ appName/ + ▾ cmd/ + add.go + your.go + commands.go + here.go + main.go +``` + +In a Cobra app, typically the main.go file is very bare. It serves one purpose: initializing Cobra. + +```go +package main + +import ( + "fmt" + "os" + + "{pathToYourApp}/cmd" +) + +func main() { + cmd.Execute() +} +``` + +## Using the Cobra Generator + +Cobra provides its own program that will create your application and add any +commands you want. It's the easiest way to incorporate Cobra into your application. + +[Here](https://github.com/spf13/cobra/blob/master/cobra/README.md) you can find more information about it. + +## Using the Cobra Library + +To manually implement Cobra you need to create a bare main.go file and a rootCmd file. +You will optionally provide additional commands as you see fit. + +### Create rootCmd + +Cobra doesn't require any special constructors. Simply create your commands. + +Ideally you place this in app/cmd/root.go: + +```go +var rootCmd = &cobra.Command{ + Use: "hugo", + Short: "Hugo is a very fast static site generator", + Long: `A Fast and Flexible Static Site Generator built with + love by spf13 and friends in Go. + Complete documentation is available at http://hugo.spf13.com`, + Run: func(cmd *cobra.Command, args []string) { + // Do Stuff Here + }, +} + +func Execute() { + if err := rootCmd.Execute(); err != nil { + fmt.Println(err) + os.Exit(1) + } +} +``` + +You will additionally define flags and handle configuration in your init() function. + +For example cmd/root.go: + +```go +import ( + "fmt" + "os" + + homedir "github.com/mitchellh/go-homedir" + "github.com/spf13/cobra" + "github.com/spf13/viper" +) + +func init() { + cobra.OnInitialize(initConfig) + rootCmd.PersistentFlags().StringVar(&cfgFile, "config", "", "config file (default is $HOME/.cobra.yaml)") + rootCmd.PersistentFlags().StringVarP(&projectBase, "projectbase", "b", "", "base project directory eg. github.com/spf13/") + rootCmd.PersistentFlags().StringP("author", "a", "YOUR NAME", "Author name for copyright attribution") + rootCmd.PersistentFlags().StringVarP(&userLicense, "license", "l", "", "Name of license for the project (can provide `licensetext` in config)") + rootCmd.PersistentFlags().Bool("viper", true, "Use Viper for configuration") + viper.BindPFlag("author", rootCmd.PersistentFlags().Lookup("author")) + viper.BindPFlag("projectbase", rootCmd.PersistentFlags().Lookup("projectbase")) + viper.BindPFlag("useViper", rootCmd.PersistentFlags().Lookup("viper")) + viper.SetDefault("author", "NAME HERE ") + viper.SetDefault("license", "apache") +} + +func initConfig() { + // Don't forget to read config either from cfgFile or from home directory! + if cfgFile != "" { + // Use config file from the flag. + viper.SetConfigFile(cfgFile) + } else { + // Find home directory. + home, err := homedir.Dir() + if err != nil { + fmt.Println(err) + os.Exit(1) + } + + // Search config in home directory with name ".cobra" (without extension). + viper.AddConfigPath(home) + viper.SetConfigName(".cobra") + } + + if err := viper.ReadInConfig(); err != nil { + fmt.Println("Can't read config:", err) + os.Exit(1) + } +} +``` + +### Create your main.go + +With the root command you need to have your main function execute it. +Execute should be run on the root for clarity, though it can be called on any command. + +In a Cobra app, typically the main.go file is very bare. It serves, one purpose, to initialize Cobra. + +```go +package main + +import ( + "fmt" + "os" + + "{pathToYourApp}/cmd" +) + +func main() { + cmd.Execute() +} +``` + +### Create additional commands + +Additional commands can be defined and typically are each given their own file +inside of the cmd/ directory. + +If you wanted to create a version command you would create cmd/version.go and +populate it with the following: + +```go +package cmd + +import ( + "fmt" + + "github.com/spf13/cobra" +) + +func init() { + rootCmd.AddCommand(versionCmd) +} + +var versionCmd = &cobra.Command{ + Use: "version", + Short: "Print the version number of Hugo", + Long: `All software has versions. This is Hugo's`, + Run: func(cmd *cobra.Command, args []string) { + fmt.Println("Hugo Static Site Generator v0.9 -- HEAD") + }, +} +``` + +## Working with Flags + +Flags provide modifiers to control how the action command operates. + +### Assign flags to a command + +Since the flags are defined and used in different locations, we need to +define a variable outside with the correct scope to assign the flag to +work with. + +```go +var Verbose bool +var Source string +``` + +There are two different approaches to assign a flag. + +### Persistent Flags + +A flag can be 'persistent' meaning that this flag will be available to the +command it's assigned to as well as every command under that command. For +global flags, assign a flag as a persistent flag on the root. + +```go +rootCmd.PersistentFlags().BoolVarP(&Verbose, "verbose", "v", false, "verbose output") +``` + +### Local Flags + +A flag can also be assigned locally which will only apply to that specific command. + +```go +rootCmd.Flags().StringVarP(&Source, "source", "s", "", "Source directory to read from") +``` + +### Local Flag on Parent Commands + +By default Cobra only parses local flags on the target command, any local flags on +parent commands are ignored. By enabling `Command.TraverseChildren` Cobra will +parse local flags on each command before executing the target command. + +```go +command := cobra.Command{ + Use: "print [OPTIONS] [COMMANDS]", + TraverseChildren: true, +} +``` + +### Bind Flags with Config + +You can also bind your flags with [viper](https://github.com/spf13/viper): +```go +var author string + +func init() { + rootCmd.PersistentFlags().StringVar(&author, "author", "YOUR NAME", "Author name for copyright attribution") + viper.BindPFlag("author", rootCmd.PersistentFlags().Lookup("author")) +} +``` + +In this example the persistent flag `author` is bound with `viper`. +**Note**, that the variable `author` will not be set to the value from config, +when the `--author` flag is not provided by user. + +More in [viper documentation](https://github.com/spf13/viper#working-with-flags). + +### Required flags + +Flags are optional by default. If instead you wish your command to report an error +when a flag has not been set, mark it as required: +```go +rootCmd.Flags().StringVarP(&Region, "region", "r", "", "AWS region (required)") +rootCmd.MarkFlagRequired("region") +``` + +## Positional and Custom Arguments + +Validation of positional arguments can be specified using the `Args` field +of `Command`. + +The following validators are built in: + +- `NoArgs` - the command will report an error if there are any positional args. +- `ArbitraryArgs` - the command will accept any args. +- `OnlyValidArgs` - the command will report an error if there are any positional args that are not in the `ValidArgs` field of `Command`. +- `MinimumNArgs(int)` - the command will report an error if there are not at least N positional args. +- `MaximumNArgs(int)` - the command will report an error if there are more than N positional args. +- `ExactArgs(int)` - the command will report an error if there are not exactly N positional args. +- `RangeArgs(min, max)` - the command will report an error if the number of args is not between the minimum and maximum number of expected args. + +An example of setting the custom validator: + +```go +var cmd = &cobra.Command{ + Short: "hello", + Args: func(cmd *cobra.Command, args []string) error { + if len(args) < 1 { + return errors.New("requires at least one arg") + } + if myapp.IsValidColor(args[0]) { + return nil + } + return fmt.Errorf("invalid color specified: %s", args[0]) + }, + Run: func(cmd *cobra.Command, args []string) { + fmt.Println("Hello, World!") + }, +} +``` + +## Example + +In the example below, we have defined three commands. Two are at the top level +and one (cmdTimes) is a child of one of the top commands. In this case the root +is not executable meaning that a subcommand is required. This is accomplished +by not providing a 'Run' for the 'rootCmd'. + +We have only defined one flag for a single command. + +More documentation about flags is available at https://github.com/spf13/pflag + +```go +package main + +import ( + "fmt" + "strings" + + "github.com/spf13/cobra" +) + +func main() { + var echoTimes int + + var cmdPrint = &cobra.Command{ + Use: "print [string to print]", + Short: "Print anything to the screen", + Long: `print is for printing anything back to the screen. +For many years people have printed back to the screen.`, + Args: cobra.MinimumNArgs(1), + Run: func(cmd *cobra.Command, args []string) { + fmt.Println("Print: " + strings.Join(args, " ")) + }, + } + + var cmdEcho = &cobra.Command{ + Use: "echo [string to echo]", + Short: "Echo anything to the screen", + Long: `echo is for echoing anything back. +Echo works a lot like print, except it has a child command.`, + Args: cobra.MinimumNArgs(1), + Run: func(cmd *cobra.Command, args []string) { + fmt.Println("Print: " + strings.Join(args, " ")) + }, + } + + var cmdTimes = &cobra.Command{ + Use: "times [# times] [string to echo]", + Short: "Echo anything to the screen more times", + Long: `echo things multiple times back to the user by providing +a count and a string.`, + Args: cobra.MinimumNArgs(1), + Run: func(cmd *cobra.Command, args []string) { + for i := 0; i < echoTimes; i++ { + fmt.Println("Echo: " + strings.Join(args, " ")) + } + }, + } + + cmdTimes.Flags().IntVarP(&echoTimes, "times", "t", 1, "times to echo the input") + + var rootCmd = &cobra.Command{Use: "app"} + rootCmd.AddCommand(cmdPrint, cmdEcho) + cmdEcho.AddCommand(cmdTimes) + rootCmd.Execute() +} +``` + +For a more complete example of a larger application, please checkout [Hugo](http://gohugo.io/). + +## Help Command + +Cobra automatically adds a help command to your application when you have subcommands. +This will be called when a user runs 'app help'. Additionally, help will also +support all other commands as input. Say, for instance, you have a command called +'create' without any additional configuration; Cobra will work when 'app help +create' is called. Every command will automatically have the '--help' flag added. + +### Example + +The following output is automatically generated by Cobra. Nothing beyond the +command and flag definitions are needed. + + $ cobra help + + Cobra is a CLI library for Go that empowers applications. + This application is a tool to generate the needed files + to quickly create a Cobra application. + + Usage: + cobra [command] + + Available Commands: + add Add a command to a Cobra Application + help Help about any command + init Initialize a Cobra Application + + Flags: + -a, --author string author name for copyright attribution (default "YOUR NAME") + --config string config file (default is $HOME/.cobra.yaml) + -h, --help help for cobra + -l, --license string name of license for the project + --viper use Viper for configuration (default true) + + Use "cobra [command] --help" for more information about a command. + + +Help is just a command like any other. There is no special logic or behavior +around it. In fact, you can provide your own if you want. + +### Defining your own help + +You can provide your own Help command or your own template for the default command to use +with following functions: + +```go +cmd.SetHelpCommand(cmd *Command) +cmd.SetHelpFunc(f func(*Command, []string)) +cmd.SetHelpTemplate(s string) +``` + +The latter two will also apply to any children commands. + +## Usage Message + +When the user provides an invalid flag or invalid command, Cobra responds by +showing the user the 'usage'. + +### Example +You may recognize this from the help above. That's because the default help +embeds the usage as part of its output. + + $ cobra --invalid + Error: unknown flag: --invalid + Usage: + cobra [command] + + Available Commands: + add Add a command to a Cobra Application + help Help about any command + init Initialize a Cobra Application + + Flags: + -a, --author string author name for copyright attribution (default "YOUR NAME") + --config string config file (default is $HOME/.cobra.yaml) + -h, --help help for cobra + -l, --license string name of license for the project + --viper use Viper for configuration (default true) + + Use "cobra [command] --help" for more information about a command. + +### Defining your own usage +You can provide your own usage function or template for Cobra to use. +Like help, the function and template are overridable through public methods: + +```go +cmd.SetUsageFunc(f func(*Command) error) +cmd.SetUsageTemplate(s string) +``` + +## Version Flag + +Cobra adds a top-level '--version' flag if the Version field is set on the root command. +Running an application with the '--version' flag will print the version to stdout using +the version template. The template can be customized using the +`cmd.SetVersionTemplate(s string)` function. + +## PreRun and PostRun Hooks + +It is possible to run functions before or after the main `Run` function of your command. The `PersistentPreRun` and `PreRun` functions will be executed before `Run`. `PersistentPostRun` and `PostRun` will be executed after `Run`. The `Persistent*Run` functions will be inherited by children if they do not declare their own. These functions are run in the following order: + +- `PersistentPreRun` +- `PreRun` +- `Run` +- `PostRun` +- `PersistentPostRun` + +An example of two commands which use all of these features is below. When the subcommand is executed, it will run the root command's `PersistentPreRun` but not the root command's `PersistentPostRun`: + +```go +package main + +import ( + "fmt" + + "github.com/spf13/cobra" +) + +func main() { + + var rootCmd = &cobra.Command{ + Use: "root [sub]", + Short: "My root command", + PersistentPreRun: func(cmd *cobra.Command, args []string) { + fmt.Printf("Inside rootCmd PersistentPreRun with args: %v\n", args) + }, + PreRun: func(cmd *cobra.Command, args []string) { + fmt.Printf("Inside rootCmd PreRun with args: %v\n", args) + }, + Run: func(cmd *cobra.Command, args []string) { + fmt.Printf("Inside rootCmd Run with args: %v\n", args) + }, + PostRun: func(cmd *cobra.Command, args []string) { + fmt.Printf("Inside rootCmd PostRun with args: %v\n", args) + }, + PersistentPostRun: func(cmd *cobra.Command, args []string) { + fmt.Printf("Inside rootCmd PersistentPostRun with args: %v\n", args) + }, + } + + var subCmd = &cobra.Command{ + Use: "sub [no options!]", + Short: "My subcommand", + PreRun: func(cmd *cobra.Command, args []string) { + fmt.Printf("Inside subCmd PreRun with args: %v\n", args) + }, + Run: func(cmd *cobra.Command, args []string) { + fmt.Printf("Inside subCmd Run with args: %v\n", args) + }, + PostRun: func(cmd *cobra.Command, args []string) { + fmt.Printf("Inside subCmd PostRun with args: %v\n", args) + }, + PersistentPostRun: func(cmd *cobra.Command, args []string) { + fmt.Printf("Inside subCmd PersistentPostRun with args: %v\n", args) + }, + } + + rootCmd.AddCommand(subCmd) + + rootCmd.SetArgs([]string{""}) + rootCmd.Execute() + fmt.Println() + rootCmd.SetArgs([]string{"sub", "arg1", "arg2"}) + rootCmd.Execute() +} +``` + +Output: +``` +Inside rootCmd PersistentPreRun with args: [] +Inside rootCmd PreRun with args: [] +Inside rootCmd Run with args: [] +Inside rootCmd PostRun with args: [] +Inside rootCmd PersistentPostRun with args: [] + +Inside rootCmd PersistentPreRun with args: [arg1 arg2] +Inside subCmd PreRun with args: [arg1 arg2] +Inside subCmd Run with args: [arg1 arg2] +Inside subCmd PostRun with args: [arg1 arg2] +Inside subCmd PersistentPostRun with args: [arg1 arg2] +``` + +## Suggestions when "unknown command" happens + +Cobra will print automatic suggestions when "unknown command" errors happen. This allows Cobra to behave similarly to the `git` command when a typo happens. For example: + +``` +$ hugo srever +Error: unknown command "srever" for "hugo" + +Did you mean this? + server + +Run 'hugo --help' for usage. +``` + +Suggestions are automatic based on every subcommand registered and use an implementation of [Levenshtein distance](http://en.wikipedia.org/wiki/Levenshtein_distance). Every registered command that matches a minimum distance of 2 (ignoring case) will be displayed as a suggestion. + +If you need to disable suggestions or tweak the string distance in your command, use: + +```go +command.DisableSuggestions = true +``` + +or + +```go +command.SuggestionsMinimumDistance = 1 +``` + +You can also explicitly set names for which a given command will be suggested using the `SuggestFor` attribute. This allows suggestions for strings that are not close in terms of string distance, but makes sense in your set of commands and for some which you don't want aliases. Example: + +``` +$ kubectl remove +Error: unknown command "remove" for "kubectl" + +Did you mean this? + delete + +Run 'kubectl help' for usage. +``` + +## Generating documentation for your command + +Cobra can generate documentation based on subcommands, flags, etc. in the following formats: + +- [Markdown](doc/md_docs.md) +- [ReStructured Text](doc/rest_docs.md) +- [Man Page](doc/man_docs.md) + +## Generating bash completions + +Cobra can generate a bash-completion file. If you add more information to your command, these completions can be amazingly powerful and flexible. Read more about it in [Bash Completions](bash_completions.md). + +# Contributing + +1. Fork it +2. Download your fork to your PC (`git clone https://github.com/your_username/cobra && cd cobra`) +3. Create your feature branch (`git checkout -b my-new-feature`) +4. Make changes and add them (`git add .`) +5. Commit your changes (`git commit -m 'Add some feature'`) +6. Push to the branch (`git push origin my-new-feature`) +7. Create new pull request + +# License + +Cobra is released under the Apache 2.0 license. See [LICENSE.txt](https://github.com/spf13/cobra/blob/master/LICENSE.txt) diff --git a/vendor/github.com/spf13/cobra/args.go b/vendor/github.com/spf13/cobra/args.go new file mode 100644 index 000000000..a5d8a9273 --- /dev/null +++ b/vendor/github.com/spf13/cobra/args.go @@ -0,0 +1,89 @@ +package cobra + +import ( + "fmt" +) + +type PositionalArgs func(cmd *Command, args []string) error + +// Legacy arg validation has the following behaviour: +// - root commands with no subcommands can take arbitrary arguments +// - root commands with subcommands will do subcommand validity checking +// - subcommands will always accept arbitrary arguments +func legacyArgs(cmd *Command, args []string) error { + // no subcommand, always take args + if !cmd.HasSubCommands() { + return nil + } + + // root command with subcommands, do subcommand checking. + if !cmd.HasParent() && len(args) > 0 { + return fmt.Errorf("unknown command %q for %q%s", args[0], cmd.CommandPath(), cmd.findSuggestions(args[0])) + } + return nil +} + +// NoArgs returns an error if any args are included. +func NoArgs(cmd *Command, args []string) error { + if len(args) > 0 { + return fmt.Errorf("unknown command %q for %q", args[0], cmd.CommandPath()) + } + return nil +} + +// OnlyValidArgs returns an error if any args are not in the list of ValidArgs. +func OnlyValidArgs(cmd *Command, args []string) error { + if len(cmd.ValidArgs) > 0 { + for _, v := range args { + if !stringInSlice(v, cmd.ValidArgs) { + return fmt.Errorf("invalid argument %q for %q%s", v, cmd.CommandPath(), cmd.findSuggestions(args[0])) + } + } + } + return nil +} + +// ArbitraryArgs never returns an error. +func ArbitraryArgs(cmd *Command, args []string) error { + return nil +} + +// MinimumNArgs returns an error if there is not at least N args. +func MinimumNArgs(n int) PositionalArgs { + return func(cmd *Command, args []string) error { + if len(args) < n { + return fmt.Errorf("requires at least %d arg(s), only received %d", n, len(args)) + } + return nil + } +} + +// MaximumNArgs returns an error if there are more than N args. +func MaximumNArgs(n int) PositionalArgs { + return func(cmd *Command, args []string) error { + if len(args) > n { + return fmt.Errorf("accepts at most %d arg(s), received %d", n, len(args)) + } + return nil + } +} + +// ExactArgs returns an error if there are not exactly n args. +func ExactArgs(n int) PositionalArgs { + return func(cmd *Command, args []string) error { + if len(args) != n { + return fmt.Errorf("accepts %d arg(s), received %d", n, len(args)) + } + return nil + } +} + +// RangeArgs returns an error if the number of args is not within the expected range. +func RangeArgs(min int, max int) PositionalArgs { + return func(cmd *Command, args []string) error { + if len(args) < min || len(args) > max { + return fmt.Errorf("accepts between %d and %d arg(s), received %d", min, max, len(args)) + } + return nil + } +} diff --git a/vendor/github.com/spf13/cobra/bash_completions.go b/vendor/github.com/spf13/cobra/bash_completions.go new file mode 100644 index 000000000..8fa8f486f --- /dev/null +++ b/vendor/github.com/spf13/cobra/bash_completions.go @@ -0,0 +1,584 @@ +package cobra + +import ( + "bytes" + "fmt" + "io" + "os" + "sort" + "strings" + + "github.com/spf13/pflag" +) + +// Annotations for Bash completion. +const ( + BashCompFilenameExt = "cobra_annotation_bash_completion_filename_extensions" + BashCompCustom = "cobra_annotation_bash_completion_custom" + BashCompOneRequiredFlag = "cobra_annotation_bash_completion_one_required_flag" + BashCompSubdirsInDir = "cobra_annotation_bash_completion_subdirs_in_dir" +) + +func writePreamble(buf *bytes.Buffer, name string) { + buf.WriteString(fmt.Sprintf("# bash completion for %-36s -*- shell-script -*-\n", name)) + buf.WriteString(fmt.Sprintf(` +__%[1]s_debug() +{ + if [[ -n ${BASH_COMP_DEBUG_FILE} ]]; then + echo "$*" >> "${BASH_COMP_DEBUG_FILE}" + fi +} + +# Homebrew on Macs have version 1.3 of bash-completion which doesn't include +# _init_completion. This is a very minimal version of that function. +__%[1]s_init_completion() +{ + COMPREPLY=() + _get_comp_words_by_ref "$@" cur prev words cword +} + +__%[1]s_index_of_word() +{ + local w word=$1 + shift + index=0 + for w in "$@"; do + [[ $w = "$word" ]] && return + index=$((index+1)) + done + index=-1 +} + +__%[1]s_contains_word() +{ + local w word=$1; shift + for w in "$@"; do + [[ $w = "$word" ]] && return + done + return 1 +} + +__%[1]s_handle_reply() +{ + __%[1]s_debug "${FUNCNAME[0]}" + case $cur in + -*) + if [[ $(type -t compopt) = "builtin" ]]; then + compopt -o nospace + fi + local allflags + if [ ${#must_have_one_flag[@]} -ne 0 ]; then + allflags=("${must_have_one_flag[@]}") + else + allflags=("${flags[*]} ${two_word_flags[*]}") + fi + COMPREPLY=( $(compgen -W "${allflags[*]}" -- "$cur") ) + if [[ $(type -t compopt) = "builtin" ]]; then + [[ "${COMPREPLY[0]}" == *= ]] || compopt +o nospace + fi + + # complete after --flag=abc + if [[ $cur == *=* ]]; then + if [[ $(type -t compopt) = "builtin" ]]; then + compopt +o nospace + fi + + local index flag + flag="${cur%%=*}" + __%[1]s_index_of_word "${flag}" "${flags_with_completion[@]}" + COMPREPLY=() + if [[ ${index} -ge 0 ]]; then + PREFIX="" + cur="${cur#*=}" + ${flags_completion[${index}]} + if [ -n "${ZSH_VERSION}" ]; then + # zsh completion needs --flag= prefix + eval "COMPREPLY=( \"\${COMPREPLY[@]/#/${flag}=}\" )" + fi + fi + fi + return 0; + ;; + esac + + # check if we are handling a flag with special work handling + local index + __%[1]s_index_of_word "${prev}" "${flags_with_completion[@]}" + if [[ ${index} -ge 0 ]]; then + ${flags_completion[${index}]} + return + fi + + # we are parsing a flag and don't have a special handler, no completion + if [[ ${cur} != "${words[cword]}" ]]; then + return + fi + + local completions + completions=("${commands[@]}") + if [[ ${#must_have_one_noun[@]} -ne 0 ]]; then + completions=("${must_have_one_noun[@]}") + fi + if [[ ${#must_have_one_flag[@]} -ne 0 ]]; then + completions+=("${must_have_one_flag[@]}") + fi + COMPREPLY=( $(compgen -W "${completions[*]}" -- "$cur") ) + + if [[ ${#COMPREPLY[@]} -eq 0 && ${#noun_aliases[@]} -gt 0 && ${#must_have_one_noun[@]} -ne 0 ]]; then + COMPREPLY=( $(compgen -W "${noun_aliases[*]}" -- "$cur") ) + fi + + if [[ ${#COMPREPLY[@]} -eq 0 ]]; then + declare -F __custom_func >/dev/null && __custom_func + fi + + # available in bash-completion >= 2, not always present on macOS + if declare -F __ltrim_colon_completions >/dev/null; then + __ltrim_colon_completions "$cur" + fi + + # If there is only 1 completion and it is a flag with an = it will be completed + # but we don't want a space after the = + if [[ "${#COMPREPLY[@]}" -eq "1" ]] && [[ $(type -t compopt) = "builtin" ]] && [[ "${COMPREPLY[0]}" == --*= ]]; then + compopt -o nospace + fi +} + +# The arguments should be in the form "ext1|ext2|extn" +__%[1]s_handle_filename_extension_flag() +{ + local ext="$1" + _filedir "@(${ext})" +} + +__%[1]s_handle_subdirs_in_dir_flag() +{ + local dir="$1" + pushd "${dir}" >/dev/null 2>&1 && _filedir -d && popd >/dev/null 2>&1 +} + +__%[1]s_handle_flag() +{ + __%[1]s_debug "${FUNCNAME[0]}: c is $c words[c] is ${words[c]}" + + # if a command required a flag, and we found it, unset must_have_one_flag() + local flagname=${words[c]} + local flagvalue + # if the word contained an = + if [[ ${words[c]} == *"="* ]]; then + flagvalue=${flagname#*=} # take in as flagvalue after the = + flagname=${flagname%%=*} # strip everything after the = + flagname="${flagname}=" # but put the = back + fi + __%[1]s_debug "${FUNCNAME[0]}: looking for ${flagname}" + if __%[1]s_contains_word "${flagname}" "${must_have_one_flag[@]}"; then + must_have_one_flag=() + fi + + # if you set a flag which only applies to this command, don't show subcommands + if __%[1]s_contains_word "${flagname}" "${local_nonpersistent_flags[@]}"; then + commands=() + fi + + # keep flag value with flagname as flaghash + # flaghash variable is an associative array which is only supported in bash > 3. + if [[ -z "${BASH_VERSION}" || "${BASH_VERSINFO[0]}" -gt 3 ]]; then + if [ -n "${flagvalue}" ] ; then + flaghash[${flagname}]=${flagvalue} + elif [ -n "${words[ $((c+1)) ]}" ] ; then + flaghash[${flagname}]=${words[ $((c+1)) ]} + else + flaghash[${flagname}]="true" # pad "true" for bool flag + fi + fi + + # skip the argument to a two word flag + if __%[1]s_contains_word "${words[c]}" "${two_word_flags[@]}"; then + c=$((c+1)) + # if we are looking for a flags value, don't show commands + if [[ $c -eq $cword ]]; then + commands=() + fi + fi + + c=$((c+1)) + +} + +__%[1]s_handle_noun() +{ + __%[1]s_debug "${FUNCNAME[0]}: c is $c words[c] is ${words[c]}" + + if __%[1]s_contains_word "${words[c]}" "${must_have_one_noun[@]}"; then + must_have_one_noun=() + elif __%[1]s_contains_word "${words[c]}" "${noun_aliases[@]}"; then + must_have_one_noun=() + fi + + nouns+=("${words[c]}") + c=$((c+1)) +} + +__%[1]s_handle_command() +{ + __%[1]s_debug "${FUNCNAME[0]}: c is $c words[c] is ${words[c]}" + + local next_command + if [[ -n ${last_command} ]]; then + next_command="_${last_command}_${words[c]//:/__}" + else + if [[ $c -eq 0 ]]; then + next_command="_%[1]s_root_command" + else + next_command="_${words[c]//:/__}" + fi + fi + c=$((c+1)) + __%[1]s_debug "${FUNCNAME[0]}: looking for ${next_command}" + declare -F "$next_command" >/dev/null && $next_command +} + +__%[1]s_handle_word() +{ + if [[ $c -ge $cword ]]; then + __%[1]s_handle_reply + return + fi + __%[1]s_debug "${FUNCNAME[0]}: c is $c words[c] is ${words[c]}" + if [[ "${words[c]}" == -* ]]; then + __%[1]s_handle_flag + elif __%[1]s_contains_word "${words[c]}" "${commands[@]}"; then + __%[1]s_handle_command + elif [[ $c -eq 0 ]]; then + __%[1]s_handle_command + elif __%[1]s_contains_word "${words[c]}" "${command_aliases[@]}"; then + # aliashash variable is an associative array which is only supported in bash > 3. + if [[ -z "${BASH_VERSION}" || "${BASH_VERSINFO[0]}" -gt 3 ]]; then + words[c]=${aliashash[${words[c]}]} + __%[1]s_handle_command + else + __%[1]s_handle_noun + fi + else + __%[1]s_handle_noun + fi + __%[1]s_handle_word +} + +`, name)) +} + +func writePostscript(buf *bytes.Buffer, name string) { + name = strings.Replace(name, ":", "__", -1) + buf.WriteString(fmt.Sprintf("__start_%s()\n", name)) + buf.WriteString(fmt.Sprintf(`{ + local cur prev words cword + declare -A flaghash 2>/dev/null || : + declare -A aliashash 2>/dev/null || : + if declare -F _init_completion >/dev/null 2>&1; then + _init_completion -s || return + else + __%[1]s_init_completion -n "=" || return + fi + + local c=0 + local flags=() + local two_word_flags=() + local local_nonpersistent_flags=() + local flags_with_completion=() + local flags_completion=() + local commands=("%[1]s") + local must_have_one_flag=() + local must_have_one_noun=() + local last_command + local nouns=() + + __%[1]s_handle_word +} + +`, name)) + buf.WriteString(fmt.Sprintf(`if [[ $(type -t compopt) = "builtin" ]]; then + complete -o default -F __start_%s %s +else + complete -o default -o nospace -F __start_%s %s +fi + +`, name, name, name, name)) + buf.WriteString("# ex: ts=4 sw=4 et filetype=sh\n") +} + +func writeCommands(buf *bytes.Buffer, cmd *Command) { + buf.WriteString(" commands=()\n") + for _, c := range cmd.Commands() { + if !c.IsAvailableCommand() || c == cmd.helpCommand { + continue + } + buf.WriteString(fmt.Sprintf(" commands+=(%q)\n", c.Name())) + writeCmdAliases(buf, c) + } + buf.WriteString("\n") +} + +func writeFlagHandler(buf *bytes.Buffer, name string, annotations map[string][]string, cmd *Command) { + for key, value := range annotations { + switch key { + case BashCompFilenameExt: + buf.WriteString(fmt.Sprintf(" flags_with_completion+=(%q)\n", name)) + + var ext string + if len(value) > 0 { + ext = fmt.Sprintf("__%s_handle_filename_extension_flag ", cmd.Root().Name()) + strings.Join(value, "|") + } else { + ext = "_filedir" + } + buf.WriteString(fmt.Sprintf(" flags_completion+=(%q)\n", ext)) + case BashCompCustom: + buf.WriteString(fmt.Sprintf(" flags_with_completion+=(%q)\n", name)) + if len(value) > 0 { + handlers := strings.Join(value, "; ") + buf.WriteString(fmt.Sprintf(" flags_completion+=(%q)\n", handlers)) + } else { + buf.WriteString(" flags_completion+=(:)\n") + } + case BashCompSubdirsInDir: + buf.WriteString(fmt.Sprintf(" flags_with_completion+=(%q)\n", name)) + + var ext string + if len(value) == 1 { + ext = fmt.Sprintf("__%s_handle_subdirs_in_dir_flag ", cmd.Root().Name()) + value[0] + } else { + ext = "_filedir -d" + } + buf.WriteString(fmt.Sprintf(" flags_completion+=(%q)\n", ext)) + } + } +} + +func writeShortFlag(buf *bytes.Buffer, flag *pflag.Flag, cmd *Command) { + name := flag.Shorthand + format := " " + if len(flag.NoOptDefVal) == 0 { + format += "two_word_" + } + format += "flags+=(\"-%s\")\n" + buf.WriteString(fmt.Sprintf(format, name)) + writeFlagHandler(buf, "-"+name, flag.Annotations, cmd) +} + +func writeFlag(buf *bytes.Buffer, flag *pflag.Flag, cmd *Command) { + name := flag.Name + format := " flags+=(\"--%s" + if len(flag.NoOptDefVal) == 0 { + format += "=" + } + format += "\")\n" + buf.WriteString(fmt.Sprintf(format, name)) + writeFlagHandler(buf, "--"+name, flag.Annotations, cmd) +} + +func writeLocalNonPersistentFlag(buf *bytes.Buffer, flag *pflag.Flag) { + name := flag.Name + format := " local_nonpersistent_flags+=(\"--%s" + if len(flag.NoOptDefVal) == 0 { + format += "=" + } + format += "\")\n" + buf.WriteString(fmt.Sprintf(format, name)) +} + +func writeFlags(buf *bytes.Buffer, cmd *Command) { + buf.WriteString(` flags=() + two_word_flags=() + local_nonpersistent_flags=() + flags_with_completion=() + flags_completion=() + +`) + localNonPersistentFlags := cmd.LocalNonPersistentFlags() + cmd.NonInheritedFlags().VisitAll(func(flag *pflag.Flag) { + if nonCompletableFlag(flag) { + return + } + writeFlag(buf, flag, cmd) + if len(flag.Shorthand) > 0 { + writeShortFlag(buf, flag, cmd) + } + if localNonPersistentFlags.Lookup(flag.Name) != nil { + writeLocalNonPersistentFlag(buf, flag) + } + }) + cmd.InheritedFlags().VisitAll(func(flag *pflag.Flag) { + if nonCompletableFlag(flag) { + return + } + writeFlag(buf, flag, cmd) + if len(flag.Shorthand) > 0 { + writeShortFlag(buf, flag, cmd) + } + }) + + buf.WriteString("\n") +} + +func writeRequiredFlag(buf *bytes.Buffer, cmd *Command) { + buf.WriteString(" must_have_one_flag=()\n") + flags := cmd.NonInheritedFlags() + flags.VisitAll(func(flag *pflag.Flag) { + if nonCompletableFlag(flag) { + return + } + for key := range flag.Annotations { + switch key { + case BashCompOneRequiredFlag: + format := " must_have_one_flag+=(\"--%s" + if flag.Value.Type() != "bool" { + format += "=" + } + format += "\")\n" + buf.WriteString(fmt.Sprintf(format, flag.Name)) + + if len(flag.Shorthand) > 0 { + buf.WriteString(fmt.Sprintf(" must_have_one_flag+=(\"-%s\")\n", flag.Shorthand)) + } + } + } + }) +} + +func writeRequiredNouns(buf *bytes.Buffer, cmd *Command) { + buf.WriteString(" must_have_one_noun=()\n") + sort.Sort(sort.StringSlice(cmd.ValidArgs)) + for _, value := range cmd.ValidArgs { + buf.WriteString(fmt.Sprintf(" must_have_one_noun+=(%q)\n", value)) + } +} + +func writeCmdAliases(buf *bytes.Buffer, cmd *Command) { + if len(cmd.Aliases) == 0 { + return + } + + sort.Sort(sort.StringSlice(cmd.Aliases)) + + buf.WriteString(fmt.Sprint(` if [[ -z "${BASH_VERSION}" || "${BASH_VERSINFO[0]}" -gt 3 ]]; then`, "\n")) + for _, value := range cmd.Aliases { + buf.WriteString(fmt.Sprintf(" command_aliases+=(%q)\n", value)) + buf.WriteString(fmt.Sprintf(" aliashash[%q]=%q\n", value, cmd.Name())) + } + buf.WriteString(` fi`) + buf.WriteString("\n") +} +func writeArgAliases(buf *bytes.Buffer, cmd *Command) { + buf.WriteString(" noun_aliases=()\n") + sort.Sort(sort.StringSlice(cmd.ArgAliases)) + for _, value := range cmd.ArgAliases { + buf.WriteString(fmt.Sprintf(" noun_aliases+=(%q)\n", value)) + } +} + +func gen(buf *bytes.Buffer, cmd *Command) { + for _, c := range cmd.Commands() { + if !c.IsAvailableCommand() || c == cmd.helpCommand { + continue + } + gen(buf, c) + } + commandName := cmd.CommandPath() + commandName = strings.Replace(commandName, " ", "_", -1) + commandName = strings.Replace(commandName, ":", "__", -1) + + if cmd.Root() == cmd { + buf.WriteString(fmt.Sprintf("_%s_root_command()\n{\n", commandName)) + } else { + buf.WriteString(fmt.Sprintf("_%s()\n{\n", commandName)) + } + + buf.WriteString(fmt.Sprintf(" last_command=%q\n", commandName)) + buf.WriteString("\n") + buf.WriteString(" command_aliases=()\n") + buf.WriteString("\n") + + writeCommands(buf, cmd) + writeFlags(buf, cmd) + writeRequiredFlag(buf, cmd) + writeRequiredNouns(buf, cmd) + writeArgAliases(buf, cmd) + buf.WriteString("}\n\n") +} + +// GenBashCompletion generates bash completion file and writes to the passed writer. +func (c *Command) GenBashCompletion(w io.Writer) error { + buf := new(bytes.Buffer) + writePreamble(buf, c.Name()) + if len(c.BashCompletionFunction) > 0 { + buf.WriteString(c.BashCompletionFunction + "\n") + } + gen(buf, c) + writePostscript(buf, c.Name()) + + _, err := buf.WriteTo(w) + return err +} + +func nonCompletableFlag(flag *pflag.Flag) bool { + return flag.Hidden || len(flag.Deprecated) > 0 +} + +// GenBashCompletionFile generates bash completion file. +func (c *Command) GenBashCompletionFile(filename string) error { + outFile, err := os.Create(filename) + if err != nil { + return err + } + defer outFile.Close() + + return c.GenBashCompletion(outFile) +} + +// MarkFlagRequired adds the BashCompOneRequiredFlag annotation to the named flag if it exists, +// and causes your command to report an error if invoked without the flag. +func (c *Command) MarkFlagRequired(name string) error { + return MarkFlagRequired(c.Flags(), name) +} + +// MarkPersistentFlagRequired adds the BashCompOneRequiredFlag annotation to the named persistent flag if it exists, +// and causes your command to report an error if invoked without the flag. +func (c *Command) MarkPersistentFlagRequired(name string) error { + return MarkFlagRequired(c.PersistentFlags(), name) +} + +// MarkFlagRequired adds the BashCompOneRequiredFlag annotation to the named flag if it exists, +// and causes your command to report an error if invoked without the flag. +func MarkFlagRequired(flags *pflag.FlagSet, name string) error { + return flags.SetAnnotation(name, BashCompOneRequiredFlag, []string{"true"}) +} + +// MarkFlagFilename adds the BashCompFilenameExt annotation to the named flag, if it exists. +// Generated bash autocompletion will select filenames for the flag, limiting to named extensions if provided. +func (c *Command) MarkFlagFilename(name string, extensions ...string) error { + return MarkFlagFilename(c.Flags(), name, extensions...) +} + +// MarkFlagCustom adds the BashCompCustom annotation to the named flag, if it exists. +// Generated bash autocompletion will call the bash function f for the flag. +func (c *Command) MarkFlagCustom(name string, f string) error { + return MarkFlagCustom(c.Flags(), name, f) +} + +// MarkPersistentFlagFilename adds the BashCompFilenameExt annotation to the named persistent flag, if it exists. +// Generated bash autocompletion will select filenames for the flag, limiting to named extensions if provided. +func (c *Command) MarkPersistentFlagFilename(name string, extensions ...string) error { + return MarkFlagFilename(c.PersistentFlags(), name, extensions...) +} + +// MarkFlagFilename adds the BashCompFilenameExt annotation to the named flag in the flag set, if it exists. +// Generated bash autocompletion will select filenames for the flag, limiting to named extensions if provided. +func MarkFlagFilename(flags *pflag.FlagSet, name string, extensions ...string) error { + return flags.SetAnnotation(name, BashCompFilenameExt, extensions) +} + +// MarkFlagCustom adds the BashCompCustom annotation to the named flag in the flag set, if it exists. +// Generated bash autocompletion will call the bash function f for the flag. +func MarkFlagCustom(flags *pflag.FlagSet, name string, f string) error { + return flags.SetAnnotation(name, BashCompCustom, []string{f}) +} diff --git a/vendor/github.com/spf13/cobra/bash_completions.md b/vendor/github.com/spf13/cobra/bash_completions.md new file mode 100644 index 000000000..e79d4769d --- /dev/null +++ b/vendor/github.com/spf13/cobra/bash_completions.md @@ -0,0 +1,221 @@ +# Generating Bash Completions For Your Own cobra.Command + +Generating bash completions from a cobra command is incredibly easy. An actual program which does so for the kubernetes kubectl binary is as follows: + +```go +package main + +import ( + "io/ioutil" + "os" + + "k8s.io/kubernetes/pkg/kubectl/cmd" + "k8s.io/kubernetes/pkg/kubectl/cmd/util" +) + +func main() { + kubectl := cmd.NewKubectlCommand(util.NewFactory(nil), os.Stdin, ioutil.Discard, ioutil.Discard) + kubectl.GenBashCompletionFile("out.sh") +} +``` + +`out.sh` will get you completions of subcommands and flags. Copy it to `/etc/bash_completion.d/` as described [here](https://debian-administration.org/article/316/An_introduction_to_bash_completion_part_1) and reset your terminal to use autocompletion. If you make additional annotations to your code, you can get even more intelligent and flexible behavior. + +## Creating your own custom functions + +Some more actual code that works in kubernetes: + +```bash +const ( + bash_completion_func = `__kubectl_parse_get() +{ + local kubectl_output out + if kubectl_output=$(kubectl get --no-headers "$1" 2>/dev/null); then + out=($(echo "${kubectl_output}" | awk '{print $1}')) + COMPREPLY=( $( compgen -W "${out[*]}" -- "$cur" ) ) + fi +} + +__kubectl_get_resource() +{ + if [[ ${#nouns[@]} -eq 0 ]]; then + return 1 + fi + __kubectl_parse_get ${nouns[${#nouns[@]} -1]} + if [[ $? -eq 0 ]]; then + return 0 + fi +} + +__custom_func() { + case ${last_command} in + kubectl_get | kubectl_describe | kubectl_delete | kubectl_stop) + __kubectl_get_resource + return + ;; + *) + ;; + esac +} +`) +``` + +And then I set that in my command definition: + +```go +cmds := &cobra.Command{ + Use: "kubectl", + Short: "kubectl controls the Kubernetes cluster manager", + Long: `kubectl controls the Kubernetes cluster manager. + +Find more information at https://github.com/GoogleCloudPlatform/kubernetes.`, + Run: runHelp, + BashCompletionFunction: bash_completion_func, +} +``` + +The `BashCompletionFunction` option is really only valid/useful on the root command. Doing the above will cause `__custom_func()` to be called when the built in processor was unable to find a solution. In the case of kubernetes a valid command might look something like `kubectl get pod [mypod]`. If you type `kubectl get pod [tab][tab]` the `__customc_func()` will run because the cobra.Command only understood "kubectl" and "get." `__custom_func()` will see that the cobra.Command is "kubectl_get" and will thus call another helper `__kubectl_get_resource()`. `__kubectl_get_resource` will look at the 'nouns' collected. In our example the only noun will be `pod`. So it will call `__kubectl_parse_get pod`. `__kubectl_parse_get` will actually call out to kubernetes and get any pods. It will then set `COMPREPLY` to valid pods! + +## Have the completions code complete your 'nouns' + +In the above example "pod" was assumed to already be typed. But if you want `kubectl get [tab][tab]` to show a list of valid "nouns" you have to set them. Simplified code from `kubectl get` looks like: + +```go +validArgs []string = { "pod", "node", "service", "replicationcontroller" } + +cmd := &cobra.Command{ + Use: "get [(-o|--output=)json|yaml|template|...] (RESOURCE [NAME] | RESOURCE/NAME ...)", + Short: "Display one or many resources", + Long: get_long, + Example: get_example, + Run: func(cmd *cobra.Command, args []string) { + err := RunGet(f, out, cmd, args) + util.CheckErr(err) + }, + ValidArgs: validArgs, +} +``` + +Notice we put the "ValidArgs" on the "get" subcommand. Doing so will give results like + +```bash +# kubectl get [tab][tab] +node pod replicationcontroller service +``` + +## Plural form and shortcuts for nouns + +If your nouns have a number of aliases, you can define them alongside `ValidArgs` using `ArgAliases`: + +```go +argAliases []string = { "pods", "nodes", "services", "svc", "replicationcontrollers", "rc" } + +cmd := &cobra.Command{ + ... + ValidArgs: validArgs, + ArgAliases: argAliases +} +``` + +The aliases are not shown to the user on tab completion, but they are accepted as valid nouns by +the completion algorithm if entered manually, e.g. in: + +```bash +# kubectl get rc [tab][tab] +backend frontend database +``` + +Note that without declaring `rc` as an alias, the completion algorithm would show the list of nouns +in this example again instead of the replication controllers. + +## Mark flags as required + +Most of the time completions will only show subcommands. But if a flag is required to make a subcommand work, you probably want it to show up when the user types [tab][tab]. Marking a flag as 'Required' is incredibly easy. + +```go +cmd.MarkFlagRequired("pod") +cmd.MarkFlagRequired("container") +``` + +and you'll get something like + +```bash +# kubectl exec [tab][tab][tab] +-c --container= -p --pod= +``` + +# Specify valid filename extensions for flags that take a filename + +In this example we use --filename= and expect to get a json or yaml file as the argument. To make this easier we annotate the --filename flag with valid filename extensions. + +```go + annotations := []string{"json", "yaml", "yml"} + annotation := make(map[string][]string) + annotation[cobra.BashCompFilenameExt] = annotations + + flag := &pflag.Flag{ + Name: "filename", + Shorthand: "f", + Usage: usage, + Value: value, + DefValue: value.String(), + Annotations: annotation, + } + cmd.Flags().AddFlag(flag) +``` + +Now when you run a command with this filename flag you'll get something like + +```bash +# kubectl create -f +test/ example/ rpmbuild/ +hello.yml test.json +``` + +So while there are many other files in the CWD it only shows me subdirs and those with valid extensions. + +# Specify custom flag completion + +Similar to the filename completion and filtering using cobra.BashCompFilenameExt, you can specify +a custom flag completion function with cobra.BashCompCustom: + +```go + annotation := make(map[string][]string) + annotation[cobra.BashCompCustom] = []string{"__kubectl_get_namespaces"} + + flag := &pflag.Flag{ + Name: "namespace", + Usage: usage, + Annotations: annotation, + } + cmd.Flags().AddFlag(flag) +``` + +In addition add the `__handle_namespace_flag` implementation in the `BashCompletionFunction` +value, e.g.: + +```bash +__kubectl_get_namespaces() +{ + local template + template="{{ range .items }}{{ .metadata.name }} {{ end }}" + local kubectl_out + if kubectl_out=$(kubectl get -o template --template="${template}" namespace 2>/dev/null); then + COMPREPLY=( $( compgen -W "${kubectl_out}[*]" -- "$cur" ) ) + fi +} +``` +# Using bash aliases for commands + +You can also configure the `bash aliases` for the commands and they will also support completions. + +```bash +alias aliasname=origcommand +complete -o default -F __start_origcommand aliasname + +# and now when you run `aliasname` completion will make +# suggestions as it did for `origcommand`. + +$) aliasname +completion firstcommand secondcommand +``` diff --git a/vendor/github.com/spf13/cobra/cobra.go b/vendor/github.com/spf13/cobra/cobra.go new file mode 100644 index 000000000..7010fd15b --- /dev/null +++ b/vendor/github.com/spf13/cobra/cobra.go @@ -0,0 +1,200 @@ +// Copyright © 2013 Steve Francia . +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Commands similar to git, go tools and other modern CLI tools +// inspired by go, go-Commander, gh and subcommand + +package cobra + +import ( + "fmt" + "io" + "reflect" + "strconv" + "strings" + "text/template" + "unicode" +) + +var templateFuncs = template.FuncMap{ + "trim": strings.TrimSpace, + "trimRightSpace": trimRightSpace, + "trimTrailingWhitespaces": trimRightSpace, + "appendIfNotPresent": appendIfNotPresent, + "rpad": rpad, + "gt": Gt, + "eq": Eq, +} + +var initializers []func() + +// EnablePrefixMatching allows to set automatic prefix matching. Automatic prefix matching can be a dangerous thing +// to automatically enable in CLI tools. +// Set this to true to enable it. +var EnablePrefixMatching = false + +// EnableCommandSorting controls sorting of the slice of commands, which is turned on by default. +// To disable sorting, set it to false. +var EnableCommandSorting = true + +// MousetrapHelpText enables an information splash screen on Windows +// if the CLI is started from explorer.exe. +// To disable the mousetrap, just set this variable to blank string (""). +// Works only on Microsoft Windows. +var MousetrapHelpText string = `This is a command line tool. + +You need to open cmd.exe and run it from there. +` + +// AddTemplateFunc adds a template function that's available to Usage and Help +// template generation. +func AddTemplateFunc(name string, tmplFunc interface{}) { + templateFuncs[name] = tmplFunc +} + +// AddTemplateFuncs adds multiple template functions that are available to Usage and +// Help template generation. +func AddTemplateFuncs(tmplFuncs template.FuncMap) { + for k, v := range tmplFuncs { + templateFuncs[k] = v + } +} + +// OnInitialize sets the passed functions to be run when each command's +// Execute method is called. +func OnInitialize(y ...func()) { + initializers = append(initializers, y...) +} + +// FIXME Gt is unused by cobra and should be removed in a version 2. It exists only for compatibility with users of cobra. + +// Gt takes two types and checks whether the first type is greater than the second. In case of types Arrays, Chans, +// Maps and Slices, Gt will compare their lengths. Ints are compared directly while strings are first parsed as +// ints and then compared. +func Gt(a interface{}, b interface{}) bool { + var left, right int64 + av := reflect.ValueOf(a) + + switch av.Kind() { + case reflect.Array, reflect.Chan, reflect.Map, reflect.Slice: + left = int64(av.Len()) + case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: + left = av.Int() + case reflect.String: + left, _ = strconv.ParseInt(av.String(), 10, 64) + } + + bv := reflect.ValueOf(b) + + switch bv.Kind() { + case reflect.Array, reflect.Chan, reflect.Map, reflect.Slice: + right = int64(bv.Len()) + case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: + right = bv.Int() + case reflect.String: + right, _ = strconv.ParseInt(bv.String(), 10, 64) + } + + return left > right +} + +// FIXME Eq is unused by cobra and should be removed in a version 2. It exists only for compatibility with users of cobra. + +// Eq takes two types and checks whether they are equal. Supported types are int and string. Unsupported types will panic. +func Eq(a interface{}, b interface{}) bool { + av := reflect.ValueOf(a) + bv := reflect.ValueOf(b) + + switch av.Kind() { + case reflect.Array, reflect.Chan, reflect.Map, reflect.Slice: + panic("Eq called on unsupported type") + case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: + return av.Int() == bv.Int() + case reflect.String: + return av.String() == bv.String() + } + return false +} + +func trimRightSpace(s string) string { + return strings.TrimRightFunc(s, unicode.IsSpace) +} + +// FIXME appendIfNotPresent is unused by cobra and should be removed in a version 2. It exists only for compatibility with users of cobra. + +// appendIfNotPresent will append stringToAppend to the end of s, but only if it's not yet present in s. +func appendIfNotPresent(s, stringToAppend string) string { + if strings.Contains(s, stringToAppend) { + return s + } + return s + " " + stringToAppend +} + +// rpad adds padding to the right of a string. +func rpad(s string, padding int) string { + template := fmt.Sprintf("%%-%ds", padding) + return fmt.Sprintf(template, s) +} + +// tmpl executes the given template text on data, writing the result to w. +func tmpl(w io.Writer, text string, data interface{}) error { + t := template.New("top") + t.Funcs(templateFuncs) + template.Must(t.Parse(text)) + return t.Execute(w, data) +} + +// ld compares two strings and returns the levenshtein distance between them. +func ld(s, t string, ignoreCase bool) int { + if ignoreCase { + s = strings.ToLower(s) + t = strings.ToLower(t) + } + d := make([][]int, len(s)+1) + for i := range d { + d[i] = make([]int, len(t)+1) + } + for i := range d { + d[i][0] = i + } + for j := range d[0] { + d[0][j] = j + } + for j := 1; j <= len(t); j++ { + for i := 1; i <= len(s); i++ { + if s[i-1] == t[j-1] { + d[i][j] = d[i-1][j-1] + } else { + min := d[i-1][j] + if d[i][j-1] < min { + min = d[i][j-1] + } + if d[i-1][j-1] < min { + min = d[i-1][j-1] + } + d[i][j] = min + 1 + } + } + + } + return d[len(s)][len(t)] +} + +func stringInSlice(a string, list []string) bool { + for _, b := range list { + if b == a { + return true + } + } + return false +} diff --git a/vendor/github.com/spf13/cobra/command.go b/vendor/github.com/spf13/cobra/command.go new file mode 100644 index 000000000..34d1bf367 --- /dev/null +++ b/vendor/github.com/spf13/cobra/command.go @@ -0,0 +1,1517 @@ +// Copyright © 2013 Steve Francia . +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Package cobra is a commander providing a simple interface to create powerful modern CLI interfaces. +// In addition to providing an interface, Cobra simultaneously provides a controller to organize your application code. +package cobra + +import ( + "bytes" + "fmt" + "io" + "os" + "path/filepath" + "sort" + "strings" + + flag "github.com/spf13/pflag" +) + +// FParseErrWhitelist configures Flag parse errors to be ignored +type FParseErrWhitelist flag.ParseErrorsWhitelist + +// Command is just that, a command for your application. +// E.g. 'go run ...' - 'run' is the command. Cobra requires +// you to define the usage and description as part of your command +// definition to ensure usability. +type Command struct { + // Use is the one-line usage message. + Use string + + // Aliases is an array of aliases that can be used instead of the first word in Use. + Aliases []string + + // SuggestFor is an array of command names for which this command will be suggested - + // similar to aliases but only suggests. + SuggestFor []string + + // Short is the short description shown in the 'help' output. + Short string + + // Long is the long message shown in the 'help ' output. + Long string + + // Example is examples of how to use the command. + Example string + + // ValidArgs is list of all valid non-flag arguments that are accepted in bash completions + ValidArgs []string + + // Expected arguments + Args PositionalArgs + + // ArgAliases is List of aliases for ValidArgs. + // These are not suggested to the user in the bash completion, + // but accepted if entered manually. + ArgAliases []string + + // BashCompletionFunction is custom functions used by the bash autocompletion generator. + BashCompletionFunction string + + // Deprecated defines, if this command is deprecated and should print this string when used. + Deprecated string + + // Hidden defines, if this command is hidden and should NOT show up in the list of available commands. + Hidden bool + + // Annotations are key/value pairs that can be used by applications to identify or + // group commands. + Annotations map[string]string + + // Version defines the version for this command. If this value is non-empty and the command does not + // define a "version" flag, a "version" boolean flag will be added to the command and, if specified, + // will print content of the "Version" variable. + Version string + + // The *Run functions are executed in the following order: + // * PersistentPreRun() + // * PreRun() + // * Run() + // * PostRun() + // * PersistentPostRun() + // All functions get the same args, the arguments after the command name. + // + // PersistentPreRun: children of this command will inherit and execute. + PersistentPreRun func(cmd *Command, args []string) + // PersistentPreRunE: PersistentPreRun but returns an error. + PersistentPreRunE func(cmd *Command, args []string) error + // PreRun: children of this command will not inherit. + PreRun func(cmd *Command, args []string) + // PreRunE: PreRun but returns an error. + PreRunE func(cmd *Command, args []string) error + // Run: Typically the actual work function. Most commands will only implement this. + Run func(cmd *Command, args []string) + // RunE: Run but returns an error. + RunE func(cmd *Command, args []string) error + // PostRun: run after the Run command. + PostRun func(cmd *Command, args []string) + // PostRunE: PostRun but returns an error. + PostRunE func(cmd *Command, args []string) error + // PersistentPostRun: children of this command will inherit and execute after PostRun. + PersistentPostRun func(cmd *Command, args []string) + // PersistentPostRunE: PersistentPostRun but returns an error. + PersistentPostRunE func(cmd *Command, args []string) error + + // SilenceErrors is an option to quiet errors down stream. + SilenceErrors bool + + // SilenceUsage is an option to silence usage when an error occurs. + SilenceUsage bool + + // DisableFlagParsing disables the flag parsing. + // If this is true all flags will be passed to the command as arguments. + DisableFlagParsing bool + + // DisableAutoGenTag defines, if gen tag ("Auto generated by spf13/cobra...") + // will be printed by generating docs for this command. + DisableAutoGenTag bool + + // DisableFlagsInUseLine will disable the addition of [flags] to the usage + // line of a command when printing help or generating docs + DisableFlagsInUseLine bool + + // DisableSuggestions disables the suggestions based on Levenshtein distance + // that go along with 'unknown command' messages. + DisableSuggestions bool + // SuggestionsMinimumDistance defines minimum levenshtein distance to display suggestions. + // Must be > 0. + SuggestionsMinimumDistance int + + // TraverseChildren parses flags on all parents before executing child command. + TraverseChildren bool + + //FParseErrWhitelist flag parse errors to be ignored + FParseErrWhitelist FParseErrWhitelist + + // commands is the list of commands supported by this program. + commands []*Command + // parent is a parent command for this command. + parent *Command + // Max lengths of commands' string lengths for use in padding. + commandsMaxUseLen int + commandsMaxCommandPathLen int + commandsMaxNameLen int + // commandsAreSorted defines, if command slice are sorted or not. + commandsAreSorted bool + // commandCalledAs is the name or alias value used to call this command. + commandCalledAs struct { + name string + called bool + } + + // args is actual args parsed from flags. + args []string + // flagErrorBuf contains all error messages from pflag. + flagErrorBuf *bytes.Buffer + // flags is full set of flags. + flags *flag.FlagSet + // pflags contains persistent flags. + pflags *flag.FlagSet + // lflags contains local flags. + lflags *flag.FlagSet + // iflags contains inherited flags. + iflags *flag.FlagSet + // parentsPflags is all persistent flags of cmd's parents. + parentsPflags *flag.FlagSet + // globNormFunc is the global normalization function + // that we can use on every pflag set and children commands + globNormFunc func(f *flag.FlagSet, name string) flag.NormalizedName + + // output is an output writer defined by user. + output io.Writer + // usageFunc is usage func defined by user. + usageFunc func(*Command) error + // usageTemplate is usage template defined by user. + usageTemplate string + // flagErrorFunc is func defined by user and it's called when the parsing of + // flags returns an error. + flagErrorFunc func(*Command, error) error + // helpTemplate is help template defined by user. + helpTemplate string + // helpFunc is help func defined by user. + helpFunc func(*Command, []string) + // helpCommand is command with usage 'help'. If it's not defined by user, + // cobra uses default help command. + helpCommand *Command + // versionTemplate is the version template defined by user. + versionTemplate string +} + +// SetArgs sets arguments for the command. It is set to os.Args[1:] by default, if desired, can be overridden +// particularly useful when testing. +func (c *Command) SetArgs(a []string) { + c.args = a +} + +// SetOutput sets the destination for usage and error messages. +// If output is nil, os.Stderr is used. +func (c *Command) SetOutput(output io.Writer) { + c.output = output +} + +// SetUsageFunc sets usage function. Usage can be defined by application. +func (c *Command) SetUsageFunc(f func(*Command) error) { + c.usageFunc = f +} + +// SetUsageTemplate sets usage template. Can be defined by Application. +func (c *Command) SetUsageTemplate(s string) { + c.usageTemplate = s +} + +// SetFlagErrorFunc sets a function to generate an error when flag parsing +// fails. +func (c *Command) SetFlagErrorFunc(f func(*Command, error) error) { + c.flagErrorFunc = f +} + +// SetHelpFunc sets help function. Can be defined by Application. +func (c *Command) SetHelpFunc(f func(*Command, []string)) { + c.helpFunc = f +} + +// SetHelpCommand sets help command. +func (c *Command) SetHelpCommand(cmd *Command) { + c.helpCommand = cmd +} + +// SetHelpTemplate sets help template to be used. Application can use it to set custom template. +func (c *Command) SetHelpTemplate(s string) { + c.helpTemplate = s +} + +// SetVersionTemplate sets version template to be used. Application can use it to set custom template. +func (c *Command) SetVersionTemplate(s string) { + c.versionTemplate = s +} + +// SetGlobalNormalizationFunc sets a normalization function to all flag sets and also to child commands. +// The user should not have a cyclic dependency on commands. +func (c *Command) SetGlobalNormalizationFunc(n func(f *flag.FlagSet, name string) flag.NormalizedName) { + c.Flags().SetNormalizeFunc(n) + c.PersistentFlags().SetNormalizeFunc(n) + c.globNormFunc = n + + for _, command := range c.commands { + command.SetGlobalNormalizationFunc(n) + } +} + +// OutOrStdout returns output to stdout. +func (c *Command) OutOrStdout() io.Writer { + return c.getOut(os.Stdout) +} + +// OutOrStderr returns output to stderr +func (c *Command) OutOrStderr() io.Writer { + return c.getOut(os.Stderr) +} + +func (c *Command) getOut(def io.Writer) io.Writer { + if c.output != nil { + return c.output + } + if c.HasParent() { + return c.parent.getOut(def) + } + return def +} + +// UsageFunc returns either the function set by SetUsageFunc for this command +// or a parent, or it returns a default usage function. +func (c *Command) UsageFunc() (f func(*Command) error) { + if c.usageFunc != nil { + return c.usageFunc + } + if c.HasParent() { + return c.Parent().UsageFunc() + } + return func(c *Command) error { + c.mergePersistentFlags() + err := tmpl(c.OutOrStderr(), c.UsageTemplate(), c) + if err != nil { + c.Println(err) + } + return err + } +} + +// Usage puts out the usage for the command. +// Used when a user provides invalid input. +// Can be defined by user by overriding UsageFunc. +func (c *Command) Usage() error { + return c.UsageFunc()(c) +} + +// HelpFunc returns either the function set by SetHelpFunc for this command +// or a parent, or it returns a function with default help behavior. +func (c *Command) HelpFunc() func(*Command, []string) { + if c.helpFunc != nil { + return c.helpFunc + } + if c.HasParent() { + return c.Parent().HelpFunc() + } + return func(c *Command, a []string) { + c.mergePersistentFlags() + err := tmpl(c.OutOrStdout(), c.HelpTemplate(), c) + if err != nil { + c.Println(err) + } + } +} + +// Help puts out the help for the command. +// Used when a user calls help [command]. +// Can be defined by user by overriding HelpFunc. +func (c *Command) Help() error { + c.HelpFunc()(c, []string{}) + return nil +} + +// UsageString return usage string. +func (c *Command) UsageString() string { + tmpOutput := c.output + bb := new(bytes.Buffer) + c.SetOutput(bb) + c.Usage() + c.output = tmpOutput + return bb.String() +} + +// FlagErrorFunc returns either the function set by SetFlagErrorFunc for this +// command or a parent, or it returns a function which returns the original +// error. +func (c *Command) FlagErrorFunc() (f func(*Command, error) error) { + if c.flagErrorFunc != nil { + return c.flagErrorFunc + } + + if c.HasParent() { + return c.parent.FlagErrorFunc() + } + return func(c *Command, err error) error { + return err + } +} + +var minUsagePadding = 25 + +// UsagePadding return padding for the usage. +func (c *Command) UsagePadding() int { + if c.parent == nil || minUsagePadding > c.parent.commandsMaxUseLen { + return minUsagePadding + } + return c.parent.commandsMaxUseLen +} + +var minCommandPathPadding = 11 + +// CommandPathPadding return padding for the command path. +func (c *Command) CommandPathPadding() int { + if c.parent == nil || minCommandPathPadding > c.parent.commandsMaxCommandPathLen { + return minCommandPathPadding + } + return c.parent.commandsMaxCommandPathLen +} + +var minNamePadding = 11 + +// NamePadding returns padding for the name. +func (c *Command) NamePadding() int { + if c.parent == nil || minNamePadding > c.parent.commandsMaxNameLen { + return minNamePadding + } + return c.parent.commandsMaxNameLen +} + +// UsageTemplate returns usage template for the command. +func (c *Command) UsageTemplate() string { + if c.usageTemplate != "" { + return c.usageTemplate + } + + if c.HasParent() { + return c.parent.UsageTemplate() + } + return `Usage:{{if .Runnable}} + {{.UseLine}}{{end}}{{if .HasAvailableSubCommands}} + {{.CommandPath}} [command]{{end}}{{if gt (len .Aliases) 0}} + +Aliases: + {{.NameAndAliases}}{{end}}{{if .HasExample}} + +Examples: +{{.Example}}{{end}}{{if .HasAvailableSubCommands}} + +Available Commands:{{range .Commands}}{{if (or .IsAvailableCommand (eq .Name "help"))}} + {{rpad .Name .NamePadding }} {{.Short}}{{end}}{{end}}{{end}}{{if .HasAvailableLocalFlags}} + +Flags: +{{.LocalFlags.FlagUsages | trimTrailingWhitespaces}}{{end}}{{if .HasAvailableInheritedFlags}} + +Global Flags: +{{.InheritedFlags.FlagUsages | trimTrailingWhitespaces}}{{end}}{{if .HasHelpSubCommands}} + +Additional help topics:{{range .Commands}}{{if .IsAdditionalHelpTopicCommand}} + {{rpad .CommandPath .CommandPathPadding}} {{.Short}}{{end}}{{end}}{{end}}{{if .HasAvailableSubCommands}} + +Use "{{.CommandPath}} [command] --help" for more information about a command.{{end}} +` +} + +// HelpTemplate return help template for the command. +func (c *Command) HelpTemplate() string { + if c.helpTemplate != "" { + return c.helpTemplate + } + + if c.HasParent() { + return c.parent.HelpTemplate() + } + return `{{with (or .Long .Short)}}{{. | trimTrailingWhitespaces}} + +{{end}}{{if or .Runnable .HasSubCommands}}{{.UsageString}}{{end}}` +} + +// VersionTemplate return version template for the command. +func (c *Command) VersionTemplate() string { + if c.versionTemplate != "" { + return c.versionTemplate + } + + if c.HasParent() { + return c.parent.VersionTemplate() + } + return `{{with .Name}}{{printf "%s " .}}{{end}}{{printf "version %s" .Version}} +` +} + +func hasNoOptDefVal(name string, fs *flag.FlagSet) bool { + flag := fs.Lookup(name) + if flag == nil { + return false + } + return flag.NoOptDefVal != "" +} + +func shortHasNoOptDefVal(name string, fs *flag.FlagSet) bool { + if len(name) == 0 { + return false + } + + flag := fs.ShorthandLookup(name[:1]) + if flag == nil { + return false + } + return flag.NoOptDefVal != "" +} + +func stripFlags(args []string, c *Command) []string { + if len(args) == 0 { + return args + } + c.mergePersistentFlags() + + commands := []string{} + flags := c.Flags() + +Loop: + for len(args) > 0 { + s := args[0] + args = args[1:] + switch { + case s == "--": + // "--" terminates the flags + break Loop + case strings.HasPrefix(s, "--") && !strings.Contains(s, "=") && !hasNoOptDefVal(s[2:], flags): + // If '--flag arg' then + // delete arg from args. + fallthrough // (do the same as below) + case strings.HasPrefix(s, "-") && !strings.Contains(s, "=") && len(s) == 2 && !shortHasNoOptDefVal(s[1:], flags): + // If '-f arg' then + // delete 'arg' from args or break the loop if len(args) <= 1. + if len(args) <= 1 { + break Loop + } else { + args = args[1:] + continue + } + case s != "" && !strings.HasPrefix(s, "-"): + commands = append(commands, s) + } + } + + return commands +} + +// argsMinusFirstX removes only the first x from args. Otherwise, commands that look like +// openshift admin policy add-role-to-user admin my-user, lose the admin argument (arg[4]). +func argsMinusFirstX(args []string, x string) []string { + for i, y := range args { + if x == y { + ret := []string{} + ret = append(ret, args[:i]...) + ret = append(ret, args[i+1:]...) + return ret + } + } + return args +} + +func isFlagArg(arg string) bool { + return ((len(arg) >= 3 && arg[1] == '-') || + (len(arg) >= 2 && arg[0] == '-' && arg[1] != '-')) +} + +// Find the target command given the args and command tree +// Meant to be run on the highest node. Only searches down. +func (c *Command) Find(args []string) (*Command, []string, error) { + var innerfind func(*Command, []string) (*Command, []string) + + innerfind = func(c *Command, innerArgs []string) (*Command, []string) { + argsWOflags := stripFlags(innerArgs, c) + if len(argsWOflags) == 0 { + return c, innerArgs + } + nextSubCmd := argsWOflags[0] + + cmd := c.findNext(nextSubCmd) + if cmd != nil { + return innerfind(cmd, argsMinusFirstX(innerArgs, nextSubCmd)) + } + return c, innerArgs + } + + commandFound, a := innerfind(c, args) + if commandFound.Args == nil { + return commandFound, a, legacyArgs(commandFound, stripFlags(a, commandFound)) + } + return commandFound, a, nil +} + +func (c *Command) findSuggestions(arg string) string { + if c.DisableSuggestions { + return "" + } + if c.SuggestionsMinimumDistance <= 0 { + c.SuggestionsMinimumDistance = 2 + } + suggestionsString := "" + if suggestions := c.SuggestionsFor(arg); len(suggestions) > 0 { + suggestionsString += "\n\nDid you mean this?\n" + for _, s := range suggestions { + suggestionsString += fmt.Sprintf("\t%v\n", s) + } + } + return suggestionsString +} + +func (c *Command) findNext(next string) *Command { + matches := make([]*Command, 0) + for _, cmd := range c.commands { + if cmd.Name() == next || cmd.HasAlias(next) { + cmd.commandCalledAs.name = next + return cmd + } + if EnablePrefixMatching && cmd.hasNameOrAliasPrefix(next) { + matches = append(matches, cmd) + } + } + + if len(matches) == 1 { + return matches[0] + } + + return nil +} + +// Traverse the command tree to find the command, and parse args for +// each parent. +func (c *Command) Traverse(args []string) (*Command, []string, error) { + flags := []string{} + inFlag := false + + for i, arg := range args { + switch { + // A long flag with a space separated value + case strings.HasPrefix(arg, "--") && !strings.Contains(arg, "="): + // TODO: this isn't quite right, we should really check ahead for 'true' or 'false' + inFlag = !hasNoOptDefVal(arg[2:], c.Flags()) + flags = append(flags, arg) + continue + // A short flag with a space separated value + case strings.HasPrefix(arg, "-") && !strings.Contains(arg, "=") && len(arg) == 2 && !shortHasNoOptDefVal(arg[1:], c.Flags()): + inFlag = true + flags = append(flags, arg) + continue + // The value for a flag + case inFlag: + inFlag = false + flags = append(flags, arg) + continue + // A flag without a value, or with an `=` separated value + case isFlagArg(arg): + flags = append(flags, arg) + continue + } + + cmd := c.findNext(arg) + if cmd == nil { + return c, args, nil + } + + if err := c.ParseFlags(flags); err != nil { + return nil, args, err + } + return cmd.Traverse(args[i+1:]) + } + return c, args, nil +} + +// SuggestionsFor provides suggestions for the typedName. +func (c *Command) SuggestionsFor(typedName string) []string { + suggestions := []string{} + for _, cmd := range c.commands { + if cmd.IsAvailableCommand() { + levenshteinDistance := ld(typedName, cmd.Name(), true) + suggestByLevenshtein := levenshteinDistance <= c.SuggestionsMinimumDistance + suggestByPrefix := strings.HasPrefix(strings.ToLower(cmd.Name()), strings.ToLower(typedName)) + if suggestByLevenshtein || suggestByPrefix { + suggestions = append(suggestions, cmd.Name()) + } + for _, explicitSuggestion := range cmd.SuggestFor { + if strings.EqualFold(typedName, explicitSuggestion) { + suggestions = append(suggestions, cmd.Name()) + } + } + } + } + return suggestions +} + +// VisitParents visits all parents of the command and invokes fn on each parent. +func (c *Command) VisitParents(fn func(*Command)) { + if c.HasParent() { + fn(c.Parent()) + c.Parent().VisitParents(fn) + } +} + +// Root finds root command. +func (c *Command) Root() *Command { + if c.HasParent() { + return c.Parent().Root() + } + return c +} + +// ArgsLenAtDash will return the length of c.Flags().Args at the moment +// when a -- was found during args parsing. +func (c *Command) ArgsLenAtDash() int { + return c.Flags().ArgsLenAtDash() +} + +func (c *Command) execute(a []string) (err error) { + if c == nil { + return fmt.Errorf("Called Execute() on a nil Command") + } + + if len(c.Deprecated) > 0 { + c.Printf("Command %q is deprecated, %s\n", c.Name(), c.Deprecated) + } + + // initialize help and version flag at the last point possible to allow for user + // overriding + c.InitDefaultHelpFlag() + c.InitDefaultVersionFlag() + + err = c.ParseFlags(a) + if err != nil { + return c.FlagErrorFunc()(c, err) + } + + // If help is called, regardless of other flags, return we want help. + // Also say we need help if the command isn't runnable. + helpVal, err := c.Flags().GetBool("help") + if err != nil { + // should be impossible to get here as we always declare a help + // flag in InitDefaultHelpFlag() + c.Println("\"help\" flag declared as non-bool. Please correct your code") + return err + } + + if helpVal { + return flag.ErrHelp + } + + // for back-compat, only add version flag behavior if version is defined + if c.Version != "" { + versionVal, err := c.Flags().GetBool("version") + if err != nil { + c.Println("\"version\" flag declared as non-bool. Please correct your code") + return err + } + if versionVal { + err := tmpl(c.OutOrStdout(), c.VersionTemplate(), c) + if err != nil { + c.Println(err) + } + return err + } + } + + if !c.Runnable() { + return flag.ErrHelp + } + + c.preRun() + + argWoFlags := c.Flags().Args() + if c.DisableFlagParsing { + argWoFlags = a + } + + if err := c.ValidateArgs(argWoFlags); err != nil { + return err + } + + for p := c; p != nil; p = p.Parent() { + if p.PersistentPreRunE != nil { + if err := p.PersistentPreRunE(c, argWoFlags); err != nil { + return err + } + break + } else if p.PersistentPreRun != nil { + p.PersistentPreRun(c, argWoFlags) + break + } + } + if c.PreRunE != nil { + if err := c.PreRunE(c, argWoFlags); err != nil { + return err + } + } else if c.PreRun != nil { + c.PreRun(c, argWoFlags) + } + + if err := c.validateRequiredFlags(); err != nil { + return err + } + if c.RunE != nil { + if err := c.RunE(c, argWoFlags); err != nil { + return err + } + } else { + c.Run(c, argWoFlags) + } + if c.PostRunE != nil { + if err := c.PostRunE(c, argWoFlags); err != nil { + return err + } + } else if c.PostRun != nil { + c.PostRun(c, argWoFlags) + } + for p := c; p != nil; p = p.Parent() { + if p.PersistentPostRunE != nil { + if err := p.PersistentPostRunE(c, argWoFlags); err != nil { + return err + } + break + } else if p.PersistentPostRun != nil { + p.PersistentPostRun(c, argWoFlags) + break + } + } + + return nil +} + +func (c *Command) preRun() { + for _, x := range initializers { + x() + } +} + +// Execute uses the args (os.Args[1:] by default) +// and run through the command tree finding appropriate matches +// for commands and then corresponding flags. +func (c *Command) Execute() error { + _, err := c.ExecuteC() + return err +} + +// ExecuteC executes the command. +func (c *Command) ExecuteC() (cmd *Command, err error) { + // Regardless of what command execute is called on, run on Root only + if c.HasParent() { + return c.Root().ExecuteC() + } + + // windows hook + if preExecHookFn != nil { + preExecHookFn(c) + } + + // initialize help as the last point possible to allow for user + // overriding + c.InitDefaultHelpCmd() + + var args []string + + // Workaround FAIL with "go test -v" or "cobra.test -test.v", see #155 + if c.args == nil && filepath.Base(os.Args[0]) != "cobra.test" { + args = os.Args[1:] + } else { + args = c.args + } + + var flags []string + if c.TraverseChildren { + cmd, flags, err = c.Traverse(args) + } else { + cmd, flags, err = c.Find(args) + } + if err != nil { + // If found parse to a subcommand and then failed, talk about the subcommand + if cmd != nil { + c = cmd + } + if !c.SilenceErrors { + c.Println("Error:", err.Error()) + c.Printf("Run '%v --help' for usage.\n", c.CommandPath()) + } + return c, err + } + + cmd.commandCalledAs.called = true + if cmd.commandCalledAs.name == "" { + cmd.commandCalledAs.name = cmd.Name() + } + + err = cmd.execute(flags) + if err != nil { + // Always show help if requested, even if SilenceErrors is in + // effect + if err == flag.ErrHelp { + cmd.HelpFunc()(cmd, args) + return cmd, nil + } + + // If root command has SilentErrors flagged, + // all subcommands should respect it + if !cmd.SilenceErrors && !c.SilenceErrors { + c.Println("Error:", err.Error()) + } + + // If root command has SilentUsage flagged, + // all subcommands should respect it + if !cmd.SilenceUsage && !c.SilenceUsage { + c.Println(cmd.UsageString()) + } + } + return cmd, err +} + +func (c *Command) ValidateArgs(args []string) error { + if c.Args == nil { + return nil + } + return c.Args(c, args) +} + +func (c *Command) validateRequiredFlags() error { + flags := c.Flags() + missingFlagNames := []string{} + flags.VisitAll(func(pflag *flag.Flag) { + requiredAnnotation, found := pflag.Annotations[BashCompOneRequiredFlag] + if !found { + return + } + if (requiredAnnotation[0] == "true") && !pflag.Changed { + missingFlagNames = append(missingFlagNames, pflag.Name) + } + }) + + if len(missingFlagNames) > 0 { + return fmt.Errorf(`required flag(s) "%s" not set`, strings.Join(missingFlagNames, `", "`)) + } + return nil +} + +// InitDefaultHelpFlag adds default help flag to c. +// It is called automatically by executing the c or by calling help and usage. +// If c already has help flag, it will do nothing. +func (c *Command) InitDefaultHelpFlag() { + c.mergePersistentFlags() + if c.Flags().Lookup("help") == nil { + usage := "help for " + if c.Name() == "" { + usage += "this command" + } else { + usage += c.Name() + } + c.Flags().BoolP("help", "h", false, usage) + } +} + +// InitDefaultVersionFlag adds default version flag to c. +// It is called automatically by executing the c. +// If c already has a version flag, it will do nothing. +// If c.Version is empty, it will do nothing. +func (c *Command) InitDefaultVersionFlag() { + if c.Version == "" { + return + } + + c.mergePersistentFlags() + if c.Flags().Lookup("version") == nil { + usage := "version for " + if c.Name() == "" { + usage += "this command" + } else { + usage += c.Name() + } + c.Flags().Bool("version", false, usage) + } +} + +// InitDefaultHelpCmd adds default help command to c. +// It is called automatically by executing the c or by calling help and usage. +// If c already has help command or c has no subcommands, it will do nothing. +func (c *Command) InitDefaultHelpCmd() { + if !c.HasSubCommands() { + return + } + + if c.helpCommand == nil { + c.helpCommand = &Command{ + Use: "help [command]", + Short: "Help about any command", + Long: `Help provides help for any command in the application. +Simply type ` + c.Name() + ` help [path to command] for full details.`, + + Run: func(c *Command, args []string) { + cmd, _, e := c.Root().Find(args) + if cmd == nil || e != nil { + c.Printf("Unknown help topic %#q\n", args) + c.Root().Usage() + } else { + cmd.InitDefaultHelpFlag() // make possible 'help' flag to be shown + cmd.Help() + } + }, + } + } + c.RemoveCommand(c.helpCommand) + c.AddCommand(c.helpCommand) +} + +// ResetCommands delete parent, subcommand and help command from c. +func (c *Command) ResetCommands() { + c.parent = nil + c.commands = nil + c.helpCommand = nil + c.parentsPflags = nil +} + +// Sorts commands by their names. +type commandSorterByName []*Command + +func (c commandSorterByName) Len() int { return len(c) } +func (c commandSorterByName) Swap(i, j int) { c[i], c[j] = c[j], c[i] } +func (c commandSorterByName) Less(i, j int) bool { return c[i].Name() < c[j].Name() } + +// Commands returns a sorted slice of child commands. +func (c *Command) Commands() []*Command { + // do not sort commands if it already sorted or sorting was disabled + if EnableCommandSorting && !c.commandsAreSorted { + sort.Sort(commandSorterByName(c.commands)) + c.commandsAreSorted = true + } + return c.commands +} + +// AddCommand adds one or more commands to this parent command. +func (c *Command) AddCommand(cmds ...*Command) { + for i, x := range cmds { + if cmds[i] == c { + panic("Command can't be a child of itself") + } + cmds[i].parent = c + // update max lengths + usageLen := len(x.Use) + if usageLen > c.commandsMaxUseLen { + c.commandsMaxUseLen = usageLen + } + commandPathLen := len(x.CommandPath()) + if commandPathLen > c.commandsMaxCommandPathLen { + c.commandsMaxCommandPathLen = commandPathLen + } + nameLen := len(x.Name()) + if nameLen > c.commandsMaxNameLen { + c.commandsMaxNameLen = nameLen + } + // If global normalization function exists, update all children + if c.globNormFunc != nil { + x.SetGlobalNormalizationFunc(c.globNormFunc) + } + c.commands = append(c.commands, x) + c.commandsAreSorted = false + } +} + +// RemoveCommand removes one or more commands from a parent command. +func (c *Command) RemoveCommand(cmds ...*Command) { + commands := []*Command{} +main: + for _, command := range c.commands { + for _, cmd := range cmds { + if command == cmd { + command.parent = nil + continue main + } + } + commands = append(commands, command) + } + c.commands = commands + // recompute all lengths + c.commandsMaxUseLen = 0 + c.commandsMaxCommandPathLen = 0 + c.commandsMaxNameLen = 0 + for _, command := range c.commands { + usageLen := len(command.Use) + if usageLen > c.commandsMaxUseLen { + c.commandsMaxUseLen = usageLen + } + commandPathLen := len(command.CommandPath()) + if commandPathLen > c.commandsMaxCommandPathLen { + c.commandsMaxCommandPathLen = commandPathLen + } + nameLen := len(command.Name()) + if nameLen > c.commandsMaxNameLen { + c.commandsMaxNameLen = nameLen + } + } +} + +// Print is a convenience method to Print to the defined output, fallback to Stderr if not set. +func (c *Command) Print(i ...interface{}) { + fmt.Fprint(c.OutOrStderr(), i...) +} + +// Println is a convenience method to Println to the defined output, fallback to Stderr if not set. +func (c *Command) Println(i ...interface{}) { + c.Print(fmt.Sprintln(i...)) +} + +// Printf is a convenience method to Printf to the defined output, fallback to Stderr if not set. +func (c *Command) Printf(format string, i ...interface{}) { + c.Print(fmt.Sprintf(format, i...)) +} + +// CommandPath returns the full path to this command. +func (c *Command) CommandPath() string { + if c.HasParent() { + return c.Parent().CommandPath() + " " + c.Name() + } + return c.Name() +} + +// UseLine puts out the full usage for a given command (including parents). +func (c *Command) UseLine() string { + var useline string + if c.HasParent() { + useline = c.parent.CommandPath() + " " + c.Use + } else { + useline = c.Use + } + if c.DisableFlagsInUseLine { + return useline + } + if c.HasAvailableFlags() && !strings.Contains(useline, "[flags]") { + useline += " [flags]" + } + return useline +} + +// DebugFlags used to determine which flags have been assigned to which commands +// and which persist. +func (c *Command) DebugFlags() { + c.Println("DebugFlags called on", c.Name()) + var debugflags func(*Command) + + debugflags = func(x *Command) { + if x.HasFlags() || x.HasPersistentFlags() { + c.Println(x.Name()) + } + if x.HasFlags() { + x.flags.VisitAll(func(f *flag.Flag) { + if x.HasPersistentFlags() && x.persistentFlag(f.Name) != nil { + c.Println(" -"+f.Shorthand+",", "--"+f.Name, "["+f.DefValue+"]", "", f.Value, " [LP]") + } else { + c.Println(" -"+f.Shorthand+",", "--"+f.Name, "["+f.DefValue+"]", "", f.Value, " [L]") + } + }) + } + if x.HasPersistentFlags() { + x.pflags.VisitAll(func(f *flag.Flag) { + if x.HasFlags() { + if x.flags.Lookup(f.Name) == nil { + c.Println(" -"+f.Shorthand+",", "--"+f.Name, "["+f.DefValue+"]", "", f.Value, " [P]") + } + } else { + c.Println(" -"+f.Shorthand+",", "--"+f.Name, "["+f.DefValue+"]", "", f.Value, " [P]") + } + }) + } + c.Println(x.flagErrorBuf) + if x.HasSubCommands() { + for _, y := range x.commands { + debugflags(y) + } + } + } + + debugflags(c) +} + +// Name returns the command's name: the first word in the use line. +func (c *Command) Name() string { + name := c.Use + i := strings.Index(name, " ") + if i >= 0 { + name = name[:i] + } + return name +} + +// HasAlias determines if a given string is an alias of the command. +func (c *Command) HasAlias(s string) bool { + for _, a := range c.Aliases { + if a == s { + return true + } + } + return false +} + +// CalledAs returns the command name or alias that was used to invoke +// this command or an empty string if the command has not been called. +func (c *Command) CalledAs() string { + if c.commandCalledAs.called { + return c.commandCalledAs.name + } + return "" +} + +// hasNameOrAliasPrefix returns true if the Name or any of aliases start +// with prefix +func (c *Command) hasNameOrAliasPrefix(prefix string) bool { + if strings.HasPrefix(c.Name(), prefix) { + c.commandCalledAs.name = c.Name() + return true + } + for _, alias := range c.Aliases { + if strings.HasPrefix(alias, prefix) { + c.commandCalledAs.name = alias + return true + } + } + return false +} + +// NameAndAliases returns a list of the command name and all aliases +func (c *Command) NameAndAliases() string { + return strings.Join(append([]string{c.Name()}, c.Aliases...), ", ") +} + +// HasExample determines if the command has example. +func (c *Command) HasExample() bool { + return len(c.Example) > 0 +} + +// Runnable determines if the command is itself runnable. +func (c *Command) Runnable() bool { + return c.Run != nil || c.RunE != nil +} + +// HasSubCommands determines if the command has children commands. +func (c *Command) HasSubCommands() bool { + return len(c.commands) > 0 +} + +// IsAvailableCommand determines if a command is available as a non-help command +// (this includes all non deprecated/hidden commands). +func (c *Command) IsAvailableCommand() bool { + if len(c.Deprecated) != 0 || c.Hidden { + return false + } + + if c.HasParent() && c.Parent().helpCommand == c { + return false + } + + if c.Runnable() || c.HasAvailableSubCommands() { + return true + } + + return false +} + +// IsAdditionalHelpTopicCommand determines if a command is an additional +// help topic command; additional help topic command is determined by the +// fact that it is NOT runnable/hidden/deprecated, and has no sub commands that +// are runnable/hidden/deprecated. +// Concrete example: https://github.com/spf13/cobra/issues/393#issuecomment-282741924. +func (c *Command) IsAdditionalHelpTopicCommand() bool { + // if a command is runnable, deprecated, or hidden it is not a 'help' command + if c.Runnable() || len(c.Deprecated) != 0 || c.Hidden { + return false + } + + // if any non-help sub commands are found, the command is not a 'help' command + for _, sub := range c.commands { + if !sub.IsAdditionalHelpTopicCommand() { + return false + } + } + + // the command either has no sub commands, or no non-help sub commands + return true +} + +// HasHelpSubCommands determines if a command has any available 'help' sub commands +// that need to be shown in the usage/help default template under 'additional help +// topics'. +func (c *Command) HasHelpSubCommands() bool { + // return true on the first found available 'help' sub command + for _, sub := range c.commands { + if sub.IsAdditionalHelpTopicCommand() { + return true + } + } + + // the command either has no sub commands, or no available 'help' sub commands + return false +} + +// HasAvailableSubCommands determines if a command has available sub commands that +// need to be shown in the usage/help default template under 'available commands'. +func (c *Command) HasAvailableSubCommands() bool { + // return true on the first found available (non deprecated/help/hidden) + // sub command + for _, sub := range c.commands { + if sub.IsAvailableCommand() { + return true + } + } + + // the command either has no sub commands, or no available (non deprecated/help/hidden) + // sub commands + return false +} + +// HasParent determines if the command is a child command. +func (c *Command) HasParent() bool { + return c.parent != nil +} + +// GlobalNormalizationFunc returns the global normalization function or nil if it doesn't exist. +func (c *Command) GlobalNormalizationFunc() func(f *flag.FlagSet, name string) flag.NormalizedName { + return c.globNormFunc +} + +// Flags returns the complete FlagSet that applies +// to this command (local and persistent declared here and by all parents). +func (c *Command) Flags() *flag.FlagSet { + if c.flags == nil { + c.flags = flag.NewFlagSet(c.Name(), flag.ContinueOnError) + if c.flagErrorBuf == nil { + c.flagErrorBuf = new(bytes.Buffer) + } + c.flags.SetOutput(c.flagErrorBuf) + } + + return c.flags +} + +// LocalNonPersistentFlags are flags specific to this command which will NOT persist to subcommands. +func (c *Command) LocalNonPersistentFlags() *flag.FlagSet { + persistentFlags := c.PersistentFlags() + + out := flag.NewFlagSet(c.Name(), flag.ContinueOnError) + c.LocalFlags().VisitAll(func(f *flag.Flag) { + if persistentFlags.Lookup(f.Name) == nil { + out.AddFlag(f) + } + }) + return out +} + +// LocalFlags returns the local FlagSet specifically set in the current command. +func (c *Command) LocalFlags() *flag.FlagSet { + c.mergePersistentFlags() + + if c.lflags == nil { + c.lflags = flag.NewFlagSet(c.Name(), flag.ContinueOnError) + if c.flagErrorBuf == nil { + c.flagErrorBuf = new(bytes.Buffer) + } + c.lflags.SetOutput(c.flagErrorBuf) + } + c.lflags.SortFlags = c.Flags().SortFlags + if c.globNormFunc != nil { + c.lflags.SetNormalizeFunc(c.globNormFunc) + } + + addToLocal := func(f *flag.Flag) { + if c.lflags.Lookup(f.Name) == nil && c.parentsPflags.Lookup(f.Name) == nil { + c.lflags.AddFlag(f) + } + } + c.Flags().VisitAll(addToLocal) + c.PersistentFlags().VisitAll(addToLocal) + return c.lflags +} + +// InheritedFlags returns all flags which were inherited from parents commands. +func (c *Command) InheritedFlags() *flag.FlagSet { + c.mergePersistentFlags() + + if c.iflags == nil { + c.iflags = flag.NewFlagSet(c.Name(), flag.ContinueOnError) + if c.flagErrorBuf == nil { + c.flagErrorBuf = new(bytes.Buffer) + } + c.iflags.SetOutput(c.flagErrorBuf) + } + + local := c.LocalFlags() + if c.globNormFunc != nil { + c.iflags.SetNormalizeFunc(c.globNormFunc) + } + + c.parentsPflags.VisitAll(func(f *flag.Flag) { + if c.iflags.Lookup(f.Name) == nil && local.Lookup(f.Name) == nil { + c.iflags.AddFlag(f) + } + }) + return c.iflags +} + +// NonInheritedFlags returns all flags which were not inherited from parent commands. +func (c *Command) NonInheritedFlags() *flag.FlagSet { + return c.LocalFlags() +} + +// PersistentFlags returns the persistent FlagSet specifically set in the current command. +func (c *Command) PersistentFlags() *flag.FlagSet { + if c.pflags == nil { + c.pflags = flag.NewFlagSet(c.Name(), flag.ContinueOnError) + if c.flagErrorBuf == nil { + c.flagErrorBuf = new(bytes.Buffer) + } + c.pflags.SetOutput(c.flagErrorBuf) + } + return c.pflags +} + +// ResetFlags deletes all flags from command. +func (c *Command) ResetFlags() { + c.flagErrorBuf = new(bytes.Buffer) + c.flagErrorBuf.Reset() + c.flags = flag.NewFlagSet(c.Name(), flag.ContinueOnError) + c.flags.SetOutput(c.flagErrorBuf) + c.pflags = flag.NewFlagSet(c.Name(), flag.ContinueOnError) + c.pflags.SetOutput(c.flagErrorBuf) + + c.lflags = nil + c.iflags = nil + c.parentsPflags = nil +} + +// HasFlags checks if the command contains any flags (local plus persistent from the entire structure). +func (c *Command) HasFlags() bool { + return c.Flags().HasFlags() +} + +// HasPersistentFlags checks if the command contains persistent flags. +func (c *Command) HasPersistentFlags() bool { + return c.PersistentFlags().HasFlags() +} + +// HasLocalFlags checks if the command has flags specifically declared locally. +func (c *Command) HasLocalFlags() bool { + return c.LocalFlags().HasFlags() +} + +// HasInheritedFlags checks if the command has flags inherited from its parent command. +func (c *Command) HasInheritedFlags() bool { + return c.InheritedFlags().HasFlags() +} + +// HasAvailableFlags checks if the command contains any flags (local plus persistent from the entire +// structure) which are not hidden or deprecated. +func (c *Command) HasAvailableFlags() bool { + return c.Flags().HasAvailableFlags() +} + +// HasAvailablePersistentFlags checks if the command contains persistent flags which are not hidden or deprecated. +func (c *Command) HasAvailablePersistentFlags() bool { + return c.PersistentFlags().HasAvailableFlags() +} + +// HasAvailableLocalFlags checks if the command has flags specifically declared locally which are not hidden +// or deprecated. +func (c *Command) HasAvailableLocalFlags() bool { + return c.LocalFlags().HasAvailableFlags() +} + +// HasAvailableInheritedFlags checks if the command has flags inherited from its parent command which are +// not hidden or deprecated. +func (c *Command) HasAvailableInheritedFlags() bool { + return c.InheritedFlags().HasAvailableFlags() +} + +// Flag climbs up the command tree looking for matching flag. +func (c *Command) Flag(name string) (flag *flag.Flag) { + flag = c.Flags().Lookup(name) + + if flag == nil { + flag = c.persistentFlag(name) + } + + return +} + +// Recursively find matching persistent flag. +func (c *Command) persistentFlag(name string) (flag *flag.Flag) { + if c.HasPersistentFlags() { + flag = c.PersistentFlags().Lookup(name) + } + + if flag == nil { + c.updateParentsPflags() + flag = c.parentsPflags.Lookup(name) + } + return +} + +// ParseFlags parses persistent flag tree and local flags. +func (c *Command) ParseFlags(args []string) error { + if c.DisableFlagParsing { + return nil + } + + if c.flagErrorBuf == nil { + c.flagErrorBuf = new(bytes.Buffer) + } + beforeErrorBufLen := c.flagErrorBuf.Len() + c.mergePersistentFlags() + + //do it here after merging all flags and just before parse + c.Flags().ParseErrorsWhitelist = flag.ParseErrorsWhitelist(c.FParseErrWhitelist) + + err := c.Flags().Parse(args) + // Print warnings if they occurred (e.g. deprecated flag messages). + if c.flagErrorBuf.Len()-beforeErrorBufLen > 0 && err == nil { + c.Print(c.flagErrorBuf.String()) + } + + return err +} + +// Parent returns a commands parent command. +func (c *Command) Parent() *Command { + return c.parent +} + +// mergePersistentFlags merges c.PersistentFlags() to c.Flags() +// and adds missing persistent flags of all parents. +func (c *Command) mergePersistentFlags() { + c.updateParentsPflags() + c.Flags().AddFlagSet(c.PersistentFlags()) + c.Flags().AddFlagSet(c.parentsPflags) +} + +// updateParentsPflags updates c.parentsPflags by adding +// new persistent flags of all parents. +// If c.parentsPflags == nil, it makes new. +func (c *Command) updateParentsPflags() { + if c.parentsPflags == nil { + c.parentsPflags = flag.NewFlagSet(c.Name(), flag.ContinueOnError) + c.parentsPflags.SetOutput(c.flagErrorBuf) + c.parentsPflags.SortFlags = false + } + + if c.globNormFunc != nil { + c.parentsPflags.SetNormalizeFunc(c.globNormFunc) + } + + c.Root().PersistentFlags().AddFlagSet(flag.CommandLine) + + c.VisitParents(func(parent *Command) { + c.parentsPflags.AddFlagSet(parent.PersistentFlags()) + }) +} diff --git a/vendor/github.com/spf13/cobra/command_notwin.go b/vendor/github.com/spf13/cobra/command_notwin.go new file mode 100644 index 000000000..6159c1cc1 --- /dev/null +++ b/vendor/github.com/spf13/cobra/command_notwin.go @@ -0,0 +1,5 @@ +// +build !windows + +package cobra + +var preExecHookFn func(*Command) diff --git a/vendor/github.com/spf13/cobra/command_win.go b/vendor/github.com/spf13/cobra/command_win.go new file mode 100644 index 000000000..edec728e4 --- /dev/null +++ b/vendor/github.com/spf13/cobra/command_win.go @@ -0,0 +1,20 @@ +// +build windows + +package cobra + +import ( + "os" + "time" + + "github.com/inconshreveable/mousetrap" +) + +var preExecHookFn = preExecHook + +func preExecHook(c *Command) { + if MousetrapHelpText != "" && mousetrap.StartedByExplorer() { + c.Print(MousetrapHelpText) + time.Sleep(5 * time.Second) + os.Exit(1) + } +} diff --git a/vendor/github.com/spf13/cobra/zsh_completions.go b/vendor/github.com/spf13/cobra/zsh_completions.go new file mode 100644 index 000000000..889c22e27 --- /dev/null +++ b/vendor/github.com/spf13/cobra/zsh_completions.go @@ -0,0 +1,126 @@ +package cobra + +import ( + "bytes" + "fmt" + "io" + "os" + "strings" +) + +// GenZshCompletionFile generates zsh completion file. +func (c *Command) GenZshCompletionFile(filename string) error { + outFile, err := os.Create(filename) + if err != nil { + return err + } + defer outFile.Close() + + return c.GenZshCompletion(outFile) +} + +// GenZshCompletion generates a zsh completion file and writes to the passed writer. +func (c *Command) GenZshCompletion(w io.Writer) error { + buf := new(bytes.Buffer) + + writeHeader(buf, c) + maxDepth := maxDepth(c) + writeLevelMapping(buf, maxDepth) + writeLevelCases(buf, maxDepth, c) + + _, err := buf.WriteTo(w) + return err +} + +func writeHeader(w io.Writer, cmd *Command) { + fmt.Fprintf(w, "#compdef %s\n\n", cmd.Name()) +} + +func maxDepth(c *Command) int { + if len(c.Commands()) == 0 { + return 0 + } + maxDepthSub := 0 + for _, s := range c.Commands() { + subDepth := maxDepth(s) + if subDepth > maxDepthSub { + maxDepthSub = subDepth + } + } + return 1 + maxDepthSub +} + +func writeLevelMapping(w io.Writer, numLevels int) { + fmt.Fprintln(w, `_arguments \`) + for i := 1; i <= numLevels; i++ { + fmt.Fprintf(w, ` '%d: :->level%d' \`, i, i) + fmt.Fprintln(w) + } + fmt.Fprintf(w, ` '%d: :%s'`, numLevels+1, "_files") + fmt.Fprintln(w) +} + +func writeLevelCases(w io.Writer, maxDepth int, root *Command) { + fmt.Fprintln(w, "case $state in") + defer fmt.Fprintln(w, "esac") + + for i := 1; i <= maxDepth; i++ { + fmt.Fprintf(w, " level%d)\n", i) + writeLevel(w, root, i) + fmt.Fprintln(w, " ;;") + } + fmt.Fprintln(w, " *)") + fmt.Fprintln(w, " _arguments '*: :_files'") + fmt.Fprintln(w, " ;;") +} + +func writeLevel(w io.Writer, root *Command, i int) { + fmt.Fprintf(w, " case $words[%d] in\n", i) + defer fmt.Fprintln(w, " esac") + + commands := filterByLevel(root, i) + byParent := groupByParent(commands) + + for p, c := range byParent { + names := names(c) + fmt.Fprintf(w, " %s)\n", p) + fmt.Fprintf(w, " _arguments '%d: :(%s)'\n", i, strings.Join(names, " ")) + fmt.Fprintln(w, " ;;") + } + fmt.Fprintln(w, " *)") + fmt.Fprintln(w, " _arguments '*: :_files'") + fmt.Fprintln(w, " ;;") + +} + +func filterByLevel(c *Command, l int) []*Command { + cs := make([]*Command, 0) + if l == 0 { + cs = append(cs, c) + return cs + } + for _, s := range c.Commands() { + cs = append(cs, filterByLevel(s, l-1)...) + } + return cs +} + +func groupByParent(commands []*Command) map[string][]*Command { + m := make(map[string][]*Command) + for _, c := range commands { + parent := c.Parent() + if parent == nil { + continue + } + m[parent.Name()] = append(m[parent.Name()], c) + } + return m +} + +func names(commands []*Command) []string { + ns := make([]string, len(commands)) + for i, c := range commands { + ns[i] = c.Name() + } + return ns +} diff --git a/vendor/github.com/spf13/pflag/.gitignore b/vendor/github.com/spf13/pflag/.gitignore new file mode 100644 index 000000000..c3da29013 --- /dev/null +++ b/vendor/github.com/spf13/pflag/.gitignore @@ -0,0 +1,2 @@ +.idea/* + diff --git a/vendor/github.com/spf13/pflag/.travis.yml b/vendor/github.com/spf13/pflag/.travis.yml new file mode 100644 index 000000000..f8a63b308 --- /dev/null +++ b/vendor/github.com/spf13/pflag/.travis.yml @@ -0,0 +1,21 @@ +sudo: false + +language: go + +go: + - 1.7.3 + - 1.8.1 + - tip + +matrix: + allow_failures: + - go: tip + +install: + - go get github.com/golang/lint/golint + - export PATH=$GOPATH/bin:$PATH + - go install ./... + +script: + - verify/all.sh -v + - go test ./... diff --git a/vendor/github.com/spf13/pflag/LICENSE b/vendor/github.com/spf13/pflag/LICENSE new file mode 100644 index 000000000..63ed1cfea --- /dev/null +++ b/vendor/github.com/spf13/pflag/LICENSE @@ -0,0 +1,28 @@ +Copyright (c) 2012 Alex Ogier. All rights reserved. +Copyright (c) 2012 The Go Authors. All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + + * Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above +copyright notice, this list of conditions and the following disclaimer +in the documentation and/or other materials provided with the +distribution. + * Neither the name of Google Inc. nor the names of its +contributors may be used to endorse or promote products derived from +this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/vendor/github.com/spf13/pflag/README.md b/vendor/github.com/spf13/pflag/README.md new file mode 100644 index 000000000..b052414d1 --- /dev/null +++ b/vendor/github.com/spf13/pflag/README.md @@ -0,0 +1,296 @@ +[![Build Status](https://travis-ci.org/spf13/pflag.svg?branch=master)](https://travis-ci.org/spf13/pflag) +[![Go Report Card](https://goreportcard.com/badge/github.com/spf13/pflag)](https://goreportcard.com/report/github.com/spf13/pflag) +[![GoDoc](https://godoc.org/github.com/spf13/pflag?status.svg)](https://godoc.org/github.com/spf13/pflag) + +## Description + +pflag is a drop-in replacement for Go's flag package, implementing +POSIX/GNU-style --flags. + +pflag is compatible with the [GNU extensions to the POSIX recommendations +for command-line options][1]. For a more precise description, see the +"Command-line flag syntax" section below. + +[1]: http://www.gnu.org/software/libc/manual/html_node/Argument-Syntax.html + +pflag is available under the same style of BSD license as the Go language, +which can be found in the LICENSE file. + +## Installation + +pflag is available using the standard `go get` command. + +Install by running: + + go get github.com/spf13/pflag + +Run tests by running: + + go test github.com/spf13/pflag + +## Usage + +pflag is a drop-in replacement of Go's native flag package. If you import +pflag under the name "flag" then all code should continue to function +with no changes. + +``` go +import flag "github.com/spf13/pflag" +``` + +There is one exception to this: if you directly instantiate the Flag struct +there is one more field "Shorthand" that you will need to set. +Most code never instantiates this struct directly, and instead uses +functions such as String(), BoolVar(), and Var(), and is therefore +unaffected. + +Define flags using flag.String(), Bool(), Int(), etc. + +This declares an integer flag, -flagname, stored in the pointer ip, with type *int. + +``` go +var ip *int = flag.Int("flagname", 1234, "help message for flagname") +``` + +If you like, you can bind the flag to a variable using the Var() functions. + +``` go +var flagvar int +func init() { + flag.IntVar(&flagvar, "flagname", 1234, "help message for flagname") +} +``` + +Or you can create custom flags that satisfy the Value interface (with +pointer receivers) and couple them to flag parsing by + +``` go +flag.Var(&flagVal, "name", "help message for flagname") +``` + +For such flags, the default value is just the initial value of the variable. + +After all flags are defined, call + +``` go +flag.Parse() +``` + +to parse the command line into the defined flags. + +Flags may then be used directly. If you're using the flags themselves, +they are all pointers; if you bind to variables, they're values. + +``` go +fmt.Println("ip has value ", *ip) +fmt.Println("flagvar has value ", flagvar) +``` + +There are helpers function to get values later if you have the FlagSet but +it was difficult to keep up with all of the flag pointers in your code. +If you have a pflag.FlagSet with a flag called 'flagname' of type int you +can use GetInt() to get the int value. But notice that 'flagname' must exist +and it must be an int. GetString("flagname") will fail. + +``` go +i, err := flagset.GetInt("flagname") +``` + +After parsing, the arguments after the flag are available as the +slice flag.Args() or individually as flag.Arg(i). +The arguments are indexed from 0 through flag.NArg()-1. + +The pflag package also defines some new functions that are not in flag, +that give one-letter shorthands for flags. You can use these by appending +'P' to the name of any function that defines a flag. + +``` go +var ip = flag.IntP("flagname", "f", 1234, "help message") +var flagvar bool +func init() { + flag.BoolVarP(&flagvar, "boolname", "b", true, "help message") +} +flag.VarP(&flagVal, "varname", "v", "help message") +``` + +Shorthand letters can be used with single dashes on the command line. +Boolean shorthand flags can be combined with other shorthand flags. + +The default set of command-line flags is controlled by +top-level functions. The FlagSet type allows one to define +independent sets of flags, such as to implement subcommands +in a command-line interface. The methods of FlagSet are +analogous to the top-level functions for the command-line +flag set. + +## Setting no option default values for flags + +After you create a flag it is possible to set the pflag.NoOptDefVal for +the given flag. Doing this changes the meaning of the flag slightly. If +a flag has a NoOptDefVal and the flag is set on the command line without +an option the flag will be set to the NoOptDefVal. For example given: + +``` go +var ip = flag.IntP("flagname", "f", 1234, "help message") +flag.Lookup("flagname").NoOptDefVal = "4321" +``` + +Would result in something like + +| Parsed Arguments | Resulting Value | +| ------------- | ------------- | +| --flagname=1357 | ip=1357 | +| --flagname | ip=4321 | +| [nothing] | ip=1234 | + +## Command line flag syntax + +``` +--flag // boolean flags, or flags with no option default values +--flag x // only on flags without a default value +--flag=x +``` + +Unlike the flag package, a single dash before an option means something +different than a double dash. Single dashes signify a series of shorthand +letters for flags. All but the last shorthand letter must be boolean flags +or a flag with a default value + +``` +// boolean or flags where the 'no option default value' is set +-f +-f=true +-abc +but +-b true is INVALID + +// non-boolean and flags without a 'no option default value' +-n 1234 +-n=1234 +-n1234 + +// mixed +-abcs "hello" +-absd="hello" +-abcs1234 +``` + +Flag parsing stops after the terminator "--". Unlike the flag package, +flags can be interspersed with arguments anywhere on the command line +before this terminator. + +Integer flags accept 1234, 0664, 0x1234 and may be negative. +Boolean flags (in their long form) accept 1, 0, t, f, true, false, +TRUE, FALSE, True, False. +Duration flags accept any input valid for time.ParseDuration. + +## Mutating or "Normalizing" Flag names + +It is possible to set a custom flag name 'normalization function.' It allows flag names to be mutated both when created in the code and when used on the command line to some 'normalized' form. The 'normalized' form is used for comparison. Two examples of using the custom normalization func follow. + +**Example #1**: You want -, _, and . in flags to compare the same. aka --my-flag == --my_flag == --my.flag + +``` go +func wordSepNormalizeFunc(f *pflag.FlagSet, name string) pflag.NormalizedName { + from := []string{"-", "_"} + to := "." + for _, sep := range from { + name = strings.Replace(name, sep, to, -1) + } + return pflag.NormalizedName(name) +} + +myFlagSet.SetNormalizeFunc(wordSepNormalizeFunc) +``` + +**Example #2**: You want to alias two flags. aka --old-flag-name == --new-flag-name + +``` go +func aliasNormalizeFunc(f *pflag.FlagSet, name string) pflag.NormalizedName { + switch name { + case "old-flag-name": + name = "new-flag-name" + break + } + return pflag.NormalizedName(name) +} + +myFlagSet.SetNormalizeFunc(aliasNormalizeFunc) +``` + +## Deprecating a flag or its shorthand +It is possible to deprecate a flag, or just its shorthand. Deprecating a flag/shorthand hides it from help text and prints a usage message when the deprecated flag/shorthand is used. + +**Example #1**: You want to deprecate a flag named "badflag" as well as inform the users what flag they should use instead. +```go +// deprecate a flag by specifying its name and a usage message +flags.MarkDeprecated("badflag", "please use --good-flag instead") +``` +This hides "badflag" from help text, and prints `Flag --badflag has been deprecated, please use --good-flag instead` when "badflag" is used. + +**Example #2**: You want to keep a flag name "noshorthandflag" but deprecate its shortname "n". +```go +// deprecate a flag shorthand by specifying its flag name and a usage message +flags.MarkShorthandDeprecated("noshorthandflag", "please use --noshorthandflag only") +``` +This hides the shortname "n" from help text, and prints `Flag shorthand -n has been deprecated, please use --noshorthandflag only` when the shorthand "n" is used. + +Note that usage message is essential here, and it should not be empty. + +## Hidden flags +It is possible to mark a flag as hidden, meaning it will still function as normal, however will not show up in usage/help text. + +**Example**: You have a flag named "secretFlag" that you need for internal use only and don't want it showing up in help text, or for its usage text to be available. +```go +// hide a flag by specifying its name +flags.MarkHidden("secretFlag") +``` + +## Disable sorting of flags +`pflag` allows you to disable sorting of flags for help and usage message. + +**Example**: +```go +flags.BoolP("verbose", "v", false, "verbose output") +flags.String("coolflag", "yeaah", "it's really cool flag") +flags.Int("usefulflag", 777, "sometimes it's very useful") +flags.SortFlags = false +flags.PrintDefaults() +``` +**Output**: +``` + -v, --verbose verbose output + --coolflag string it's really cool flag (default "yeaah") + --usefulflag int sometimes it's very useful (default 777) +``` + + +## Supporting Go flags when using pflag +In order to support flags defined using Go's `flag` package, they must be added to the `pflag` flagset. This is usually necessary +to support flags defined by third-party dependencies (e.g. `golang/glog`). + +**Example**: You want to add the Go flags to the `CommandLine` flagset +```go +import ( + goflag "flag" + flag "github.com/spf13/pflag" +) + +var ip *int = flag.Int("flagname", 1234, "help message for flagname") + +func main() { + flag.CommandLine.AddGoFlagSet(goflag.CommandLine) + flag.Parse() +} +``` + +## More info + +You can see the full reference documentation of the pflag package +[at godoc.org][3], or through go's standard documentation system by +running `godoc -http=:6060` and browsing to +[http://localhost:6060/pkg/github.com/spf13/pflag][2] after +installation. + +[2]: http://localhost:6060/pkg/github.com/spf13/pflag +[3]: http://godoc.org/github.com/spf13/pflag diff --git a/vendor/github.com/spf13/pflag/bool.go b/vendor/github.com/spf13/pflag/bool.go new file mode 100644 index 000000000..c4c5c0bfd --- /dev/null +++ b/vendor/github.com/spf13/pflag/bool.go @@ -0,0 +1,94 @@ +package pflag + +import "strconv" + +// optional interface to indicate boolean flags that can be +// supplied without "=value" text +type boolFlag interface { + Value + IsBoolFlag() bool +} + +// -- bool Value +type boolValue bool + +func newBoolValue(val bool, p *bool) *boolValue { + *p = val + return (*boolValue)(p) +} + +func (b *boolValue) Set(s string) error { + v, err := strconv.ParseBool(s) + *b = boolValue(v) + return err +} + +func (b *boolValue) Type() string { + return "bool" +} + +func (b *boolValue) String() string { return strconv.FormatBool(bool(*b)) } + +func (b *boolValue) IsBoolFlag() bool { return true } + +func boolConv(sval string) (interface{}, error) { + return strconv.ParseBool(sval) +} + +// GetBool return the bool value of a flag with the given name +func (f *FlagSet) GetBool(name string) (bool, error) { + val, err := f.getFlagType(name, "bool", boolConv) + if err != nil { + return false, err + } + return val.(bool), nil +} + +// BoolVar defines a bool flag with specified name, default value, and usage string. +// The argument p points to a bool variable in which to store the value of the flag. +func (f *FlagSet) BoolVar(p *bool, name string, value bool, usage string) { + f.BoolVarP(p, name, "", value, usage) +} + +// BoolVarP is like BoolVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) BoolVarP(p *bool, name, shorthand string, value bool, usage string) { + flag := f.VarPF(newBoolValue(value, p), name, shorthand, usage) + flag.NoOptDefVal = "true" +} + +// BoolVar defines a bool flag with specified name, default value, and usage string. +// The argument p points to a bool variable in which to store the value of the flag. +func BoolVar(p *bool, name string, value bool, usage string) { + BoolVarP(p, name, "", value, usage) +} + +// BoolVarP is like BoolVar, but accepts a shorthand letter that can be used after a single dash. +func BoolVarP(p *bool, name, shorthand string, value bool, usage string) { + flag := CommandLine.VarPF(newBoolValue(value, p), name, shorthand, usage) + flag.NoOptDefVal = "true" +} + +// Bool defines a bool flag with specified name, default value, and usage string. +// The return value is the address of a bool variable that stores the value of the flag. +func (f *FlagSet) Bool(name string, value bool, usage string) *bool { + return f.BoolP(name, "", value, usage) +} + +// BoolP is like Bool, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) BoolP(name, shorthand string, value bool, usage string) *bool { + p := new(bool) + f.BoolVarP(p, name, shorthand, value, usage) + return p +} + +// Bool defines a bool flag with specified name, default value, and usage string. +// The return value is the address of a bool variable that stores the value of the flag. +func Bool(name string, value bool, usage string) *bool { + return BoolP(name, "", value, usage) +} + +// BoolP is like Bool, but accepts a shorthand letter that can be used after a single dash. +func BoolP(name, shorthand string, value bool, usage string) *bool { + b := CommandLine.BoolP(name, shorthand, value, usage) + return b +} diff --git a/vendor/github.com/spf13/pflag/bool_slice.go b/vendor/github.com/spf13/pflag/bool_slice.go new file mode 100644 index 000000000..5af02f1a7 --- /dev/null +++ b/vendor/github.com/spf13/pflag/bool_slice.go @@ -0,0 +1,147 @@ +package pflag + +import ( + "io" + "strconv" + "strings" +) + +// -- boolSlice Value +type boolSliceValue struct { + value *[]bool + changed bool +} + +func newBoolSliceValue(val []bool, p *[]bool) *boolSliceValue { + bsv := new(boolSliceValue) + bsv.value = p + *bsv.value = val + return bsv +} + +// Set converts, and assigns, the comma-separated boolean argument string representation as the []bool value of this flag. +// If Set is called on a flag that already has a []bool assigned, the newly converted values will be appended. +func (s *boolSliceValue) Set(val string) error { + + // remove all quote characters + rmQuote := strings.NewReplacer(`"`, "", `'`, "", "`", "") + + // read flag arguments with CSV parser + boolStrSlice, err := readAsCSV(rmQuote.Replace(val)) + if err != nil && err != io.EOF { + return err + } + + // parse boolean values into slice + out := make([]bool, 0, len(boolStrSlice)) + for _, boolStr := range boolStrSlice { + b, err := strconv.ParseBool(strings.TrimSpace(boolStr)) + if err != nil { + return err + } + out = append(out, b) + } + + if !s.changed { + *s.value = out + } else { + *s.value = append(*s.value, out...) + } + + s.changed = true + + return nil +} + +// Type returns a string that uniquely represents this flag's type. +func (s *boolSliceValue) Type() string { + return "boolSlice" +} + +// String defines a "native" format for this boolean slice flag value. +func (s *boolSliceValue) String() string { + + boolStrSlice := make([]string, len(*s.value)) + for i, b := range *s.value { + boolStrSlice[i] = strconv.FormatBool(b) + } + + out, _ := writeAsCSV(boolStrSlice) + + return "[" + out + "]" +} + +func boolSliceConv(val string) (interface{}, error) { + val = strings.Trim(val, "[]") + // Empty string would cause a slice with one (empty) entry + if len(val) == 0 { + return []bool{}, nil + } + ss := strings.Split(val, ",") + out := make([]bool, len(ss)) + for i, t := range ss { + var err error + out[i], err = strconv.ParseBool(t) + if err != nil { + return nil, err + } + } + return out, nil +} + +// GetBoolSlice returns the []bool value of a flag with the given name. +func (f *FlagSet) GetBoolSlice(name string) ([]bool, error) { + val, err := f.getFlagType(name, "boolSlice", boolSliceConv) + if err != nil { + return []bool{}, err + } + return val.([]bool), nil +} + +// BoolSliceVar defines a boolSlice flag with specified name, default value, and usage string. +// The argument p points to a []bool variable in which to store the value of the flag. +func (f *FlagSet) BoolSliceVar(p *[]bool, name string, value []bool, usage string) { + f.VarP(newBoolSliceValue(value, p), name, "", usage) +} + +// BoolSliceVarP is like BoolSliceVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) BoolSliceVarP(p *[]bool, name, shorthand string, value []bool, usage string) { + f.VarP(newBoolSliceValue(value, p), name, shorthand, usage) +} + +// BoolSliceVar defines a []bool flag with specified name, default value, and usage string. +// The argument p points to a []bool variable in which to store the value of the flag. +func BoolSliceVar(p *[]bool, name string, value []bool, usage string) { + CommandLine.VarP(newBoolSliceValue(value, p), name, "", usage) +} + +// BoolSliceVarP is like BoolSliceVar, but accepts a shorthand letter that can be used after a single dash. +func BoolSliceVarP(p *[]bool, name, shorthand string, value []bool, usage string) { + CommandLine.VarP(newBoolSliceValue(value, p), name, shorthand, usage) +} + +// BoolSlice defines a []bool flag with specified name, default value, and usage string. +// The return value is the address of a []bool variable that stores the value of the flag. +func (f *FlagSet) BoolSlice(name string, value []bool, usage string) *[]bool { + p := []bool{} + f.BoolSliceVarP(&p, name, "", value, usage) + return &p +} + +// BoolSliceP is like BoolSlice, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) BoolSliceP(name, shorthand string, value []bool, usage string) *[]bool { + p := []bool{} + f.BoolSliceVarP(&p, name, shorthand, value, usage) + return &p +} + +// BoolSlice defines a []bool flag with specified name, default value, and usage string. +// The return value is the address of a []bool variable that stores the value of the flag. +func BoolSlice(name string, value []bool, usage string) *[]bool { + return CommandLine.BoolSliceP(name, "", value, usage) +} + +// BoolSliceP is like BoolSlice, but accepts a shorthand letter that can be used after a single dash. +func BoolSliceP(name, shorthand string, value []bool, usage string) *[]bool { + return CommandLine.BoolSliceP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/bytes.go b/vendor/github.com/spf13/pflag/bytes.go new file mode 100644 index 000000000..12c58db9f --- /dev/null +++ b/vendor/github.com/spf13/pflag/bytes.go @@ -0,0 +1,105 @@ +package pflag + +import ( + "encoding/hex" + "fmt" + "strings" +) + +// BytesHex adapts []byte for use as a flag. Value of flag is HEX encoded +type bytesHexValue []byte + +func (bytesHex bytesHexValue) String() string { + return fmt.Sprintf("%X", []byte(bytesHex)) +} + +func (bytesHex *bytesHexValue) Set(value string) error { + bin, err := hex.DecodeString(strings.TrimSpace(value)) + + if err != nil { + return err + } + + *bytesHex = bin + + return nil +} + +func (*bytesHexValue) Type() string { + return "bytesHex" +} + +func newBytesHexValue(val []byte, p *[]byte) *bytesHexValue { + *p = val + return (*bytesHexValue)(p) +} + +func bytesHexConv(sval string) (interface{}, error) { + + bin, err := hex.DecodeString(sval) + + if err == nil { + return bin, nil + } + + return nil, fmt.Errorf("invalid string being converted to Bytes: %s %s", sval, err) +} + +// GetBytesHex return the []byte value of a flag with the given name +func (f *FlagSet) GetBytesHex(name string) ([]byte, error) { + val, err := f.getFlagType(name, "bytesHex", bytesHexConv) + + if err != nil { + return []byte{}, err + } + + return val.([]byte), nil +} + +// BytesHexVar defines an []byte flag with specified name, default value, and usage string. +// The argument p points to an []byte variable in which to store the value of the flag. +func (f *FlagSet) BytesHexVar(p *[]byte, name string, value []byte, usage string) { + f.VarP(newBytesHexValue(value, p), name, "", usage) +} + +// BytesHexVarP is like BytesHexVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) BytesHexVarP(p *[]byte, name, shorthand string, value []byte, usage string) { + f.VarP(newBytesHexValue(value, p), name, shorthand, usage) +} + +// BytesHexVar defines an []byte flag with specified name, default value, and usage string. +// The argument p points to an []byte variable in which to store the value of the flag. +func BytesHexVar(p *[]byte, name string, value []byte, usage string) { + CommandLine.VarP(newBytesHexValue(value, p), name, "", usage) +} + +// BytesHexVarP is like BytesHexVar, but accepts a shorthand letter that can be used after a single dash. +func BytesHexVarP(p *[]byte, name, shorthand string, value []byte, usage string) { + CommandLine.VarP(newBytesHexValue(value, p), name, shorthand, usage) +} + +// BytesHex defines an []byte flag with specified name, default value, and usage string. +// The return value is the address of an []byte variable that stores the value of the flag. +func (f *FlagSet) BytesHex(name string, value []byte, usage string) *[]byte { + p := new([]byte) + f.BytesHexVarP(p, name, "", value, usage) + return p +} + +// BytesHexP is like BytesHex, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) BytesHexP(name, shorthand string, value []byte, usage string) *[]byte { + p := new([]byte) + f.BytesHexVarP(p, name, shorthand, value, usage) + return p +} + +// BytesHex defines an []byte flag with specified name, default value, and usage string. +// The return value is the address of an []byte variable that stores the value of the flag. +func BytesHex(name string, value []byte, usage string) *[]byte { + return CommandLine.BytesHexP(name, "", value, usage) +} + +// BytesHexP is like BytesHex, but accepts a shorthand letter that can be used after a single dash. +func BytesHexP(name, shorthand string, value []byte, usage string) *[]byte { + return CommandLine.BytesHexP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/count.go b/vendor/github.com/spf13/pflag/count.go new file mode 100644 index 000000000..aa126e44d --- /dev/null +++ b/vendor/github.com/spf13/pflag/count.go @@ -0,0 +1,96 @@ +package pflag + +import "strconv" + +// -- count Value +type countValue int + +func newCountValue(val int, p *int) *countValue { + *p = val + return (*countValue)(p) +} + +func (i *countValue) Set(s string) error { + // "+1" means that no specific value was passed, so increment + if s == "+1" { + *i = countValue(*i + 1) + return nil + } + v, err := strconv.ParseInt(s, 0, 0) + *i = countValue(v) + return err +} + +func (i *countValue) Type() string { + return "count" +} + +func (i *countValue) String() string { return strconv.Itoa(int(*i)) } + +func countConv(sval string) (interface{}, error) { + i, err := strconv.Atoi(sval) + if err != nil { + return nil, err + } + return i, nil +} + +// GetCount return the int value of a flag with the given name +func (f *FlagSet) GetCount(name string) (int, error) { + val, err := f.getFlagType(name, "count", countConv) + if err != nil { + return 0, err + } + return val.(int), nil +} + +// CountVar defines a count flag with specified name, default value, and usage string. +// The argument p points to an int variable in which to store the value of the flag. +// A count flag will add 1 to its value evey time it is found on the command line +func (f *FlagSet) CountVar(p *int, name string, usage string) { + f.CountVarP(p, name, "", usage) +} + +// CountVarP is like CountVar only take a shorthand for the flag name. +func (f *FlagSet) CountVarP(p *int, name, shorthand string, usage string) { + flag := f.VarPF(newCountValue(0, p), name, shorthand, usage) + flag.NoOptDefVal = "+1" +} + +// CountVar like CountVar only the flag is placed on the CommandLine instead of a given flag set +func CountVar(p *int, name string, usage string) { + CommandLine.CountVar(p, name, usage) +} + +// CountVarP is like CountVar only take a shorthand for the flag name. +func CountVarP(p *int, name, shorthand string, usage string) { + CommandLine.CountVarP(p, name, shorthand, usage) +} + +// Count defines a count flag with specified name, default value, and usage string. +// The return value is the address of an int variable that stores the value of the flag. +// A count flag will add 1 to its value evey time it is found on the command line +func (f *FlagSet) Count(name string, usage string) *int { + p := new(int) + f.CountVarP(p, name, "", usage) + return p +} + +// CountP is like Count only takes a shorthand for the flag name. +func (f *FlagSet) CountP(name, shorthand string, usage string) *int { + p := new(int) + f.CountVarP(p, name, shorthand, usage) + return p +} + +// Count defines a count flag with specified name, default value, and usage string. +// The return value is the address of an int variable that stores the value of the flag. +// A count flag will add 1 to its value evey time it is found on the command line +func Count(name string, usage string) *int { + return CommandLine.CountP(name, "", usage) +} + +// CountP is like Count only takes a shorthand for the flag name. +func CountP(name, shorthand string, usage string) *int { + return CommandLine.CountP(name, shorthand, usage) +} diff --git a/vendor/github.com/spf13/pflag/duration.go b/vendor/github.com/spf13/pflag/duration.go new file mode 100644 index 000000000..e9debef88 --- /dev/null +++ b/vendor/github.com/spf13/pflag/duration.go @@ -0,0 +1,86 @@ +package pflag + +import ( + "time" +) + +// -- time.Duration Value +type durationValue time.Duration + +func newDurationValue(val time.Duration, p *time.Duration) *durationValue { + *p = val + return (*durationValue)(p) +} + +func (d *durationValue) Set(s string) error { + v, err := time.ParseDuration(s) + *d = durationValue(v) + return err +} + +func (d *durationValue) Type() string { + return "duration" +} + +func (d *durationValue) String() string { return (*time.Duration)(d).String() } + +func durationConv(sval string) (interface{}, error) { + return time.ParseDuration(sval) +} + +// GetDuration return the duration value of a flag with the given name +func (f *FlagSet) GetDuration(name string) (time.Duration, error) { + val, err := f.getFlagType(name, "duration", durationConv) + if err != nil { + return 0, err + } + return val.(time.Duration), nil +} + +// DurationVar defines a time.Duration flag with specified name, default value, and usage string. +// The argument p points to a time.Duration variable in which to store the value of the flag. +func (f *FlagSet) DurationVar(p *time.Duration, name string, value time.Duration, usage string) { + f.VarP(newDurationValue(value, p), name, "", usage) +} + +// DurationVarP is like DurationVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) DurationVarP(p *time.Duration, name, shorthand string, value time.Duration, usage string) { + f.VarP(newDurationValue(value, p), name, shorthand, usage) +} + +// DurationVar defines a time.Duration flag with specified name, default value, and usage string. +// The argument p points to a time.Duration variable in which to store the value of the flag. +func DurationVar(p *time.Duration, name string, value time.Duration, usage string) { + CommandLine.VarP(newDurationValue(value, p), name, "", usage) +} + +// DurationVarP is like DurationVar, but accepts a shorthand letter that can be used after a single dash. +func DurationVarP(p *time.Duration, name, shorthand string, value time.Duration, usage string) { + CommandLine.VarP(newDurationValue(value, p), name, shorthand, usage) +} + +// Duration defines a time.Duration flag with specified name, default value, and usage string. +// The return value is the address of a time.Duration variable that stores the value of the flag. +func (f *FlagSet) Duration(name string, value time.Duration, usage string) *time.Duration { + p := new(time.Duration) + f.DurationVarP(p, name, "", value, usage) + return p +} + +// DurationP is like Duration, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) DurationP(name, shorthand string, value time.Duration, usage string) *time.Duration { + p := new(time.Duration) + f.DurationVarP(p, name, shorthand, value, usage) + return p +} + +// Duration defines a time.Duration flag with specified name, default value, and usage string. +// The return value is the address of a time.Duration variable that stores the value of the flag. +func Duration(name string, value time.Duration, usage string) *time.Duration { + return CommandLine.DurationP(name, "", value, usage) +} + +// DurationP is like Duration, but accepts a shorthand letter that can be used after a single dash. +func DurationP(name, shorthand string, value time.Duration, usage string) *time.Duration { + return CommandLine.DurationP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/duration_slice.go b/vendor/github.com/spf13/pflag/duration_slice.go new file mode 100644 index 000000000..52c6b6dc1 --- /dev/null +++ b/vendor/github.com/spf13/pflag/duration_slice.go @@ -0,0 +1,128 @@ +package pflag + +import ( + "fmt" + "strings" + "time" +) + +// -- durationSlice Value +type durationSliceValue struct { + value *[]time.Duration + changed bool +} + +func newDurationSliceValue(val []time.Duration, p *[]time.Duration) *durationSliceValue { + dsv := new(durationSliceValue) + dsv.value = p + *dsv.value = val + return dsv +} + +func (s *durationSliceValue) Set(val string) error { + ss := strings.Split(val, ",") + out := make([]time.Duration, len(ss)) + for i, d := range ss { + var err error + out[i], err = time.ParseDuration(d) + if err != nil { + return err + } + + } + if !s.changed { + *s.value = out + } else { + *s.value = append(*s.value, out...) + } + s.changed = true + return nil +} + +func (s *durationSliceValue) Type() string { + return "durationSlice" +} + +func (s *durationSliceValue) String() string { + out := make([]string, len(*s.value)) + for i, d := range *s.value { + out[i] = fmt.Sprintf("%s", d) + } + return "[" + strings.Join(out, ",") + "]" +} + +func durationSliceConv(val string) (interface{}, error) { + val = strings.Trim(val, "[]") + // Empty string would cause a slice with one (empty) entry + if len(val) == 0 { + return []time.Duration{}, nil + } + ss := strings.Split(val, ",") + out := make([]time.Duration, len(ss)) + for i, d := range ss { + var err error + out[i], err = time.ParseDuration(d) + if err != nil { + return nil, err + } + + } + return out, nil +} + +// GetDurationSlice returns the []time.Duration value of a flag with the given name +func (f *FlagSet) GetDurationSlice(name string) ([]time.Duration, error) { + val, err := f.getFlagType(name, "durationSlice", durationSliceConv) + if err != nil { + return []time.Duration{}, err + } + return val.([]time.Duration), nil +} + +// DurationSliceVar defines a durationSlice flag with specified name, default value, and usage string. +// The argument p points to a []time.Duration variable in which to store the value of the flag. +func (f *FlagSet) DurationSliceVar(p *[]time.Duration, name string, value []time.Duration, usage string) { + f.VarP(newDurationSliceValue(value, p), name, "", usage) +} + +// DurationSliceVarP is like DurationSliceVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) DurationSliceVarP(p *[]time.Duration, name, shorthand string, value []time.Duration, usage string) { + f.VarP(newDurationSliceValue(value, p), name, shorthand, usage) +} + +// DurationSliceVar defines a duration[] flag with specified name, default value, and usage string. +// The argument p points to a duration[] variable in which to store the value of the flag. +func DurationSliceVar(p *[]time.Duration, name string, value []time.Duration, usage string) { + CommandLine.VarP(newDurationSliceValue(value, p), name, "", usage) +} + +// DurationSliceVarP is like DurationSliceVar, but accepts a shorthand letter that can be used after a single dash. +func DurationSliceVarP(p *[]time.Duration, name, shorthand string, value []time.Duration, usage string) { + CommandLine.VarP(newDurationSliceValue(value, p), name, shorthand, usage) +} + +// DurationSlice defines a []time.Duration flag with specified name, default value, and usage string. +// The return value is the address of a []time.Duration variable that stores the value of the flag. +func (f *FlagSet) DurationSlice(name string, value []time.Duration, usage string) *[]time.Duration { + p := []time.Duration{} + f.DurationSliceVarP(&p, name, "", value, usage) + return &p +} + +// DurationSliceP is like DurationSlice, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) DurationSliceP(name, shorthand string, value []time.Duration, usage string) *[]time.Duration { + p := []time.Duration{} + f.DurationSliceVarP(&p, name, shorthand, value, usage) + return &p +} + +// DurationSlice defines a []time.Duration flag with specified name, default value, and usage string. +// The return value is the address of a []time.Duration variable that stores the value of the flag. +func DurationSlice(name string, value []time.Duration, usage string) *[]time.Duration { + return CommandLine.DurationSliceP(name, "", value, usage) +} + +// DurationSliceP is like DurationSlice, but accepts a shorthand letter that can be used after a single dash. +func DurationSliceP(name, shorthand string, value []time.Duration, usage string) *[]time.Duration { + return CommandLine.DurationSliceP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/flag.go b/vendor/github.com/spf13/pflag/flag.go new file mode 100644 index 000000000..5eadc84e3 --- /dev/null +++ b/vendor/github.com/spf13/pflag/flag.go @@ -0,0 +1,1223 @@ +// Copyright 2009 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +/* +Package pflag is a drop-in replacement for Go's flag package, implementing +POSIX/GNU-style --flags. + +pflag is compatible with the GNU extensions to the POSIX recommendations +for command-line options. See +http://www.gnu.org/software/libc/manual/html_node/Argument-Syntax.html + +Usage: + +pflag is a drop-in replacement of Go's native flag package. If you import +pflag under the name "flag" then all code should continue to function +with no changes. + + import flag "github.com/spf13/pflag" + +There is one exception to this: if you directly instantiate the Flag struct +there is one more field "Shorthand" that you will need to set. +Most code never instantiates this struct directly, and instead uses +functions such as String(), BoolVar(), and Var(), and is therefore +unaffected. + +Define flags using flag.String(), Bool(), Int(), etc. + +This declares an integer flag, -flagname, stored in the pointer ip, with type *int. + var ip = flag.Int("flagname", 1234, "help message for flagname") +If you like, you can bind the flag to a variable using the Var() functions. + var flagvar int + func init() { + flag.IntVar(&flagvar, "flagname", 1234, "help message for flagname") + } +Or you can create custom flags that satisfy the Value interface (with +pointer receivers) and couple them to flag parsing by + flag.Var(&flagVal, "name", "help message for flagname") +For such flags, the default value is just the initial value of the variable. + +After all flags are defined, call + flag.Parse() +to parse the command line into the defined flags. + +Flags may then be used directly. If you're using the flags themselves, +they are all pointers; if you bind to variables, they're values. + fmt.Println("ip has value ", *ip) + fmt.Println("flagvar has value ", flagvar) + +After parsing, the arguments after the flag are available as the +slice flag.Args() or individually as flag.Arg(i). +The arguments are indexed from 0 through flag.NArg()-1. + +The pflag package also defines some new functions that are not in flag, +that give one-letter shorthands for flags. You can use these by appending +'P' to the name of any function that defines a flag. + var ip = flag.IntP("flagname", "f", 1234, "help message") + var flagvar bool + func init() { + flag.BoolVarP("boolname", "b", true, "help message") + } + flag.VarP(&flagVar, "varname", "v", 1234, "help message") +Shorthand letters can be used with single dashes on the command line. +Boolean shorthand flags can be combined with other shorthand flags. + +Command line flag syntax: + --flag // boolean flags only + --flag=x + +Unlike the flag package, a single dash before an option means something +different than a double dash. Single dashes signify a series of shorthand +letters for flags. All but the last shorthand letter must be boolean flags. + // boolean flags + -f + -abc + // non-boolean flags + -n 1234 + -Ifile + // mixed + -abcs "hello" + -abcn1234 + +Flag parsing stops after the terminator "--". Unlike the flag package, +flags can be interspersed with arguments anywhere on the command line +before this terminator. + +Integer flags accept 1234, 0664, 0x1234 and may be negative. +Boolean flags (in their long form) accept 1, 0, t, f, true, false, +TRUE, FALSE, True, False. +Duration flags accept any input valid for time.ParseDuration. + +The default set of command-line flags is controlled by +top-level functions. The FlagSet type allows one to define +independent sets of flags, such as to implement subcommands +in a command-line interface. The methods of FlagSet are +analogous to the top-level functions for the command-line +flag set. +*/ +package pflag + +import ( + "bytes" + "errors" + goflag "flag" + "fmt" + "io" + "os" + "sort" + "strings" +) + +// ErrHelp is the error returned if the flag -help is invoked but no such flag is defined. +var ErrHelp = errors.New("pflag: help requested") + +// ErrorHandling defines how to handle flag parsing errors. +type ErrorHandling int + +const ( + // ContinueOnError will return an err from Parse() if an error is found + ContinueOnError ErrorHandling = iota + // ExitOnError will call os.Exit(2) if an error is found when parsing + ExitOnError + // PanicOnError will panic() if an error is found when parsing flags + PanicOnError +) + +// ParseErrorsWhitelist defines the parsing errors that can be ignored +type ParseErrorsWhitelist struct { + // UnknownFlags will ignore unknown flags errors and continue parsing rest of the flags + UnknownFlags bool +} + +// NormalizedName is a flag name that has been normalized according to rules +// for the FlagSet (e.g. making '-' and '_' equivalent). +type NormalizedName string + +// A FlagSet represents a set of defined flags. +type FlagSet struct { + // Usage is the function called when an error occurs while parsing flags. + // The field is a function (not a method) that may be changed to point to + // a custom error handler. + Usage func() + + // SortFlags is used to indicate, if user wants to have sorted flags in + // help/usage messages. + SortFlags bool + + // ParseErrorsWhitelist is used to configure a whitelist of errors + ParseErrorsWhitelist ParseErrorsWhitelist + + name string + parsed bool + actual map[NormalizedName]*Flag + orderedActual []*Flag + sortedActual []*Flag + formal map[NormalizedName]*Flag + orderedFormal []*Flag + sortedFormal []*Flag + shorthands map[byte]*Flag + args []string // arguments after flags + argsLenAtDash int // len(args) when a '--' was located when parsing, or -1 if no -- + errorHandling ErrorHandling + output io.Writer // nil means stderr; use out() accessor + interspersed bool // allow interspersed option/non-option args + normalizeNameFunc func(f *FlagSet, name string) NormalizedName + + addedGoFlagSets []*goflag.FlagSet +} + +// A Flag represents the state of a flag. +type Flag struct { + Name string // name as it appears on command line + Shorthand string // one-letter abbreviated flag + Usage string // help message + Value Value // value as set + DefValue string // default value (as text); for usage message + Changed bool // If the user set the value (or if left to default) + NoOptDefVal string // default value (as text); if the flag is on the command line without any options + Deprecated string // If this flag is deprecated, this string is the new or now thing to use + Hidden bool // used by cobra.Command to allow flags to be hidden from help/usage text + ShorthandDeprecated string // If the shorthand of this flag is deprecated, this string is the new or now thing to use + Annotations map[string][]string // used by cobra.Command bash autocomple code +} + +// Value is the interface to the dynamic value stored in a flag. +// (The default value is represented as a string.) +type Value interface { + String() string + Set(string) error + Type() string +} + +// sortFlags returns the flags as a slice in lexicographical sorted order. +func sortFlags(flags map[NormalizedName]*Flag) []*Flag { + list := make(sort.StringSlice, len(flags)) + i := 0 + for k := range flags { + list[i] = string(k) + i++ + } + list.Sort() + result := make([]*Flag, len(list)) + for i, name := range list { + result[i] = flags[NormalizedName(name)] + } + return result +} + +// SetNormalizeFunc allows you to add a function which can translate flag names. +// Flags added to the FlagSet will be translated and then when anything tries to +// look up the flag that will also be translated. So it would be possible to create +// a flag named "getURL" and have it translated to "geturl". A user could then pass +// "--getUrl" which may also be translated to "geturl" and everything will work. +func (f *FlagSet) SetNormalizeFunc(n func(f *FlagSet, name string) NormalizedName) { + f.normalizeNameFunc = n + f.sortedFormal = f.sortedFormal[:0] + for fname, flag := range f.formal { + nname := f.normalizeFlagName(flag.Name) + if fname == nname { + continue + } + flag.Name = string(nname) + delete(f.formal, fname) + f.formal[nname] = flag + if _, set := f.actual[fname]; set { + delete(f.actual, fname) + f.actual[nname] = flag + } + } +} + +// GetNormalizeFunc returns the previously set NormalizeFunc of a function which +// does no translation, if not set previously. +func (f *FlagSet) GetNormalizeFunc() func(f *FlagSet, name string) NormalizedName { + if f.normalizeNameFunc != nil { + return f.normalizeNameFunc + } + return func(f *FlagSet, name string) NormalizedName { return NormalizedName(name) } +} + +func (f *FlagSet) normalizeFlagName(name string) NormalizedName { + n := f.GetNormalizeFunc() + return n(f, name) +} + +func (f *FlagSet) out() io.Writer { + if f.output == nil { + return os.Stderr + } + return f.output +} + +// SetOutput sets the destination for usage and error messages. +// If output is nil, os.Stderr is used. +func (f *FlagSet) SetOutput(output io.Writer) { + f.output = output +} + +// VisitAll visits the flags in lexicographical order or +// in primordial order if f.SortFlags is false, calling fn for each. +// It visits all flags, even those not set. +func (f *FlagSet) VisitAll(fn func(*Flag)) { + if len(f.formal) == 0 { + return + } + + var flags []*Flag + if f.SortFlags { + if len(f.formal) != len(f.sortedFormal) { + f.sortedFormal = sortFlags(f.formal) + } + flags = f.sortedFormal + } else { + flags = f.orderedFormal + } + + for _, flag := range flags { + fn(flag) + } +} + +// HasFlags returns a bool to indicate if the FlagSet has any flags defined. +func (f *FlagSet) HasFlags() bool { + return len(f.formal) > 0 +} + +// HasAvailableFlags returns a bool to indicate if the FlagSet has any flags +// that are not hidden. +func (f *FlagSet) HasAvailableFlags() bool { + for _, flag := range f.formal { + if !flag.Hidden { + return true + } + } + return false +} + +// VisitAll visits the command-line flags in lexicographical order or +// in primordial order if f.SortFlags is false, calling fn for each. +// It visits all flags, even those not set. +func VisitAll(fn func(*Flag)) { + CommandLine.VisitAll(fn) +} + +// Visit visits the flags in lexicographical order or +// in primordial order if f.SortFlags is false, calling fn for each. +// It visits only those flags that have been set. +func (f *FlagSet) Visit(fn func(*Flag)) { + if len(f.actual) == 0 { + return + } + + var flags []*Flag + if f.SortFlags { + if len(f.actual) != len(f.sortedActual) { + f.sortedActual = sortFlags(f.actual) + } + flags = f.sortedActual + } else { + flags = f.orderedActual + } + + for _, flag := range flags { + fn(flag) + } +} + +// Visit visits the command-line flags in lexicographical order or +// in primordial order if f.SortFlags is false, calling fn for each. +// It visits only those flags that have been set. +func Visit(fn func(*Flag)) { + CommandLine.Visit(fn) +} + +// Lookup returns the Flag structure of the named flag, returning nil if none exists. +func (f *FlagSet) Lookup(name string) *Flag { + return f.lookup(f.normalizeFlagName(name)) +} + +// ShorthandLookup returns the Flag structure of the short handed flag, +// returning nil if none exists. +// It panics, if len(name) > 1. +func (f *FlagSet) ShorthandLookup(name string) *Flag { + if name == "" { + return nil + } + if len(name) > 1 { + msg := fmt.Sprintf("can not look up shorthand which is more than one ASCII character: %q", name) + fmt.Fprintf(f.out(), msg) + panic(msg) + } + c := name[0] + return f.shorthands[c] +} + +// lookup returns the Flag structure of the named flag, returning nil if none exists. +func (f *FlagSet) lookup(name NormalizedName) *Flag { + return f.formal[name] +} + +// func to return a given type for a given flag name +func (f *FlagSet) getFlagType(name string, ftype string, convFunc func(sval string) (interface{}, error)) (interface{}, error) { + flag := f.Lookup(name) + if flag == nil { + err := fmt.Errorf("flag accessed but not defined: %s", name) + return nil, err + } + + if flag.Value.Type() != ftype { + err := fmt.Errorf("trying to get %s value of flag of type %s", ftype, flag.Value.Type()) + return nil, err + } + + sval := flag.Value.String() + result, err := convFunc(sval) + if err != nil { + return nil, err + } + return result, nil +} + +// ArgsLenAtDash will return the length of f.Args at the moment when a -- was +// found during arg parsing. This allows your program to know which args were +// before the -- and which came after. +func (f *FlagSet) ArgsLenAtDash() int { + return f.argsLenAtDash +} + +// MarkDeprecated indicated that a flag is deprecated in your program. It will +// continue to function but will not show up in help or usage messages. Using +// this flag will also print the given usageMessage. +func (f *FlagSet) MarkDeprecated(name string, usageMessage string) error { + flag := f.Lookup(name) + if flag == nil { + return fmt.Errorf("flag %q does not exist", name) + } + if usageMessage == "" { + return fmt.Errorf("deprecated message for flag %q must be set", name) + } + flag.Deprecated = usageMessage + flag.Hidden = true + return nil +} + +// MarkShorthandDeprecated will mark the shorthand of a flag deprecated in your +// program. It will continue to function but will not show up in help or usage +// messages. Using this flag will also print the given usageMessage. +func (f *FlagSet) MarkShorthandDeprecated(name string, usageMessage string) error { + flag := f.Lookup(name) + if flag == nil { + return fmt.Errorf("flag %q does not exist", name) + } + if usageMessage == "" { + return fmt.Errorf("deprecated message for flag %q must be set", name) + } + flag.ShorthandDeprecated = usageMessage + return nil +} + +// MarkHidden sets a flag to 'hidden' in your program. It will continue to +// function but will not show up in help or usage messages. +func (f *FlagSet) MarkHidden(name string) error { + flag := f.Lookup(name) + if flag == nil { + return fmt.Errorf("flag %q does not exist", name) + } + flag.Hidden = true + return nil +} + +// Lookup returns the Flag structure of the named command-line flag, +// returning nil if none exists. +func Lookup(name string) *Flag { + return CommandLine.Lookup(name) +} + +// ShorthandLookup returns the Flag structure of the short handed flag, +// returning nil if none exists. +func ShorthandLookup(name string) *Flag { + return CommandLine.ShorthandLookup(name) +} + +// Set sets the value of the named flag. +func (f *FlagSet) Set(name, value string) error { + normalName := f.normalizeFlagName(name) + flag, ok := f.formal[normalName] + if !ok { + return fmt.Errorf("no such flag -%v", name) + } + + err := flag.Value.Set(value) + if err != nil { + var flagName string + if flag.Shorthand != "" && flag.ShorthandDeprecated == "" { + flagName = fmt.Sprintf("-%s, --%s", flag.Shorthand, flag.Name) + } else { + flagName = fmt.Sprintf("--%s", flag.Name) + } + return fmt.Errorf("invalid argument %q for %q flag: %v", value, flagName, err) + } + + if !flag.Changed { + if f.actual == nil { + f.actual = make(map[NormalizedName]*Flag) + } + f.actual[normalName] = flag + f.orderedActual = append(f.orderedActual, flag) + + flag.Changed = true + } + + if flag.Deprecated != "" { + fmt.Fprintf(f.out(), "Flag --%s has been deprecated, %s\n", flag.Name, flag.Deprecated) + } + return nil +} + +// SetAnnotation allows one to set arbitrary annotations on a flag in the FlagSet. +// This is sometimes used by spf13/cobra programs which want to generate additional +// bash completion information. +func (f *FlagSet) SetAnnotation(name, key string, values []string) error { + normalName := f.normalizeFlagName(name) + flag, ok := f.formal[normalName] + if !ok { + return fmt.Errorf("no such flag -%v", name) + } + if flag.Annotations == nil { + flag.Annotations = map[string][]string{} + } + flag.Annotations[key] = values + return nil +} + +// Changed returns true if the flag was explicitly set during Parse() and false +// otherwise +func (f *FlagSet) Changed(name string) bool { + flag := f.Lookup(name) + // If a flag doesn't exist, it wasn't changed.... + if flag == nil { + return false + } + return flag.Changed +} + +// Set sets the value of the named command-line flag. +func Set(name, value string) error { + return CommandLine.Set(name, value) +} + +// PrintDefaults prints, to standard error unless configured +// otherwise, the default values of all defined flags in the set. +func (f *FlagSet) PrintDefaults() { + usages := f.FlagUsages() + fmt.Fprint(f.out(), usages) +} + +// defaultIsZeroValue returns true if the default value for this flag represents +// a zero value. +func (f *Flag) defaultIsZeroValue() bool { + switch f.Value.(type) { + case boolFlag: + return f.DefValue == "false" + case *durationValue: + // Beginning in Go 1.7, duration zero values are "0s" + return f.DefValue == "0" || f.DefValue == "0s" + case *intValue, *int8Value, *int32Value, *int64Value, *uintValue, *uint8Value, *uint16Value, *uint32Value, *uint64Value, *countValue, *float32Value, *float64Value: + return f.DefValue == "0" + case *stringValue: + return f.DefValue == "" + case *ipValue, *ipMaskValue, *ipNetValue: + return f.DefValue == "" + case *intSliceValue, *stringSliceValue, *stringArrayValue: + return f.DefValue == "[]" + default: + switch f.Value.String() { + case "false": + return true + case "": + return true + case "": + return true + case "0": + return true + } + return false + } +} + +// UnquoteUsage extracts a back-quoted name from the usage +// string for a flag and returns it and the un-quoted usage. +// Given "a `name` to show" it returns ("name", "a name to show"). +// If there are no back quotes, the name is an educated guess of the +// type of the flag's value, or the empty string if the flag is boolean. +func UnquoteUsage(flag *Flag) (name string, usage string) { + // Look for a back-quoted name, but avoid the strings package. + usage = flag.Usage + for i := 0; i < len(usage); i++ { + if usage[i] == '`' { + for j := i + 1; j < len(usage); j++ { + if usage[j] == '`' { + name = usage[i+1 : j] + usage = usage[:i] + name + usage[j+1:] + return name, usage + } + } + break // Only one back quote; use type name. + } + } + + name = flag.Value.Type() + switch name { + case "bool": + name = "" + case "float64": + name = "float" + case "int64": + name = "int" + case "uint64": + name = "uint" + case "stringSlice": + name = "strings" + case "intSlice": + name = "ints" + case "uintSlice": + name = "uints" + case "boolSlice": + name = "bools" + } + + return +} + +// Splits the string `s` on whitespace into an initial substring up to +// `i` runes in length and the remainder. Will go `slop` over `i` if +// that encompasses the entire string (which allows the caller to +// avoid short orphan words on the final line). +func wrapN(i, slop int, s string) (string, string) { + if i+slop > len(s) { + return s, "" + } + + w := strings.LastIndexAny(s[:i], " \t\n") + if w <= 0 { + return s, "" + } + nlPos := strings.LastIndex(s[:i], "\n") + if nlPos > 0 && nlPos < w { + return s[:nlPos], s[nlPos+1:] + } + return s[:w], s[w+1:] +} + +// Wraps the string `s` to a maximum width `w` with leading indent +// `i`. The first line is not indented (this is assumed to be done by +// caller). Pass `w` == 0 to do no wrapping +func wrap(i, w int, s string) string { + if w == 0 { + return strings.Replace(s, "\n", "\n"+strings.Repeat(" ", i), -1) + } + + // space between indent i and end of line width w into which + // we should wrap the text. + wrap := w - i + + var r, l string + + // Not enough space for sensible wrapping. Wrap as a block on + // the next line instead. + if wrap < 24 { + i = 16 + wrap = w - i + r += "\n" + strings.Repeat(" ", i) + } + // If still not enough space then don't even try to wrap. + if wrap < 24 { + return strings.Replace(s, "\n", r, -1) + } + + // Try to avoid short orphan words on the final line, by + // allowing wrapN to go a bit over if that would fit in the + // remainder of the line. + slop := 5 + wrap = wrap - slop + + // Handle first line, which is indented by the caller (or the + // special case above) + l, s = wrapN(wrap, slop, s) + r = r + strings.Replace(l, "\n", "\n"+strings.Repeat(" ", i), -1) + + // Now wrap the rest + for s != "" { + var t string + + t, s = wrapN(wrap, slop, s) + r = r + "\n" + strings.Repeat(" ", i) + strings.Replace(t, "\n", "\n"+strings.Repeat(" ", i), -1) + } + + return r + +} + +// FlagUsagesWrapped returns a string containing the usage information +// for all flags in the FlagSet. Wrapped to `cols` columns (0 for no +// wrapping) +func (f *FlagSet) FlagUsagesWrapped(cols int) string { + buf := new(bytes.Buffer) + + lines := make([]string, 0, len(f.formal)) + + maxlen := 0 + f.VisitAll(func(flag *Flag) { + if flag.Hidden { + return + } + + line := "" + if flag.Shorthand != "" && flag.ShorthandDeprecated == "" { + line = fmt.Sprintf(" -%s, --%s", flag.Shorthand, flag.Name) + } else { + line = fmt.Sprintf(" --%s", flag.Name) + } + + varname, usage := UnquoteUsage(flag) + if varname != "" { + line += " " + varname + } + if flag.NoOptDefVal != "" { + switch flag.Value.Type() { + case "string": + line += fmt.Sprintf("[=\"%s\"]", flag.NoOptDefVal) + case "bool": + if flag.NoOptDefVal != "true" { + line += fmt.Sprintf("[=%s]", flag.NoOptDefVal) + } + case "count": + if flag.NoOptDefVal != "+1" { + line += fmt.Sprintf("[=%s]", flag.NoOptDefVal) + } + default: + line += fmt.Sprintf("[=%s]", flag.NoOptDefVal) + } + } + + // This special character will be replaced with spacing once the + // correct alignment is calculated + line += "\x00" + if len(line) > maxlen { + maxlen = len(line) + } + + line += usage + if !flag.defaultIsZeroValue() { + if flag.Value.Type() == "string" { + line += fmt.Sprintf(" (default %q)", flag.DefValue) + } else { + line += fmt.Sprintf(" (default %s)", flag.DefValue) + } + } + if len(flag.Deprecated) != 0 { + line += fmt.Sprintf(" (DEPRECATED: %s)", flag.Deprecated) + } + + lines = append(lines, line) + }) + + for _, line := range lines { + sidx := strings.Index(line, "\x00") + spacing := strings.Repeat(" ", maxlen-sidx) + // maxlen + 2 comes from + 1 for the \x00 and + 1 for the (deliberate) off-by-one in maxlen-sidx + fmt.Fprintln(buf, line[:sidx], spacing, wrap(maxlen+2, cols, line[sidx+1:])) + } + + return buf.String() +} + +// FlagUsages returns a string containing the usage information for all flags in +// the FlagSet +func (f *FlagSet) FlagUsages() string { + return f.FlagUsagesWrapped(0) +} + +// PrintDefaults prints to standard error the default values of all defined command-line flags. +func PrintDefaults() { + CommandLine.PrintDefaults() +} + +// defaultUsage is the default function to print a usage message. +func defaultUsage(f *FlagSet) { + fmt.Fprintf(f.out(), "Usage of %s:\n", f.name) + f.PrintDefaults() +} + +// NOTE: Usage is not just defaultUsage(CommandLine) +// because it serves (via godoc flag Usage) as the example +// for how to write your own usage function. + +// Usage prints to standard error a usage message documenting all defined command-line flags. +// The function is a variable that may be changed to point to a custom function. +// By default it prints a simple header and calls PrintDefaults; for details about the +// format of the output and how to control it, see the documentation for PrintDefaults. +var Usage = func() { + fmt.Fprintf(os.Stderr, "Usage of %s:\n", os.Args[0]) + PrintDefaults() +} + +// NFlag returns the number of flags that have been set. +func (f *FlagSet) NFlag() int { return len(f.actual) } + +// NFlag returns the number of command-line flags that have been set. +func NFlag() int { return len(CommandLine.actual) } + +// Arg returns the i'th argument. Arg(0) is the first remaining argument +// after flags have been processed. +func (f *FlagSet) Arg(i int) string { + if i < 0 || i >= len(f.args) { + return "" + } + return f.args[i] +} + +// Arg returns the i'th command-line argument. Arg(0) is the first remaining argument +// after flags have been processed. +func Arg(i int) string { + return CommandLine.Arg(i) +} + +// NArg is the number of arguments remaining after flags have been processed. +func (f *FlagSet) NArg() int { return len(f.args) } + +// NArg is the number of arguments remaining after flags have been processed. +func NArg() int { return len(CommandLine.args) } + +// Args returns the non-flag arguments. +func (f *FlagSet) Args() []string { return f.args } + +// Args returns the non-flag command-line arguments. +func Args() []string { return CommandLine.args } + +// Var defines a flag with the specified name and usage string. The type and +// value of the flag are represented by the first argument, of type Value, which +// typically holds a user-defined implementation of Value. For instance, the +// caller could create a flag that turns a comma-separated string into a slice +// of strings by giving the slice the methods of Value; in particular, Set would +// decompose the comma-separated string into the slice. +func (f *FlagSet) Var(value Value, name string, usage string) { + f.VarP(value, name, "", usage) +} + +// VarPF is like VarP, but returns the flag created +func (f *FlagSet) VarPF(value Value, name, shorthand, usage string) *Flag { + // Remember the default value as a string; it won't change. + flag := &Flag{ + Name: name, + Shorthand: shorthand, + Usage: usage, + Value: value, + DefValue: value.String(), + } + f.AddFlag(flag) + return flag +} + +// VarP is like Var, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) VarP(value Value, name, shorthand, usage string) { + f.VarPF(value, name, shorthand, usage) +} + +// AddFlag will add the flag to the FlagSet +func (f *FlagSet) AddFlag(flag *Flag) { + normalizedFlagName := f.normalizeFlagName(flag.Name) + + _, alreadyThere := f.formal[normalizedFlagName] + if alreadyThere { + msg := fmt.Sprintf("%s flag redefined: %s", f.name, flag.Name) + fmt.Fprintln(f.out(), msg) + panic(msg) // Happens only if flags are declared with identical names + } + if f.formal == nil { + f.formal = make(map[NormalizedName]*Flag) + } + + flag.Name = string(normalizedFlagName) + f.formal[normalizedFlagName] = flag + f.orderedFormal = append(f.orderedFormal, flag) + + if flag.Shorthand == "" { + return + } + if len(flag.Shorthand) > 1 { + msg := fmt.Sprintf("%q shorthand is more than one ASCII character", flag.Shorthand) + fmt.Fprintf(f.out(), msg) + panic(msg) + } + if f.shorthands == nil { + f.shorthands = make(map[byte]*Flag) + } + c := flag.Shorthand[0] + used, alreadyThere := f.shorthands[c] + if alreadyThere { + msg := fmt.Sprintf("unable to redefine %q shorthand in %q flagset: it's already used for %q flag", c, f.name, used.Name) + fmt.Fprintf(f.out(), msg) + panic(msg) + } + f.shorthands[c] = flag +} + +// AddFlagSet adds one FlagSet to another. If a flag is already present in f +// the flag from newSet will be ignored. +func (f *FlagSet) AddFlagSet(newSet *FlagSet) { + if newSet == nil { + return + } + newSet.VisitAll(func(flag *Flag) { + if f.Lookup(flag.Name) == nil { + f.AddFlag(flag) + } + }) +} + +// Var defines a flag with the specified name and usage string. The type and +// value of the flag are represented by the first argument, of type Value, which +// typically holds a user-defined implementation of Value. For instance, the +// caller could create a flag that turns a comma-separated string into a slice +// of strings by giving the slice the methods of Value; in particular, Set would +// decompose the comma-separated string into the slice. +func Var(value Value, name string, usage string) { + CommandLine.VarP(value, name, "", usage) +} + +// VarP is like Var, but accepts a shorthand letter that can be used after a single dash. +func VarP(value Value, name, shorthand, usage string) { + CommandLine.VarP(value, name, shorthand, usage) +} + +// failf prints to standard error a formatted error and usage message and +// returns the error. +func (f *FlagSet) failf(format string, a ...interface{}) error { + err := fmt.Errorf(format, a...) + if f.errorHandling != ContinueOnError { + fmt.Fprintln(f.out(), err) + f.usage() + } + return err +} + +// usage calls the Usage method for the flag set, or the usage function if +// the flag set is CommandLine. +func (f *FlagSet) usage() { + if f == CommandLine { + Usage() + } else if f.Usage == nil { + defaultUsage(f) + } else { + f.Usage() + } +} + +//--unknown (args will be empty) +//--unknown --next-flag ... (args will be --next-flag ...) +//--unknown arg ... (args will be arg ...) +func stripUnknownFlagValue(args []string) []string { + if len(args) == 0 { + //--unknown + return args + } + + first := args[0] + if first[0] == '-' { + //--unknown --next-flag ... + return args + } + + //--unknown arg ... (args will be arg ...) + return args[1:] +} + +func (f *FlagSet) parseLongArg(s string, args []string, fn parseFunc) (a []string, err error) { + a = args + name := s[2:] + if len(name) == 0 || name[0] == '-' || name[0] == '=' { + err = f.failf("bad flag syntax: %s", s) + return + } + + split := strings.SplitN(name, "=", 2) + name = split[0] + flag, exists := f.formal[f.normalizeFlagName(name)] + + if !exists { + switch { + case name == "help": + f.usage() + return a, ErrHelp + case f.ParseErrorsWhitelist.UnknownFlags: + // --unknown=unknownval arg ... + // we do not want to lose arg in this case + if len(split) >= 2 { + return a, nil + } + + return stripUnknownFlagValue(a), nil + default: + err = f.failf("unknown flag: --%s", name) + return + } + } + + var value string + if len(split) == 2 { + // '--flag=arg' + value = split[1] + } else if flag.NoOptDefVal != "" { + // '--flag' (arg was optional) + value = flag.NoOptDefVal + } else if len(a) > 0 { + // '--flag arg' + value = a[0] + a = a[1:] + } else { + // '--flag' (arg was required) + err = f.failf("flag needs an argument: %s", s) + return + } + + err = fn(flag, value) + if err != nil { + f.failf(err.Error()) + } + return +} + +func (f *FlagSet) parseSingleShortArg(shorthands string, args []string, fn parseFunc) (outShorts string, outArgs []string, err error) { + if strings.HasPrefix(shorthands, "test.") { + return + } + + outArgs = args + outShorts = shorthands[1:] + c := shorthands[0] + + flag, exists := f.shorthands[c] + if !exists { + switch { + case c == 'h': + f.usage() + err = ErrHelp + return + case f.ParseErrorsWhitelist.UnknownFlags: + // '-f=arg arg ...' + // we do not want to lose arg in this case + if len(shorthands) > 2 && shorthands[1] == '=' { + outShorts = "" + return + } + + outArgs = stripUnknownFlagValue(outArgs) + return + default: + err = f.failf("unknown shorthand flag: %q in -%s", c, shorthands) + return + } + } + + var value string + if len(shorthands) > 2 && shorthands[1] == '=' { + // '-f=arg' + value = shorthands[2:] + outShorts = "" + } else if flag.NoOptDefVal != "" { + // '-f' (arg was optional) + value = flag.NoOptDefVal + } else if len(shorthands) > 1 { + // '-farg' + value = shorthands[1:] + outShorts = "" + } else if len(args) > 0 { + // '-f arg' + value = args[0] + outArgs = args[1:] + } else { + // '-f' (arg was required) + err = f.failf("flag needs an argument: %q in -%s", c, shorthands) + return + } + + if flag.ShorthandDeprecated != "" { + fmt.Fprintf(f.out(), "Flag shorthand -%s has been deprecated, %s\n", flag.Shorthand, flag.ShorthandDeprecated) + } + + err = fn(flag, value) + if err != nil { + f.failf(err.Error()) + } + return +} + +func (f *FlagSet) parseShortArg(s string, args []string, fn parseFunc) (a []string, err error) { + a = args + shorthands := s[1:] + + // "shorthands" can be a series of shorthand letters of flags (e.g. "-vvv"). + for len(shorthands) > 0 { + shorthands, a, err = f.parseSingleShortArg(shorthands, args, fn) + if err != nil { + return + } + } + + return +} + +func (f *FlagSet) parseArgs(args []string, fn parseFunc) (err error) { + for len(args) > 0 { + s := args[0] + args = args[1:] + if len(s) == 0 || s[0] != '-' || len(s) == 1 { + if !f.interspersed { + f.args = append(f.args, s) + f.args = append(f.args, args...) + return nil + } + f.args = append(f.args, s) + continue + } + + if s[1] == '-' { + if len(s) == 2 { // "--" terminates the flags + f.argsLenAtDash = len(f.args) + f.args = append(f.args, args...) + break + } + args, err = f.parseLongArg(s, args, fn) + } else { + args, err = f.parseShortArg(s, args, fn) + } + if err != nil { + return + } + } + return +} + +// Parse parses flag definitions from the argument list, which should not +// include the command name. Must be called after all flags in the FlagSet +// are defined and before flags are accessed by the program. +// The return value will be ErrHelp if -help was set but not defined. +func (f *FlagSet) Parse(arguments []string) error { + if f.addedGoFlagSets != nil { + for _, goFlagSet := range f.addedGoFlagSets { + goFlagSet.Parse(nil) + } + } + f.parsed = true + + if len(arguments) < 0 { + return nil + } + + f.args = make([]string, 0, len(arguments)) + + set := func(flag *Flag, value string) error { + return f.Set(flag.Name, value) + } + + err := f.parseArgs(arguments, set) + if err != nil { + switch f.errorHandling { + case ContinueOnError: + return err + case ExitOnError: + fmt.Println(err) + os.Exit(2) + case PanicOnError: + panic(err) + } + } + return nil +} + +type parseFunc func(flag *Flag, value string) error + +// ParseAll parses flag definitions from the argument list, which should not +// include the command name. The arguments for fn are flag and value. Must be +// called after all flags in the FlagSet are defined and before flags are +// accessed by the program. The return value will be ErrHelp if -help was set +// but not defined. +func (f *FlagSet) ParseAll(arguments []string, fn func(flag *Flag, value string) error) error { + f.parsed = true + f.args = make([]string, 0, len(arguments)) + + err := f.parseArgs(arguments, fn) + if err != nil { + switch f.errorHandling { + case ContinueOnError: + return err + case ExitOnError: + os.Exit(2) + case PanicOnError: + panic(err) + } + } + return nil +} + +// Parsed reports whether f.Parse has been called. +func (f *FlagSet) Parsed() bool { + return f.parsed +} + +// Parse parses the command-line flags from os.Args[1:]. Must be called +// after all flags are defined and before flags are accessed by the program. +func Parse() { + // Ignore errors; CommandLine is set for ExitOnError. + CommandLine.Parse(os.Args[1:]) +} + +// ParseAll parses the command-line flags from os.Args[1:] and called fn for each. +// The arguments for fn are flag and value. Must be called after all flags are +// defined and before flags are accessed by the program. +func ParseAll(fn func(flag *Flag, value string) error) { + // Ignore errors; CommandLine is set for ExitOnError. + CommandLine.ParseAll(os.Args[1:], fn) +} + +// SetInterspersed sets whether to support interspersed option/non-option arguments. +func SetInterspersed(interspersed bool) { + CommandLine.SetInterspersed(interspersed) +} + +// Parsed returns true if the command-line flags have been parsed. +func Parsed() bool { + return CommandLine.Parsed() +} + +// CommandLine is the default set of command-line flags, parsed from os.Args. +var CommandLine = NewFlagSet(os.Args[0], ExitOnError) + +// NewFlagSet returns a new, empty flag set with the specified name, +// error handling property and SortFlags set to true. +func NewFlagSet(name string, errorHandling ErrorHandling) *FlagSet { + f := &FlagSet{ + name: name, + errorHandling: errorHandling, + argsLenAtDash: -1, + interspersed: true, + SortFlags: true, + } + return f +} + +// SetInterspersed sets whether to support interspersed option/non-option arguments. +func (f *FlagSet) SetInterspersed(interspersed bool) { + f.interspersed = interspersed +} + +// Init sets the name and error handling property for a flag set. +// By default, the zero FlagSet uses an empty name and the +// ContinueOnError error handling policy. +func (f *FlagSet) Init(name string, errorHandling ErrorHandling) { + f.name = name + f.errorHandling = errorHandling + f.argsLenAtDash = -1 +} diff --git a/vendor/github.com/spf13/pflag/float32.go b/vendor/github.com/spf13/pflag/float32.go new file mode 100644 index 000000000..a243f81f7 --- /dev/null +++ b/vendor/github.com/spf13/pflag/float32.go @@ -0,0 +1,88 @@ +package pflag + +import "strconv" + +// -- float32 Value +type float32Value float32 + +func newFloat32Value(val float32, p *float32) *float32Value { + *p = val + return (*float32Value)(p) +} + +func (f *float32Value) Set(s string) error { + v, err := strconv.ParseFloat(s, 32) + *f = float32Value(v) + return err +} + +func (f *float32Value) Type() string { + return "float32" +} + +func (f *float32Value) String() string { return strconv.FormatFloat(float64(*f), 'g', -1, 32) } + +func float32Conv(sval string) (interface{}, error) { + v, err := strconv.ParseFloat(sval, 32) + if err != nil { + return 0, err + } + return float32(v), nil +} + +// GetFloat32 return the float32 value of a flag with the given name +func (f *FlagSet) GetFloat32(name string) (float32, error) { + val, err := f.getFlagType(name, "float32", float32Conv) + if err != nil { + return 0, err + } + return val.(float32), nil +} + +// Float32Var defines a float32 flag with specified name, default value, and usage string. +// The argument p points to a float32 variable in which to store the value of the flag. +func (f *FlagSet) Float32Var(p *float32, name string, value float32, usage string) { + f.VarP(newFloat32Value(value, p), name, "", usage) +} + +// Float32VarP is like Float32Var, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Float32VarP(p *float32, name, shorthand string, value float32, usage string) { + f.VarP(newFloat32Value(value, p), name, shorthand, usage) +} + +// Float32Var defines a float32 flag with specified name, default value, and usage string. +// The argument p points to a float32 variable in which to store the value of the flag. +func Float32Var(p *float32, name string, value float32, usage string) { + CommandLine.VarP(newFloat32Value(value, p), name, "", usage) +} + +// Float32VarP is like Float32Var, but accepts a shorthand letter that can be used after a single dash. +func Float32VarP(p *float32, name, shorthand string, value float32, usage string) { + CommandLine.VarP(newFloat32Value(value, p), name, shorthand, usage) +} + +// Float32 defines a float32 flag with specified name, default value, and usage string. +// The return value is the address of a float32 variable that stores the value of the flag. +func (f *FlagSet) Float32(name string, value float32, usage string) *float32 { + p := new(float32) + f.Float32VarP(p, name, "", value, usage) + return p +} + +// Float32P is like Float32, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Float32P(name, shorthand string, value float32, usage string) *float32 { + p := new(float32) + f.Float32VarP(p, name, shorthand, value, usage) + return p +} + +// Float32 defines a float32 flag with specified name, default value, and usage string. +// The return value is the address of a float32 variable that stores the value of the flag. +func Float32(name string, value float32, usage string) *float32 { + return CommandLine.Float32P(name, "", value, usage) +} + +// Float32P is like Float32, but accepts a shorthand letter that can be used after a single dash. +func Float32P(name, shorthand string, value float32, usage string) *float32 { + return CommandLine.Float32P(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/float64.go b/vendor/github.com/spf13/pflag/float64.go new file mode 100644 index 000000000..04b5492a7 --- /dev/null +++ b/vendor/github.com/spf13/pflag/float64.go @@ -0,0 +1,84 @@ +package pflag + +import "strconv" + +// -- float64 Value +type float64Value float64 + +func newFloat64Value(val float64, p *float64) *float64Value { + *p = val + return (*float64Value)(p) +} + +func (f *float64Value) Set(s string) error { + v, err := strconv.ParseFloat(s, 64) + *f = float64Value(v) + return err +} + +func (f *float64Value) Type() string { + return "float64" +} + +func (f *float64Value) String() string { return strconv.FormatFloat(float64(*f), 'g', -1, 64) } + +func float64Conv(sval string) (interface{}, error) { + return strconv.ParseFloat(sval, 64) +} + +// GetFloat64 return the float64 value of a flag with the given name +func (f *FlagSet) GetFloat64(name string) (float64, error) { + val, err := f.getFlagType(name, "float64", float64Conv) + if err != nil { + return 0, err + } + return val.(float64), nil +} + +// Float64Var defines a float64 flag with specified name, default value, and usage string. +// The argument p points to a float64 variable in which to store the value of the flag. +func (f *FlagSet) Float64Var(p *float64, name string, value float64, usage string) { + f.VarP(newFloat64Value(value, p), name, "", usage) +} + +// Float64VarP is like Float64Var, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Float64VarP(p *float64, name, shorthand string, value float64, usage string) { + f.VarP(newFloat64Value(value, p), name, shorthand, usage) +} + +// Float64Var defines a float64 flag with specified name, default value, and usage string. +// The argument p points to a float64 variable in which to store the value of the flag. +func Float64Var(p *float64, name string, value float64, usage string) { + CommandLine.VarP(newFloat64Value(value, p), name, "", usage) +} + +// Float64VarP is like Float64Var, but accepts a shorthand letter that can be used after a single dash. +func Float64VarP(p *float64, name, shorthand string, value float64, usage string) { + CommandLine.VarP(newFloat64Value(value, p), name, shorthand, usage) +} + +// Float64 defines a float64 flag with specified name, default value, and usage string. +// The return value is the address of a float64 variable that stores the value of the flag. +func (f *FlagSet) Float64(name string, value float64, usage string) *float64 { + p := new(float64) + f.Float64VarP(p, name, "", value, usage) + return p +} + +// Float64P is like Float64, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Float64P(name, shorthand string, value float64, usage string) *float64 { + p := new(float64) + f.Float64VarP(p, name, shorthand, value, usage) + return p +} + +// Float64 defines a float64 flag with specified name, default value, and usage string. +// The return value is the address of a float64 variable that stores the value of the flag. +func Float64(name string, value float64, usage string) *float64 { + return CommandLine.Float64P(name, "", value, usage) +} + +// Float64P is like Float64, but accepts a shorthand letter that can be used after a single dash. +func Float64P(name, shorthand string, value float64, usage string) *float64 { + return CommandLine.Float64P(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/golangflag.go b/vendor/github.com/spf13/pflag/golangflag.go new file mode 100644 index 000000000..d3dd72b7f --- /dev/null +++ b/vendor/github.com/spf13/pflag/golangflag.go @@ -0,0 +1,105 @@ +// Copyright 2009 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package pflag + +import ( + goflag "flag" + "reflect" + "strings" +) + +// flagValueWrapper implements pflag.Value around a flag.Value. The main +// difference here is the addition of the Type method that returns a string +// name of the type. As this is generally unknown, we approximate that with +// reflection. +type flagValueWrapper struct { + inner goflag.Value + flagType string +} + +// We are just copying the boolFlag interface out of goflag as that is what +// they use to decide if a flag should get "true" when no arg is given. +type goBoolFlag interface { + goflag.Value + IsBoolFlag() bool +} + +func wrapFlagValue(v goflag.Value) Value { + // If the flag.Value happens to also be a pflag.Value, just use it directly. + if pv, ok := v.(Value); ok { + return pv + } + + pv := &flagValueWrapper{ + inner: v, + } + + t := reflect.TypeOf(v) + if t.Kind() == reflect.Interface || t.Kind() == reflect.Ptr { + t = t.Elem() + } + + pv.flagType = strings.TrimSuffix(t.Name(), "Value") + return pv +} + +func (v *flagValueWrapper) String() string { + return v.inner.String() +} + +func (v *flagValueWrapper) Set(s string) error { + return v.inner.Set(s) +} + +func (v *flagValueWrapper) Type() string { + return v.flagType +} + +// PFlagFromGoFlag will return a *pflag.Flag given a *flag.Flag +// If the *flag.Flag.Name was a single character (ex: `v`) it will be accessiblei +// with both `-v` and `--v` in flags. If the golang flag was more than a single +// character (ex: `verbose`) it will only be accessible via `--verbose` +func PFlagFromGoFlag(goflag *goflag.Flag) *Flag { + // Remember the default value as a string; it won't change. + flag := &Flag{ + Name: goflag.Name, + Usage: goflag.Usage, + Value: wrapFlagValue(goflag.Value), + // Looks like golang flags don't set DefValue correctly :-( + //DefValue: goflag.DefValue, + DefValue: goflag.Value.String(), + } + // Ex: if the golang flag was -v, allow both -v and --v to work + if len(flag.Name) == 1 { + flag.Shorthand = flag.Name + } + if fv, ok := goflag.Value.(goBoolFlag); ok && fv.IsBoolFlag() { + flag.NoOptDefVal = "true" + } + return flag +} + +// AddGoFlag will add the given *flag.Flag to the pflag.FlagSet +func (f *FlagSet) AddGoFlag(goflag *goflag.Flag) { + if f.Lookup(goflag.Name) != nil { + return + } + newflag := PFlagFromGoFlag(goflag) + f.AddFlag(newflag) +} + +// AddGoFlagSet will add the given *flag.FlagSet to the pflag.FlagSet +func (f *FlagSet) AddGoFlagSet(newSet *goflag.FlagSet) { + if newSet == nil { + return + } + newSet.VisitAll(func(goflag *goflag.Flag) { + f.AddGoFlag(goflag) + }) + if f.addedGoFlagSets == nil { + f.addedGoFlagSets = make([]*goflag.FlagSet, 0) + } + f.addedGoFlagSets = append(f.addedGoFlagSets, newSet) +} diff --git a/vendor/github.com/spf13/pflag/int.go b/vendor/github.com/spf13/pflag/int.go new file mode 100644 index 000000000..1474b89df --- /dev/null +++ b/vendor/github.com/spf13/pflag/int.go @@ -0,0 +1,84 @@ +package pflag + +import "strconv" + +// -- int Value +type intValue int + +func newIntValue(val int, p *int) *intValue { + *p = val + return (*intValue)(p) +} + +func (i *intValue) Set(s string) error { + v, err := strconv.ParseInt(s, 0, 64) + *i = intValue(v) + return err +} + +func (i *intValue) Type() string { + return "int" +} + +func (i *intValue) String() string { return strconv.Itoa(int(*i)) } + +func intConv(sval string) (interface{}, error) { + return strconv.Atoi(sval) +} + +// GetInt return the int value of a flag with the given name +func (f *FlagSet) GetInt(name string) (int, error) { + val, err := f.getFlagType(name, "int", intConv) + if err != nil { + return 0, err + } + return val.(int), nil +} + +// IntVar defines an int flag with specified name, default value, and usage string. +// The argument p points to an int variable in which to store the value of the flag. +func (f *FlagSet) IntVar(p *int, name string, value int, usage string) { + f.VarP(newIntValue(value, p), name, "", usage) +} + +// IntVarP is like IntVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) IntVarP(p *int, name, shorthand string, value int, usage string) { + f.VarP(newIntValue(value, p), name, shorthand, usage) +} + +// IntVar defines an int flag with specified name, default value, and usage string. +// The argument p points to an int variable in which to store the value of the flag. +func IntVar(p *int, name string, value int, usage string) { + CommandLine.VarP(newIntValue(value, p), name, "", usage) +} + +// IntVarP is like IntVar, but accepts a shorthand letter that can be used after a single dash. +func IntVarP(p *int, name, shorthand string, value int, usage string) { + CommandLine.VarP(newIntValue(value, p), name, shorthand, usage) +} + +// Int defines an int flag with specified name, default value, and usage string. +// The return value is the address of an int variable that stores the value of the flag. +func (f *FlagSet) Int(name string, value int, usage string) *int { + p := new(int) + f.IntVarP(p, name, "", value, usage) + return p +} + +// IntP is like Int, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) IntP(name, shorthand string, value int, usage string) *int { + p := new(int) + f.IntVarP(p, name, shorthand, value, usage) + return p +} + +// Int defines an int flag with specified name, default value, and usage string. +// The return value is the address of an int variable that stores the value of the flag. +func Int(name string, value int, usage string) *int { + return CommandLine.IntP(name, "", value, usage) +} + +// IntP is like Int, but accepts a shorthand letter that can be used after a single dash. +func IntP(name, shorthand string, value int, usage string) *int { + return CommandLine.IntP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/int16.go b/vendor/github.com/spf13/pflag/int16.go new file mode 100644 index 000000000..f1a01d05e --- /dev/null +++ b/vendor/github.com/spf13/pflag/int16.go @@ -0,0 +1,88 @@ +package pflag + +import "strconv" + +// -- int16 Value +type int16Value int16 + +func newInt16Value(val int16, p *int16) *int16Value { + *p = val + return (*int16Value)(p) +} + +func (i *int16Value) Set(s string) error { + v, err := strconv.ParseInt(s, 0, 16) + *i = int16Value(v) + return err +} + +func (i *int16Value) Type() string { + return "int16" +} + +func (i *int16Value) String() string { return strconv.FormatInt(int64(*i), 10) } + +func int16Conv(sval string) (interface{}, error) { + v, err := strconv.ParseInt(sval, 0, 16) + if err != nil { + return 0, err + } + return int16(v), nil +} + +// GetInt16 returns the int16 value of a flag with the given name +func (f *FlagSet) GetInt16(name string) (int16, error) { + val, err := f.getFlagType(name, "int16", int16Conv) + if err != nil { + return 0, err + } + return val.(int16), nil +} + +// Int16Var defines an int16 flag with specified name, default value, and usage string. +// The argument p points to an int16 variable in which to store the value of the flag. +func (f *FlagSet) Int16Var(p *int16, name string, value int16, usage string) { + f.VarP(newInt16Value(value, p), name, "", usage) +} + +// Int16VarP is like Int16Var, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Int16VarP(p *int16, name, shorthand string, value int16, usage string) { + f.VarP(newInt16Value(value, p), name, shorthand, usage) +} + +// Int16Var defines an int16 flag with specified name, default value, and usage string. +// The argument p points to an int16 variable in which to store the value of the flag. +func Int16Var(p *int16, name string, value int16, usage string) { + CommandLine.VarP(newInt16Value(value, p), name, "", usage) +} + +// Int16VarP is like Int16Var, but accepts a shorthand letter that can be used after a single dash. +func Int16VarP(p *int16, name, shorthand string, value int16, usage string) { + CommandLine.VarP(newInt16Value(value, p), name, shorthand, usage) +} + +// Int16 defines an int16 flag with specified name, default value, and usage string. +// The return value is the address of an int16 variable that stores the value of the flag. +func (f *FlagSet) Int16(name string, value int16, usage string) *int16 { + p := new(int16) + f.Int16VarP(p, name, "", value, usage) + return p +} + +// Int16P is like Int16, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Int16P(name, shorthand string, value int16, usage string) *int16 { + p := new(int16) + f.Int16VarP(p, name, shorthand, value, usage) + return p +} + +// Int16 defines an int16 flag with specified name, default value, and usage string. +// The return value is the address of an int16 variable that stores the value of the flag. +func Int16(name string, value int16, usage string) *int16 { + return CommandLine.Int16P(name, "", value, usage) +} + +// Int16P is like Int16, but accepts a shorthand letter that can be used after a single dash. +func Int16P(name, shorthand string, value int16, usage string) *int16 { + return CommandLine.Int16P(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/int32.go b/vendor/github.com/spf13/pflag/int32.go new file mode 100644 index 000000000..9b95944f0 --- /dev/null +++ b/vendor/github.com/spf13/pflag/int32.go @@ -0,0 +1,88 @@ +package pflag + +import "strconv" + +// -- int32 Value +type int32Value int32 + +func newInt32Value(val int32, p *int32) *int32Value { + *p = val + return (*int32Value)(p) +} + +func (i *int32Value) Set(s string) error { + v, err := strconv.ParseInt(s, 0, 32) + *i = int32Value(v) + return err +} + +func (i *int32Value) Type() string { + return "int32" +} + +func (i *int32Value) String() string { return strconv.FormatInt(int64(*i), 10) } + +func int32Conv(sval string) (interface{}, error) { + v, err := strconv.ParseInt(sval, 0, 32) + if err != nil { + return 0, err + } + return int32(v), nil +} + +// GetInt32 return the int32 value of a flag with the given name +func (f *FlagSet) GetInt32(name string) (int32, error) { + val, err := f.getFlagType(name, "int32", int32Conv) + if err != nil { + return 0, err + } + return val.(int32), nil +} + +// Int32Var defines an int32 flag with specified name, default value, and usage string. +// The argument p points to an int32 variable in which to store the value of the flag. +func (f *FlagSet) Int32Var(p *int32, name string, value int32, usage string) { + f.VarP(newInt32Value(value, p), name, "", usage) +} + +// Int32VarP is like Int32Var, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Int32VarP(p *int32, name, shorthand string, value int32, usage string) { + f.VarP(newInt32Value(value, p), name, shorthand, usage) +} + +// Int32Var defines an int32 flag with specified name, default value, and usage string. +// The argument p points to an int32 variable in which to store the value of the flag. +func Int32Var(p *int32, name string, value int32, usage string) { + CommandLine.VarP(newInt32Value(value, p), name, "", usage) +} + +// Int32VarP is like Int32Var, but accepts a shorthand letter that can be used after a single dash. +func Int32VarP(p *int32, name, shorthand string, value int32, usage string) { + CommandLine.VarP(newInt32Value(value, p), name, shorthand, usage) +} + +// Int32 defines an int32 flag with specified name, default value, and usage string. +// The return value is the address of an int32 variable that stores the value of the flag. +func (f *FlagSet) Int32(name string, value int32, usage string) *int32 { + p := new(int32) + f.Int32VarP(p, name, "", value, usage) + return p +} + +// Int32P is like Int32, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Int32P(name, shorthand string, value int32, usage string) *int32 { + p := new(int32) + f.Int32VarP(p, name, shorthand, value, usage) + return p +} + +// Int32 defines an int32 flag with specified name, default value, and usage string. +// The return value is the address of an int32 variable that stores the value of the flag. +func Int32(name string, value int32, usage string) *int32 { + return CommandLine.Int32P(name, "", value, usage) +} + +// Int32P is like Int32, but accepts a shorthand letter that can be used after a single dash. +func Int32P(name, shorthand string, value int32, usage string) *int32 { + return CommandLine.Int32P(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/int64.go b/vendor/github.com/spf13/pflag/int64.go new file mode 100644 index 000000000..0026d781d --- /dev/null +++ b/vendor/github.com/spf13/pflag/int64.go @@ -0,0 +1,84 @@ +package pflag + +import "strconv" + +// -- int64 Value +type int64Value int64 + +func newInt64Value(val int64, p *int64) *int64Value { + *p = val + return (*int64Value)(p) +} + +func (i *int64Value) Set(s string) error { + v, err := strconv.ParseInt(s, 0, 64) + *i = int64Value(v) + return err +} + +func (i *int64Value) Type() string { + return "int64" +} + +func (i *int64Value) String() string { return strconv.FormatInt(int64(*i), 10) } + +func int64Conv(sval string) (interface{}, error) { + return strconv.ParseInt(sval, 0, 64) +} + +// GetInt64 return the int64 value of a flag with the given name +func (f *FlagSet) GetInt64(name string) (int64, error) { + val, err := f.getFlagType(name, "int64", int64Conv) + if err != nil { + return 0, err + } + return val.(int64), nil +} + +// Int64Var defines an int64 flag with specified name, default value, and usage string. +// The argument p points to an int64 variable in which to store the value of the flag. +func (f *FlagSet) Int64Var(p *int64, name string, value int64, usage string) { + f.VarP(newInt64Value(value, p), name, "", usage) +} + +// Int64VarP is like Int64Var, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Int64VarP(p *int64, name, shorthand string, value int64, usage string) { + f.VarP(newInt64Value(value, p), name, shorthand, usage) +} + +// Int64Var defines an int64 flag with specified name, default value, and usage string. +// The argument p points to an int64 variable in which to store the value of the flag. +func Int64Var(p *int64, name string, value int64, usage string) { + CommandLine.VarP(newInt64Value(value, p), name, "", usage) +} + +// Int64VarP is like Int64Var, but accepts a shorthand letter that can be used after a single dash. +func Int64VarP(p *int64, name, shorthand string, value int64, usage string) { + CommandLine.VarP(newInt64Value(value, p), name, shorthand, usage) +} + +// Int64 defines an int64 flag with specified name, default value, and usage string. +// The return value is the address of an int64 variable that stores the value of the flag. +func (f *FlagSet) Int64(name string, value int64, usage string) *int64 { + p := new(int64) + f.Int64VarP(p, name, "", value, usage) + return p +} + +// Int64P is like Int64, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Int64P(name, shorthand string, value int64, usage string) *int64 { + p := new(int64) + f.Int64VarP(p, name, shorthand, value, usage) + return p +} + +// Int64 defines an int64 flag with specified name, default value, and usage string. +// The return value is the address of an int64 variable that stores the value of the flag. +func Int64(name string, value int64, usage string) *int64 { + return CommandLine.Int64P(name, "", value, usage) +} + +// Int64P is like Int64, but accepts a shorthand letter that can be used after a single dash. +func Int64P(name, shorthand string, value int64, usage string) *int64 { + return CommandLine.Int64P(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/int8.go b/vendor/github.com/spf13/pflag/int8.go new file mode 100644 index 000000000..4da92228e --- /dev/null +++ b/vendor/github.com/spf13/pflag/int8.go @@ -0,0 +1,88 @@ +package pflag + +import "strconv" + +// -- int8 Value +type int8Value int8 + +func newInt8Value(val int8, p *int8) *int8Value { + *p = val + return (*int8Value)(p) +} + +func (i *int8Value) Set(s string) error { + v, err := strconv.ParseInt(s, 0, 8) + *i = int8Value(v) + return err +} + +func (i *int8Value) Type() string { + return "int8" +} + +func (i *int8Value) String() string { return strconv.FormatInt(int64(*i), 10) } + +func int8Conv(sval string) (interface{}, error) { + v, err := strconv.ParseInt(sval, 0, 8) + if err != nil { + return 0, err + } + return int8(v), nil +} + +// GetInt8 return the int8 value of a flag with the given name +func (f *FlagSet) GetInt8(name string) (int8, error) { + val, err := f.getFlagType(name, "int8", int8Conv) + if err != nil { + return 0, err + } + return val.(int8), nil +} + +// Int8Var defines an int8 flag with specified name, default value, and usage string. +// The argument p points to an int8 variable in which to store the value of the flag. +func (f *FlagSet) Int8Var(p *int8, name string, value int8, usage string) { + f.VarP(newInt8Value(value, p), name, "", usage) +} + +// Int8VarP is like Int8Var, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Int8VarP(p *int8, name, shorthand string, value int8, usage string) { + f.VarP(newInt8Value(value, p), name, shorthand, usage) +} + +// Int8Var defines an int8 flag with specified name, default value, and usage string. +// The argument p points to an int8 variable in which to store the value of the flag. +func Int8Var(p *int8, name string, value int8, usage string) { + CommandLine.VarP(newInt8Value(value, p), name, "", usage) +} + +// Int8VarP is like Int8Var, but accepts a shorthand letter that can be used after a single dash. +func Int8VarP(p *int8, name, shorthand string, value int8, usage string) { + CommandLine.VarP(newInt8Value(value, p), name, shorthand, usage) +} + +// Int8 defines an int8 flag with specified name, default value, and usage string. +// The return value is the address of an int8 variable that stores the value of the flag. +func (f *FlagSet) Int8(name string, value int8, usage string) *int8 { + p := new(int8) + f.Int8VarP(p, name, "", value, usage) + return p +} + +// Int8P is like Int8, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Int8P(name, shorthand string, value int8, usage string) *int8 { + p := new(int8) + f.Int8VarP(p, name, shorthand, value, usage) + return p +} + +// Int8 defines an int8 flag with specified name, default value, and usage string. +// The return value is the address of an int8 variable that stores the value of the flag. +func Int8(name string, value int8, usage string) *int8 { + return CommandLine.Int8P(name, "", value, usage) +} + +// Int8P is like Int8, but accepts a shorthand letter that can be used after a single dash. +func Int8P(name, shorthand string, value int8, usage string) *int8 { + return CommandLine.Int8P(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/int_slice.go b/vendor/github.com/spf13/pflag/int_slice.go new file mode 100644 index 000000000..1e7c9edde --- /dev/null +++ b/vendor/github.com/spf13/pflag/int_slice.go @@ -0,0 +1,128 @@ +package pflag + +import ( + "fmt" + "strconv" + "strings" +) + +// -- intSlice Value +type intSliceValue struct { + value *[]int + changed bool +} + +func newIntSliceValue(val []int, p *[]int) *intSliceValue { + isv := new(intSliceValue) + isv.value = p + *isv.value = val + return isv +} + +func (s *intSliceValue) Set(val string) error { + ss := strings.Split(val, ",") + out := make([]int, len(ss)) + for i, d := range ss { + var err error + out[i], err = strconv.Atoi(d) + if err != nil { + return err + } + + } + if !s.changed { + *s.value = out + } else { + *s.value = append(*s.value, out...) + } + s.changed = true + return nil +} + +func (s *intSliceValue) Type() string { + return "intSlice" +} + +func (s *intSliceValue) String() string { + out := make([]string, len(*s.value)) + for i, d := range *s.value { + out[i] = fmt.Sprintf("%d", d) + } + return "[" + strings.Join(out, ",") + "]" +} + +func intSliceConv(val string) (interface{}, error) { + val = strings.Trim(val, "[]") + // Empty string would cause a slice with one (empty) entry + if len(val) == 0 { + return []int{}, nil + } + ss := strings.Split(val, ",") + out := make([]int, len(ss)) + for i, d := range ss { + var err error + out[i], err = strconv.Atoi(d) + if err != nil { + return nil, err + } + + } + return out, nil +} + +// GetIntSlice return the []int value of a flag with the given name +func (f *FlagSet) GetIntSlice(name string) ([]int, error) { + val, err := f.getFlagType(name, "intSlice", intSliceConv) + if err != nil { + return []int{}, err + } + return val.([]int), nil +} + +// IntSliceVar defines a intSlice flag with specified name, default value, and usage string. +// The argument p points to a []int variable in which to store the value of the flag. +func (f *FlagSet) IntSliceVar(p *[]int, name string, value []int, usage string) { + f.VarP(newIntSliceValue(value, p), name, "", usage) +} + +// IntSliceVarP is like IntSliceVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) IntSliceVarP(p *[]int, name, shorthand string, value []int, usage string) { + f.VarP(newIntSliceValue(value, p), name, shorthand, usage) +} + +// IntSliceVar defines a int[] flag with specified name, default value, and usage string. +// The argument p points to a int[] variable in which to store the value of the flag. +func IntSliceVar(p *[]int, name string, value []int, usage string) { + CommandLine.VarP(newIntSliceValue(value, p), name, "", usage) +} + +// IntSliceVarP is like IntSliceVar, but accepts a shorthand letter that can be used after a single dash. +func IntSliceVarP(p *[]int, name, shorthand string, value []int, usage string) { + CommandLine.VarP(newIntSliceValue(value, p), name, shorthand, usage) +} + +// IntSlice defines a []int flag with specified name, default value, and usage string. +// The return value is the address of a []int variable that stores the value of the flag. +func (f *FlagSet) IntSlice(name string, value []int, usage string) *[]int { + p := []int{} + f.IntSliceVarP(&p, name, "", value, usage) + return &p +} + +// IntSliceP is like IntSlice, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) IntSliceP(name, shorthand string, value []int, usage string) *[]int { + p := []int{} + f.IntSliceVarP(&p, name, shorthand, value, usage) + return &p +} + +// IntSlice defines a []int flag with specified name, default value, and usage string. +// The return value is the address of a []int variable that stores the value of the flag. +func IntSlice(name string, value []int, usage string) *[]int { + return CommandLine.IntSliceP(name, "", value, usage) +} + +// IntSliceP is like IntSlice, but accepts a shorthand letter that can be used after a single dash. +func IntSliceP(name, shorthand string, value []int, usage string) *[]int { + return CommandLine.IntSliceP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/ip.go b/vendor/github.com/spf13/pflag/ip.go new file mode 100644 index 000000000..3d414ba69 --- /dev/null +++ b/vendor/github.com/spf13/pflag/ip.go @@ -0,0 +1,94 @@ +package pflag + +import ( + "fmt" + "net" + "strings" +) + +// -- net.IP value +type ipValue net.IP + +func newIPValue(val net.IP, p *net.IP) *ipValue { + *p = val + return (*ipValue)(p) +} + +func (i *ipValue) String() string { return net.IP(*i).String() } +func (i *ipValue) Set(s string) error { + ip := net.ParseIP(strings.TrimSpace(s)) + if ip == nil { + return fmt.Errorf("failed to parse IP: %q", s) + } + *i = ipValue(ip) + return nil +} + +func (i *ipValue) Type() string { + return "ip" +} + +func ipConv(sval string) (interface{}, error) { + ip := net.ParseIP(sval) + if ip != nil { + return ip, nil + } + return nil, fmt.Errorf("invalid string being converted to IP address: %s", sval) +} + +// GetIP return the net.IP value of a flag with the given name +func (f *FlagSet) GetIP(name string) (net.IP, error) { + val, err := f.getFlagType(name, "ip", ipConv) + if err != nil { + return nil, err + } + return val.(net.IP), nil +} + +// IPVar defines an net.IP flag with specified name, default value, and usage string. +// The argument p points to an net.IP variable in which to store the value of the flag. +func (f *FlagSet) IPVar(p *net.IP, name string, value net.IP, usage string) { + f.VarP(newIPValue(value, p), name, "", usage) +} + +// IPVarP is like IPVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) IPVarP(p *net.IP, name, shorthand string, value net.IP, usage string) { + f.VarP(newIPValue(value, p), name, shorthand, usage) +} + +// IPVar defines an net.IP flag with specified name, default value, and usage string. +// The argument p points to an net.IP variable in which to store the value of the flag. +func IPVar(p *net.IP, name string, value net.IP, usage string) { + CommandLine.VarP(newIPValue(value, p), name, "", usage) +} + +// IPVarP is like IPVar, but accepts a shorthand letter that can be used after a single dash. +func IPVarP(p *net.IP, name, shorthand string, value net.IP, usage string) { + CommandLine.VarP(newIPValue(value, p), name, shorthand, usage) +} + +// IP defines an net.IP flag with specified name, default value, and usage string. +// The return value is the address of an net.IP variable that stores the value of the flag. +func (f *FlagSet) IP(name string, value net.IP, usage string) *net.IP { + p := new(net.IP) + f.IPVarP(p, name, "", value, usage) + return p +} + +// IPP is like IP, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) IPP(name, shorthand string, value net.IP, usage string) *net.IP { + p := new(net.IP) + f.IPVarP(p, name, shorthand, value, usage) + return p +} + +// IP defines an net.IP flag with specified name, default value, and usage string. +// The return value is the address of an net.IP variable that stores the value of the flag. +func IP(name string, value net.IP, usage string) *net.IP { + return CommandLine.IPP(name, "", value, usage) +} + +// IPP is like IP, but accepts a shorthand letter that can be used after a single dash. +func IPP(name, shorthand string, value net.IP, usage string) *net.IP { + return CommandLine.IPP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/ip_slice.go b/vendor/github.com/spf13/pflag/ip_slice.go new file mode 100644 index 000000000..7dd196fe3 --- /dev/null +++ b/vendor/github.com/spf13/pflag/ip_slice.go @@ -0,0 +1,148 @@ +package pflag + +import ( + "fmt" + "io" + "net" + "strings" +) + +// -- ipSlice Value +type ipSliceValue struct { + value *[]net.IP + changed bool +} + +func newIPSliceValue(val []net.IP, p *[]net.IP) *ipSliceValue { + ipsv := new(ipSliceValue) + ipsv.value = p + *ipsv.value = val + return ipsv +} + +// Set converts, and assigns, the comma-separated IP argument string representation as the []net.IP value of this flag. +// If Set is called on a flag that already has a []net.IP assigned, the newly converted values will be appended. +func (s *ipSliceValue) Set(val string) error { + + // remove all quote characters + rmQuote := strings.NewReplacer(`"`, "", `'`, "", "`", "") + + // read flag arguments with CSV parser + ipStrSlice, err := readAsCSV(rmQuote.Replace(val)) + if err != nil && err != io.EOF { + return err + } + + // parse ip values into slice + out := make([]net.IP, 0, len(ipStrSlice)) + for _, ipStr := range ipStrSlice { + ip := net.ParseIP(strings.TrimSpace(ipStr)) + if ip == nil { + return fmt.Errorf("invalid string being converted to IP address: %s", ipStr) + } + out = append(out, ip) + } + + if !s.changed { + *s.value = out + } else { + *s.value = append(*s.value, out...) + } + + s.changed = true + + return nil +} + +// Type returns a string that uniquely represents this flag's type. +func (s *ipSliceValue) Type() string { + return "ipSlice" +} + +// String defines a "native" format for this net.IP slice flag value. +func (s *ipSliceValue) String() string { + + ipStrSlice := make([]string, len(*s.value)) + for i, ip := range *s.value { + ipStrSlice[i] = ip.String() + } + + out, _ := writeAsCSV(ipStrSlice) + + return "[" + out + "]" +} + +func ipSliceConv(val string) (interface{}, error) { + val = strings.Trim(val, "[]") + // Emtpy string would cause a slice with one (empty) entry + if len(val) == 0 { + return []net.IP{}, nil + } + ss := strings.Split(val, ",") + out := make([]net.IP, len(ss)) + for i, sval := range ss { + ip := net.ParseIP(strings.TrimSpace(sval)) + if ip == nil { + return nil, fmt.Errorf("invalid string being converted to IP address: %s", sval) + } + out[i] = ip + } + return out, nil +} + +// GetIPSlice returns the []net.IP value of a flag with the given name +func (f *FlagSet) GetIPSlice(name string) ([]net.IP, error) { + val, err := f.getFlagType(name, "ipSlice", ipSliceConv) + if err != nil { + return []net.IP{}, err + } + return val.([]net.IP), nil +} + +// IPSliceVar defines a ipSlice flag with specified name, default value, and usage string. +// The argument p points to a []net.IP variable in which to store the value of the flag. +func (f *FlagSet) IPSliceVar(p *[]net.IP, name string, value []net.IP, usage string) { + f.VarP(newIPSliceValue(value, p), name, "", usage) +} + +// IPSliceVarP is like IPSliceVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) IPSliceVarP(p *[]net.IP, name, shorthand string, value []net.IP, usage string) { + f.VarP(newIPSliceValue(value, p), name, shorthand, usage) +} + +// IPSliceVar defines a []net.IP flag with specified name, default value, and usage string. +// The argument p points to a []net.IP variable in which to store the value of the flag. +func IPSliceVar(p *[]net.IP, name string, value []net.IP, usage string) { + CommandLine.VarP(newIPSliceValue(value, p), name, "", usage) +} + +// IPSliceVarP is like IPSliceVar, but accepts a shorthand letter that can be used after a single dash. +func IPSliceVarP(p *[]net.IP, name, shorthand string, value []net.IP, usage string) { + CommandLine.VarP(newIPSliceValue(value, p), name, shorthand, usage) +} + +// IPSlice defines a []net.IP flag with specified name, default value, and usage string. +// The return value is the address of a []net.IP variable that stores the value of that flag. +func (f *FlagSet) IPSlice(name string, value []net.IP, usage string) *[]net.IP { + p := []net.IP{} + f.IPSliceVarP(&p, name, "", value, usage) + return &p +} + +// IPSliceP is like IPSlice, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) IPSliceP(name, shorthand string, value []net.IP, usage string) *[]net.IP { + p := []net.IP{} + f.IPSliceVarP(&p, name, shorthand, value, usage) + return &p +} + +// IPSlice defines a []net.IP flag with specified name, default value, and usage string. +// The return value is the address of a []net.IP variable that stores the value of the flag. +func IPSlice(name string, value []net.IP, usage string) *[]net.IP { + return CommandLine.IPSliceP(name, "", value, usage) +} + +// IPSliceP is like IPSlice, but accepts a shorthand letter that can be used after a single dash. +func IPSliceP(name, shorthand string, value []net.IP, usage string) *[]net.IP { + return CommandLine.IPSliceP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/ipmask.go b/vendor/github.com/spf13/pflag/ipmask.go new file mode 100644 index 000000000..5bd44bd21 --- /dev/null +++ b/vendor/github.com/spf13/pflag/ipmask.go @@ -0,0 +1,122 @@ +package pflag + +import ( + "fmt" + "net" + "strconv" +) + +// -- net.IPMask value +type ipMaskValue net.IPMask + +func newIPMaskValue(val net.IPMask, p *net.IPMask) *ipMaskValue { + *p = val + return (*ipMaskValue)(p) +} + +func (i *ipMaskValue) String() string { return net.IPMask(*i).String() } +func (i *ipMaskValue) Set(s string) error { + ip := ParseIPv4Mask(s) + if ip == nil { + return fmt.Errorf("failed to parse IP mask: %q", s) + } + *i = ipMaskValue(ip) + return nil +} + +func (i *ipMaskValue) Type() string { + return "ipMask" +} + +// ParseIPv4Mask written in IP form (e.g. 255.255.255.0). +// This function should really belong to the net package. +func ParseIPv4Mask(s string) net.IPMask { + mask := net.ParseIP(s) + if mask == nil { + if len(s) != 8 { + return nil + } + // net.IPMask.String() actually outputs things like ffffff00 + // so write a horrible parser for that as well :-( + m := []int{} + for i := 0; i < 4; i++ { + b := "0x" + s[2*i:2*i+2] + d, err := strconv.ParseInt(b, 0, 0) + if err != nil { + return nil + } + m = append(m, int(d)) + } + s := fmt.Sprintf("%d.%d.%d.%d", m[0], m[1], m[2], m[3]) + mask = net.ParseIP(s) + if mask == nil { + return nil + } + } + return net.IPv4Mask(mask[12], mask[13], mask[14], mask[15]) +} + +func parseIPv4Mask(sval string) (interface{}, error) { + mask := ParseIPv4Mask(sval) + if mask == nil { + return nil, fmt.Errorf("unable to parse %s as net.IPMask", sval) + } + return mask, nil +} + +// GetIPv4Mask return the net.IPv4Mask value of a flag with the given name +func (f *FlagSet) GetIPv4Mask(name string) (net.IPMask, error) { + val, err := f.getFlagType(name, "ipMask", parseIPv4Mask) + if err != nil { + return nil, err + } + return val.(net.IPMask), nil +} + +// IPMaskVar defines an net.IPMask flag with specified name, default value, and usage string. +// The argument p points to an net.IPMask variable in which to store the value of the flag. +func (f *FlagSet) IPMaskVar(p *net.IPMask, name string, value net.IPMask, usage string) { + f.VarP(newIPMaskValue(value, p), name, "", usage) +} + +// IPMaskVarP is like IPMaskVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) IPMaskVarP(p *net.IPMask, name, shorthand string, value net.IPMask, usage string) { + f.VarP(newIPMaskValue(value, p), name, shorthand, usage) +} + +// IPMaskVar defines an net.IPMask flag with specified name, default value, and usage string. +// The argument p points to an net.IPMask variable in which to store the value of the flag. +func IPMaskVar(p *net.IPMask, name string, value net.IPMask, usage string) { + CommandLine.VarP(newIPMaskValue(value, p), name, "", usage) +} + +// IPMaskVarP is like IPMaskVar, but accepts a shorthand letter that can be used after a single dash. +func IPMaskVarP(p *net.IPMask, name, shorthand string, value net.IPMask, usage string) { + CommandLine.VarP(newIPMaskValue(value, p), name, shorthand, usage) +} + +// IPMask defines an net.IPMask flag with specified name, default value, and usage string. +// The return value is the address of an net.IPMask variable that stores the value of the flag. +func (f *FlagSet) IPMask(name string, value net.IPMask, usage string) *net.IPMask { + p := new(net.IPMask) + f.IPMaskVarP(p, name, "", value, usage) + return p +} + +// IPMaskP is like IPMask, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) IPMaskP(name, shorthand string, value net.IPMask, usage string) *net.IPMask { + p := new(net.IPMask) + f.IPMaskVarP(p, name, shorthand, value, usage) + return p +} + +// IPMask defines an net.IPMask flag with specified name, default value, and usage string. +// The return value is the address of an net.IPMask variable that stores the value of the flag. +func IPMask(name string, value net.IPMask, usage string) *net.IPMask { + return CommandLine.IPMaskP(name, "", value, usage) +} + +// IPMaskP is like IP, but accepts a shorthand letter that can be used after a single dash. +func IPMaskP(name, shorthand string, value net.IPMask, usage string) *net.IPMask { + return CommandLine.IPMaskP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/ipnet.go b/vendor/github.com/spf13/pflag/ipnet.go new file mode 100644 index 000000000..e2c1b8bcd --- /dev/null +++ b/vendor/github.com/spf13/pflag/ipnet.go @@ -0,0 +1,98 @@ +package pflag + +import ( + "fmt" + "net" + "strings" +) + +// IPNet adapts net.IPNet for use as a flag. +type ipNetValue net.IPNet + +func (ipnet ipNetValue) String() string { + n := net.IPNet(ipnet) + return n.String() +} + +func (ipnet *ipNetValue) Set(value string) error { + _, n, err := net.ParseCIDR(strings.TrimSpace(value)) + if err != nil { + return err + } + *ipnet = ipNetValue(*n) + return nil +} + +func (*ipNetValue) Type() string { + return "ipNet" +} + +func newIPNetValue(val net.IPNet, p *net.IPNet) *ipNetValue { + *p = val + return (*ipNetValue)(p) +} + +func ipNetConv(sval string) (interface{}, error) { + _, n, err := net.ParseCIDR(strings.TrimSpace(sval)) + if err == nil { + return *n, nil + } + return nil, fmt.Errorf("invalid string being converted to IPNet: %s", sval) +} + +// GetIPNet return the net.IPNet value of a flag with the given name +func (f *FlagSet) GetIPNet(name string) (net.IPNet, error) { + val, err := f.getFlagType(name, "ipNet", ipNetConv) + if err != nil { + return net.IPNet{}, err + } + return val.(net.IPNet), nil +} + +// IPNetVar defines an net.IPNet flag with specified name, default value, and usage string. +// The argument p points to an net.IPNet variable in which to store the value of the flag. +func (f *FlagSet) IPNetVar(p *net.IPNet, name string, value net.IPNet, usage string) { + f.VarP(newIPNetValue(value, p), name, "", usage) +} + +// IPNetVarP is like IPNetVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) IPNetVarP(p *net.IPNet, name, shorthand string, value net.IPNet, usage string) { + f.VarP(newIPNetValue(value, p), name, shorthand, usage) +} + +// IPNetVar defines an net.IPNet flag with specified name, default value, and usage string. +// The argument p points to an net.IPNet variable in which to store the value of the flag. +func IPNetVar(p *net.IPNet, name string, value net.IPNet, usage string) { + CommandLine.VarP(newIPNetValue(value, p), name, "", usage) +} + +// IPNetVarP is like IPNetVar, but accepts a shorthand letter that can be used after a single dash. +func IPNetVarP(p *net.IPNet, name, shorthand string, value net.IPNet, usage string) { + CommandLine.VarP(newIPNetValue(value, p), name, shorthand, usage) +} + +// IPNet defines an net.IPNet flag with specified name, default value, and usage string. +// The return value is the address of an net.IPNet variable that stores the value of the flag. +func (f *FlagSet) IPNet(name string, value net.IPNet, usage string) *net.IPNet { + p := new(net.IPNet) + f.IPNetVarP(p, name, "", value, usage) + return p +} + +// IPNetP is like IPNet, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) IPNetP(name, shorthand string, value net.IPNet, usage string) *net.IPNet { + p := new(net.IPNet) + f.IPNetVarP(p, name, shorthand, value, usage) + return p +} + +// IPNet defines an net.IPNet flag with specified name, default value, and usage string. +// The return value is the address of an net.IPNet variable that stores the value of the flag. +func IPNet(name string, value net.IPNet, usage string) *net.IPNet { + return CommandLine.IPNetP(name, "", value, usage) +} + +// IPNetP is like IPNet, but accepts a shorthand letter that can be used after a single dash. +func IPNetP(name, shorthand string, value net.IPNet, usage string) *net.IPNet { + return CommandLine.IPNetP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/string.go b/vendor/github.com/spf13/pflag/string.go new file mode 100644 index 000000000..04e0a26ff --- /dev/null +++ b/vendor/github.com/spf13/pflag/string.go @@ -0,0 +1,80 @@ +package pflag + +// -- string Value +type stringValue string + +func newStringValue(val string, p *string) *stringValue { + *p = val + return (*stringValue)(p) +} + +func (s *stringValue) Set(val string) error { + *s = stringValue(val) + return nil +} +func (s *stringValue) Type() string { + return "string" +} + +func (s *stringValue) String() string { return string(*s) } + +func stringConv(sval string) (interface{}, error) { + return sval, nil +} + +// GetString return the string value of a flag with the given name +func (f *FlagSet) GetString(name string) (string, error) { + val, err := f.getFlagType(name, "string", stringConv) + if err != nil { + return "", err + } + return val.(string), nil +} + +// StringVar defines a string flag with specified name, default value, and usage string. +// The argument p points to a string variable in which to store the value of the flag. +func (f *FlagSet) StringVar(p *string, name string, value string, usage string) { + f.VarP(newStringValue(value, p), name, "", usage) +} + +// StringVarP is like StringVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) StringVarP(p *string, name, shorthand string, value string, usage string) { + f.VarP(newStringValue(value, p), name, shorthand, usage) +} + +// StringVar defines a string flag with specified name, default value, and usage string. +// The argument p points to a string variable in which to store the value of the flag. +func StringVar(p *string, name string, value string, usage string) { + CommandLine.VarP(newStringValue(value, p), name, "", usage) +} + +// StringVarP is like StringVar, but accepts a shorthand letter that can be used after a single dash. +func StringVarP(p *string, name, shorthand string, value string, usage string) { + CommandLine.VarP(newStringValue(value, p), name, shorthand, usage) +} + +// String defines a string flag with specified name, default value, and usage string. +// The return value is the address of a string variable that stores the value of the flag. +func (f *FlagSet) String(name string, value string, usage string) *string { + p := new(string) + f.StringVarP(p, name, "", value, usage) + return p +} + +// StringP is like String, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) StringP(name, shorthand string, value string, usage string) *string { + p := new(string) + f.StringVarP(p, name, shorthand, value, usage) + return p +} + +// String defines a string flag with specified name, default value, and usage string. +// The return value is the address of a string variable that stores the value of the flag. +func String(name string, value string, usage string) *string { + return CommandLine.StringP(name, "", value, usage) +} + +// StringP is like String, but accepts a shorthand letter that can be used after a single dash. +func StringP(name, shorthand string, value string, usage string) *string { + return CommandLine.StringP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/string_array.go b/vendor/github.com/spf13/pflag/string_array.go new file mode 100644 index 000000000..fa7bc6018 --- /dev/null +++ b/vendor/github.com/spf13/pflag/string_array.go @@ -0,0 +1,103 @@ +package pflag + +// -- stringArray Value +type stringArrayValue struct { + value *[]string + changed bool +} + +func newStringArrayValue(val []string, p *[]string) *stringArrayValue { + ssv := new(stringArrayValue) + ssv.value = p + *ssv.value = val + return ssv +} + +func (s *stringArrayValue) Set(val string) error { + if !s.changed { + *s.value = []string{val} + s.changed = true + } else { + *s.value = append(*s.value, val) + } + return nil +} + +func (s *stringArrayValue) Type() string { + return "stringArray" +} + +func (s *stringArrayValue) String() string { + str, _ := writeAsCSV(*s.value) + return "[" + str + "]" +} + +func stringArrayConv(sval string) (interface{}, error) { + sval = sval[1 : len(sval)-1] + // An empty string would cause a array with one (empty) string + if len(sval) == 0 { + return []string{}, nil + } + return readAsCSV(sval) +} + +// GetStringArray return the []string value of a flag with the given name +func (f *FlagSet) GetStringArray(name string) ([]string, error) { + val, err := f.getFlagType(name, "stringArray", stringArrayConv) + if err != nil { + return []string{}, err + } + return val.([]string), nil +} + +// StringArrayVar defines a string flag with specified name, default value, and usage string. +// The argument p points to a []string variable in which to store the values of the multiple flags. +// The value of each argument will not try to be separated by comma. Use a StringSlice for that. +func (f *FlagSet) StringArrayVar(p *[]string, name string, value []string, usage string) { + f.VarP(newStringArrayValue(value, p), name, "", usage) +} + +// StringArrayVarP is like StringArrayVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) StringArrayVarP(p *[]string, name, shorthand string, value []string, usage string) { + f.VarP(newStringArrayValue(value, p), name, shorthand, usage) +} + +// StringArrayVar defines a string flag with specified name, default value, and usage string. +// The argument p points to a []string variable in which to store the value of the flag. +// The value of each argument will not try to be separated by comma. Use a StringSlice for that. +func StringArrayVar(p *[]string, name string, value []string, usage string) { + CommandLine.VarP(newStringArrayValue(value, p), name, "", usage) +} + +// StringArrayVarP is like StringArrayVar, but accepts a shorthand letter that can be used after a single dash. +func StringArrayVarP(p *[]string, name, shorthand string, value []string, usage string) { + CommandLine.VarP(newStringArrayValue(value, p), name, shorthand, usage) +} + +// StringArray defines a string flag with specified name, default value, and usage string. +// The return value is the address of a []string variable that stores the value of the flag. +// The value of each argument will not try to be separated by comma. Use a StringSlice for that. +func (f *FlagSet) StringArray(name string, value []string, usage string) *[]string { + p := []string{} + f.StringArrayVarP(&p, name, "", value, usage) + return &p +} + +// StringArrayP is like StringArray, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) StringArrayP(name, shorthand string, value []string, usage string) *[]string { + p := []string{} + f.StringArrayVarP(&p, name, shorthand, value, usage) + return &p +} + +// StringArray defines a string flag with specified name, default value, and usage string. +// The return value is the address of a []string variable that stores the value of the flag. +// The value of each argument will not try to be separated by comma. Use a StringSlice for that. +func StringArray(name string, value []string, usage string) *[]string { + return CommandLine.StringArrayP(name, "", value, usage) +} + +// StringArrayP is like StringArray, but accepts a shorthand letter that can be used after a single dash. +func StringArrayP(name, shorthand string, value []string, usage string) *[]string { + return CommandLine.StringArrayP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/string_slice.go b/vendor/github.com/spf13/pflag/string_slice.go new file mode 100644 index 000000000..0cd3ccc08 --- /dev/null +++ b/vendor/github.com/spf13/pflag/string_slice.go @@ -0,0 +1,149 @@ +package pflag + +import ( + "bytes" + "encoding/csv" + "strings" +) + +// -- stringSlice Value +type stringSliceValue struct { + value *[]string + changed bool +} + +func newStringSliceValue(val []string, p *[]string) *stringSliceValue { + ssv := new(stringSliceValue) + ssv.value = p + *ssv.value = val + return ssv +} + +func readAsCSV(val string) ([]string, error) { + if val == "" { + return []string{}, nil + } + stringReader := strings.NewReader(val) + csvReader := csv.NewReader(stringReader) + return csvReader.Read() +} + +func writeAsCSV(vals []string) (string, error) { + b := &bytes.Buffer{} + w := csv.NewWriter(b) + err := w.Write(vals) + if err != nil { + return "", err + } + w.Flush() + return strings.TrimSuffix(b.String(), "\n"), nil +} + +func (s *stringSliceValue) Set(val string) error { + v, err := readAsCSV(val) + if err != nil { + return err + } + if !s.changed { + *s.value = v + } else { + *s.value = append(*s.value, v...) + } + s.changed = true + return nil +} + +func (s *stringSliceValue) Type() string { + return "stringSlice" +} + +func (s *stringSliceValue) String() string { + str, _ := writeAsCSV(*s.value) + return "[" + str + "]" +} + +func stringSliceConv(sval string) (interface{}, error) { + sval = sval[1 : len(sval)-1] + // An empty string would cause a slice with one (empty) string + if len(sval) == 0 { + return []string{}, nil + } + return readAsCSV(sval) +} + +// GetStringSlice return the []string value of a flag with the given name +func (f *FlagSet) GetStringSlice(name string) ([]string, error) { + val, err := f.getFlagType(name, "stringSlice", stringSliceConv) + if err != nil { + return []string{}, err + } + return val.([]string), nil +} + +// StringSliceVar defines a string flag with specified name, default value, and usage string. +// The argument p points to a []string variable in which to store the value of the flag. +// Compared to StringArray flags, StringSlice flags take comma-separated value as arguments and split them accordingly. +// For example: +// --ss="v1,v2" -ss="v3" +// will result in +// []string{"v1", "v2", "v3"} +func (f *FlagSet) StringSliceVar(p *[]string, name string, value []string, usage string) { + f.VarP(newStringSliceValue(value, p), name, "", usage) +} + +// StringSliceVarP is like StringSliceVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) StringSliceVarP(p *[]string, name, shorthand string, value []string, usage string) { + f.VarP(newStringSliceValue(value, p), name, shorthand, usage) +} + +// StringSliceVar defines a string flag with specified name, default value, and usage string. +// The argument p points to a []string variable in which to store the value of the flag. +// Compared to StringArray flags, StringSlice flags take comma-separated value as arguments and split them accordingly. +// For example: +// --ss="v1,v2" -ss="v3" +// will result in +// []string{"v1", "v2", "v3"} +func StringSliceVar(p *[]string, name string, value []string, usage string) { + CommandLine.VarP(newStringSliceValue(value, p), name, "", usage) +} + +// StringSliceVarP is like StringSliceVar, but accepts a shorthand letter that can be used after a single dash. +func StringSliceVarP(p *[]string, name, shorthand string, value []string, usage string) { + CommandLine.VarP(newStringSliceValue(value, p), name, shorthand, usage) +} + +// StringSlice defines a string flag with specified name, default value, and usage string. +// The return value is the address of a []string variable that stores the value of the flag. +// Compared to StringArray flags, StringSlice flags take comma-separated value as arguments and split them accordingly. +// For example: +// --ss="v1,v2" -ss="v3" +// will result in +// []string{"v1", "v2", "v3"} +func (f *FlagSet) StringSlice(name string, value []string, usage string) *[]string { + p := []string{} + f.StringSliceVarP(&p, name, "", value, usage) + return &p +} + +// StringSliceP is like StringSlice, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) StringSliceP(name, shorthand string, value []string, usage string) *[]string { + p := []string{} + f.StringSliceVarP(&p, name, shorthand, value, usage) + return &p +} + +// StringSlice defines a string flag with specified name, default value, and usage string. +// The return value is the address of a []string variable that stores the value of the flag. +// Compared to StringArray flags, StringSlice flags take comma-separated value as arguments and split them accordingly. +// For example: +// --ss="v1,v2" -ss="v3" +// will result in +// []string{"v1", "v2", "v3"} +func StringSlice(name string, value []string, usage string) *[]string { + return CommandLine.StringSliceP(name, "", value, usage) +} + +// StringSliceP is like StringSlice, but accepts a shorthand letter that can be used after a single dash. +func StringSliceP(name, shorthand string, value []string, usage string) *[]string { + return CommandLine.StringSliceP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/uint.go b/vendor/github.com/spf13/pflag/uint.go new file mode 100644 index 000000000..dcbc2b758 --- /dev/null +++ b/vendor/github.com/spf13/pflag/uint.go @@ -0,0 +1,88 @@ +package pflag + +import "strconv" + +// -- uint Value +type uintValue uint + +func newUintValue(val uint, p *uint) *uintValue { + *p = val + return (*uintValue)(p) +} + +func (i *uintValue) Set(s string) error { + v, err := strconv.ParseUint(s, 0, 64) + *i = uintValue(v) + return err +} + +func (i *uintValue) Type() string { + return "uint" +} + +func (i *uintValue) String() string { return strconv.FormatUint(uint64(*i), 10) } + +func uintConv(sval string) (interface{}, error) { + v, err := strconv.ParseUint(sval, 0, 0) + if err != nil { + return 0, err + } + return uint(v), nil +} + +// GetUint return the uint value of a flag with the given name +func (f *FlagSet) GetUint(name string) (uint, error) { + val, err := f.getFlagType(name, "uint", uintConv) + if err != nil { + return 0, err + } + return val.(uint), nil +} + +// UintVar defines a uint flag with specified name, default value, and usage string. +// The argument p points to a uint variable in which to store the value of the flag. +func (f *FlagSet) UintVar(p *uint, name string, value uint, usage string) { + f.VarP(newUintValue(value, p), name, "", usage) +} + +// UintVarP is like UintVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) UintVarP(p *uint, name, shorthand string, value uint, usage string) { + f.VarP(newUintValue(value, p), name, shorthand, usage) +} + +// UintVar defines a uint flag with specified name, default value, and usage string. +// The argument p points to a uint variable in which to store the value of the flag. +func UintVar(p *uint, name string, value uint, usage string) { + CommandLine.VarP(newUintValue(value, p), name, "", usage) +} + +// UintVarP is like UintVar, but accepts a shorthand letter that can be used after a single dash. +func UintVarP(p *uint, name, shorthand string, value uint, usage string) { + CommandLine.VarP(newUintValue(value, p), name, shorthand, usage) +} + +// Uint defines a uint flag with specified name, default value, and usage string. +// The return value is the address of a uint variable that stores the value of the flag. +func (f *FlagSet) Uint(name string, value uint, usage string) *uint { + p := new(uint) + f.UintVarP(p, name, "", value, usage) + return p +} + +// UintP is like Uint, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) UintP(name, shorthand string, value uint, usage string) *uint { + p := new(uint) + f.UintVarP(p, name, shorthand, value, usage) + return p +} + +// Uint defines a uint flag with specified name, default value, and usage string. +// The return value is the address of a uint variable that stores the value of the flag. +func Uint(name string, value uint, usage string) *uint { + return CommandLine.UintP(name, "", value, usage) +} + +// UintP is like Uint, but accepts a shorthand letter that can be used after a single dash. +func UintP(name, shorthand string, value uint, usage string) *uint { + return CommandLine.UintP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/uint16.go b/vendor/github.com/spf13/pflag/uint16.go new file mode 100644 index 000000000..7e9914edd --- /dev/null +++ b/vendor/github.com/spf13/pflag/uint16.go @@ -0,0 +1,88 @@ +package pflag + +import "strconv" + +// -- uint16 value +type uint16Value uint16 + +func newUint16Value(val uint16, p *uint16) *uint16Value { + *p = val + return (*uint16Value)(p) +} + +func (i *uint16Value) Set(s string) error { + v, err := strconv.ParseUint(s, 0, 16) + *i = uint16Value(v) + return err +} + +func (i *uint16Value) Type() string { + return "uint16" +} + +func (i *uint16Value) String() string { return strconv.FormatUint(uint64(*i), 10) } + +func uint16Conv(sval string) (interface{}, error) { + v, err := strconv.ParseUint(sval, 0, 16) + if err != nil { + return 0, err + } + return uint16(v), nil +} + +// GetUint16 return the uint16 value of a flag with the given name +func (f *FlagSet) GetUint16(name string) (uint16, error) { + val, err := f.getFlagType(name, "uint16", uint16Conv) + if err != nil { + return 0, err + } + return val.(uint16), nil +} + +// Uint16Var defines a uint flag with specified name, default value, and usage string. +// The argument p points to a uint variable in which to store the value of the flag. +func (f *FlagSet) Uint16Var(p *uint16, name string, value uint16, usage string) { + f.VarP(newUint16Value(value, p), name, "", usage) +} + +// Uint16VarP is like Uint16Var, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Uint16VarP(p *uint16, name, shorthand string, value uint16, usage string) { + f.VarP(newUint16Value(value, p), name, shorthand, usage) +} + +// Uint16Var defines a uint flag with specified name, default value, and usage string. +// The argument p points to a uint variable in which to store the value of the flag. +func Uint16Var(p *uint16, name string, value uint16, usage string) { + CommandLine.VarP(newUint16Value(value, p), name, "", usage) +} + +// Uint16VarP is like Uint16Var, but accepts a shorthand letter that can be used after a single dash. +func Uint16VarP(p *uint16, name, shorthand string, value uint16, usage string) { + CommandLine.VarP(newUint16Value(value, p), name, shorthand, usage) +} + +// Uint16 defines a uint flag with specified name, default value, and usage string. +// The return value is the address of a uint variable that stores the value of the flag. +func (f *FlagSet) Uint16(name string, value uint16, usage string) *uint16 { + p := new(uint16) + f.Uint16VarP(p, name, "", value, usage) + return p +} + +// Uint16P is like Uint16, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Uint16P(name, shorthand string, value uint16, usage string) *uint16 { + p := new(uint16) + f.Uint16VarP(p, name, shorthand, value, usage) + return p +} + +// Uint16 defines a uint flag with specified name, default value, and usage string. +// The return value is the address of a uint variable that stores the value of the flag. +func Uint16(name string, value uint16, usage string) *uint16 { + return CommandLine.Uint16P(name, "", value, usage) +} + +// Uint16P is like Uint16, but accepts a shorthand letter that can be used after a single dash. +func Uint16P(name, shorthand string, value uint16, usage string) *uint16 { + return CommandLine.Uint16P(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/uint32.go b/vendor/github.com/spf13/pflag/uint32.go new file mode 100644 index 000000000..d8024539b --- /dev/null +++ b/vendor/github.com/spf13/pflag/uint32.go @@ -0,0 +1,88 @@ +package pflag + +import "strconv" + +// -- uint32 value +type uint32Value uint32 + +func newUint32Value(val uint32, p *uint32) *uint32Value { + *p = val + return (*uint32Value)(p) +} + +func (i *uint32Value) Set(s string) error { + v, err := strconv.ParseUint(s, 0, 32) + *i = uint32Value(v) + return err +} + +func (i *uint32Value) Type() string { + return "uint32" +} + +func (i *uint32Value) String() string { return strconv.FormatUint(uint64(*i), 10) } + +func uint32Conv(sval string) (interface{}, error) { + v, err := strconv.ParseUint(sval, 0, 32) + if err != nil { + return 0, err + } + return uint32(v), nil +} + +// GetUint32 return the uint32 value of a flag with the given name +func (f *FlagSet) GetUint32(name string) (uint32, error) { + val, err := f.getFlagType(name, "uint32", uint32Conv) + if err != nil { + return 0, err + } + return val.(uint32), nil +} + +// Uint32Var defines a uint32 flag with specified name, default value, and usage string. +// The argument p points to a uint32 variable in which to store the value of the flag. +func (f *FlagSet) Uint32Var(p *uint32, name string, value uint32, usage string) { + f.VarP(newUint32Value(value, p), name, "", usage) +} + +// Uint32VarP is like Uint32Var, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Uint32VarP(p *uint32, name, shorthand string, value uint32, usage string) { + f.VarP(newUint32Value(value, p), name, shorthand, usage) +} + +// Uint32Var defines a uint32 flag with specified name, default value, and usage string. +// The argument p points to a uint32 variable in which to store the value of the flag. +func Uint32Var(p *uint32, name string, value uint32, usage string) { + CommandLine.VarP(newUint32Value(value, p), name, "", usage) +} + +// Uint32VarP is like Uint32Var, but accepts a shorthand letter that can be used after a single dash. +func Uint32VarP(p *uint32, name, shorthand string, value uint32, usage string) { + CommandLine.VarP(newUint32Value(value, p), name, shorthand, usage) +} + +// Uint32 defines a uint32 flag with specified name, default value, and usage string. +// The return value is the address of a uint32 variable that stores the value of the flag. +func (f *FlagSet) Uint32(name string, value uint32, usage string) *uint32 { + p := new(uint32) + f.Uint32VarP(p, name, "", value, usage) + return p +} + +// Uint32P is like Uint32, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Uint32P(name, shorthand string, value uint32, usage string) *uint32 { + p := new(uint32) + f.Uint32VarP(p, name, shorthand, value, usage) + return p +} + +// Uint32 defines a uint32 flag with specified name, default value, and usage string. +// The return value is the address of a uint32 variable that stores the value of the flag. +func Uint32(name string, value uint32, usage string) *uint32 { + return CommandLine.Uint32P(name, "", value, usage) +} + +// Uint32P is like Uint32, but accepts a shorthand letter that can be used after a single dash. +func Uint32P(name, shorthand string, value uint32, usage string) *uint32 { + return CommandLine.Uint32P(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/uint64.go b/vendor/github.com/spf13/pflag/uint64.go new file mode 100644 index 000000000..f62240f2c --- /dev/null +++ b/vendor/github.com/spf13/pflag/uint64.go @@ -0,0 +1,88 @@ +package pflag + +import "strconv" + +// -- uint64 Value +type uint64Value uint64 + +func newUint64Value(val uint64, p *uint64) *uint64Value { + *p = val + return (*uint64Value)(p) +} + +func (i *uint64Value) Set(s string) error { + v, err := strconv.ParseUint(s, 0, 64) + *i = uint64Value(v) + return err +} + +func (i *uint64Value) Type() string { + return "uint64" +} + +func (i *uint64Value) String() string { return strconv.FormatUint(uint64(*i), 10) } + +func uint64Conv(sval string) (interface{}, error) { + v, err := strconv.ParseUint(sval, 0, 64) + if err != nil { + return 0, err + } + return uint64(v), nil +} + +// GetUint64 return the uint64 value of a flag with the given name +func (f *FlagSet) GetUint64(name string) (uint64, error) { + val, err := f.getFlagType(name, "uint64", uint64Conv) + if err != nil { + return 0, err + } + return val.(uint64), nil +} + +// Uint64Var defines a uint64 flag with specified name, default value, and usage string. +// The argument p points to a uint64 variable in which to store the value of the flag. +func (f *FlagSet) Uint64Var(p *uint64, name string, value uint64, usage string) { + f.VarP(newUint64Value(value, p), name, "", usage) +} + +// Uint64VarP is like Uint64Var, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Uint64VarP(p *uint64, name, shorthand string, value uint64, usage string) { + f.VarP(newUint64Value(value, p), name, shorthand, usage) +} + +// Uint64Var defines a uint64 flag with specified name, default value, and usage string. +// The argument p points to a uint64 variable in which to store the value of the flag. +func Uint64Var(p *uint64, name string, value uint64, usage string) { + CommandLine.VarP(newUint64Value(value, p), name, "", usage) +} + +// Uint64VarP is like Uint64Var, but accepts a shorthand letter that can be used after a single dash. +func Uint64VarP(p *uint64, name, shorthand string, value uint64, usage string) { + CommandLine.VarP(newUint64Value(value, p), name, shorthand, usage) +} + +// Uint64 defines a uint64 flag with specified name, default value, and usage string. +// The return value is the address of a uint64 variable that stores the value of the flag. +func (f *FlagSet) Uint64(name string, value uint64, usage string) *uint64 { + p := new(uint64) + f.Uint64VarP(p, name, "", value, usage) + return p +} + +// Uint64P is like Uint64, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Uint64P(name, shorthand string, value uint64, usage string) *uint64 { + p := new(uint64) + f.Uint64VarP(p, name, shorthand, value, usage) + return p +} + +// Uint64 defines a uint64 flag with specified name, default value, and usage string. +// The return value is the address of a uint64 variable that stores the value of the flag. +func Uint64(name string, value uint64, usage string) *uint64 { + return CommandLine.Uint64P(name, "", value, usage) +} + +// Uint64P is like Uint64, but accepts a shorthand letter that can be used after a single dash. +func Uint64P(name, shorthand string, value uint64, usage string) *uint64 { + return CommandLine.Uint64P(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/uint8.go b/vendor/github.com/spf13/pflag/uint8.go new file mode 100644 index 000000000..bb0e83c1f --- /dev/null +++ b/vendor/github.com/spf13/pflag/uint8.go @@ -0,0 +1,88 @@ +package pflag + +import "strconv" + +// -- uint8 Value +type uint8Value uint8 + +func newUint8Value(val uint8, p *uint8) *uint8Value { + *p = val + return (*uint8Value)(p) +} + +func (i *uint8Value) Set(s string) error { + v, err := strconv.ParseUint(s, 0, 8) + *i = uint8Value(v) + return err +} + +func (i *uint8Value) Type() string { + return "uint8" +} + +func (i *uint8Value) String() string { return strconv.FormatUint(uint64(*i), 10) } + +func uint8Conv(sval string) (interface{}, error) { + v, err := strconv.ParseUint(sval, 0, 8) + if err != nil { + return 0, err + } + return uint8(v), nil +} + +// GetUint8 return the uint8 value of a flag with the given name +func (f *FlagSet) GetUint8(name string) (uint8, error) { + val, err := f.getFlagType(name, "uint8", uint8Conv) + if err != nil { + return 0, err + } + return val.(uint8), nil +} + +// Uint8Var defines a uint8 flag with specified name, default value, and usage string. +// The argument p points to a uint8 variable in which to store the value of the flag. +func (f *FlagSet) Uint8Var(p *uint8, name string, value uint8, usage string) { + f.VarP(newUint8Value(value, p), name, "", usage) +} + +// Uint8VarP is like Uint8Var, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Uint8VarP(p *uint8, name, shorthand string, value uint8, usage string) { + f.VarP(newUint8Value(value, p), name, shorthand, usage) +} + +// Uint8Var defines a uint8 flag with specified name, default value, and usage string. +// The argument p points to a uint8 variable in which to store the value of the flag. +func Uint8Var(p *uint8, name string, value uint8, usage string) { + CommandLine.VarP(newUint8Value(value, p), name, "", usage) +} + +// Uint8VarP is like Uint8Var, but accepts a shorthand letter that can be used after a single dash. +func Uint8VarP(p *uint8, name, shorthand string, value uint8, usage string) { + CommandLine.VarP(newUint8Value(value, p), name, shorthand, usage) +} + +// Uint8 defines a uint8 flag with specified name, default value, and usage string. +// The return value is the address of a uint8 variable that stores the value of the flag. +func (f *FlagSet) Uint8(name string, value uint8, usage string) *uint8 { + p := new(uint8) + f.Uint8VarP(p, name, "", value, usage) + return p +} + +// Uint8P is like Uint8, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) Uint8P(name, shorthand string, value uint8, usage string) *uint8 { + p := new(uint8) + f.Uint8VarP(p, name, shorthand, value, usage) + return p +} + +// Uint8 defines a uint8 flag with specified name, default value, and usage string. +// The return value is the address of a uint8 variable that stores the value of the flag. +func Uint8(name string, value uint8, usage string) *uint8 { + return CommandLine.Uint8P(name, "", value, usage) +} + +// Uint8P is like Uint8, but accepts a shorthand letter that can be used after a single dash. +func Uint8P(name, shorthand string, value uint8, usage string) *uint8 { + return CommandLine.Uint8P(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/uint_slice.go b/vendor/github.com/spf13/pflag/uint_slice.go new file mode 100644 index 000000000..edd94c600 --- /dev/null +++ b/vendor/github.com/spf13/pflag/uint_slice.go @@ -0,0 +1,126 @@ +package pflag + +import ( + "fmt" + "strconv" + "strings" +) + +// -- uintSlice Value +type uintSliceValue struct { + value *[]uint + changed bool +} + +func newUintSliceValue(val []uint, p *[]uint) *uintSliceValue { + uisv := new(uintSliceValue) + uisv.value = p + *uisv.value = val + return uisv +} + +func (s *uintSliceValue) Set(val string) error { + ss := strings.Split(val, ",") + out := make([]uint, len(ss)) + for i, d := range ss { + u, err := strconv.ParseUint(d, 10, 0) + if err != nil { + return err + } + out[i] = uint(u) + } + if !s.changed { + *s.value = out + } else { + *s.value = append(*s.value, out...) + } + s.changed = true + return nil +} + +func (s *uintSliceValue) Type() string { + return "uintSlice" +} + +func (s *uintSliceValue) String() string { + out := make([]string, len(*s.value)) + for i, d := range *s.value { + out[i] = fmt.Sprintf("%d", d) + } + return "[" + strings.Join(out, ",") + "]" +} + +func uintSliceConv(val string) (interface{}, error) { + val = strings.Trim(val, "[]") + // Empty string would cause a slice with one (empty) entry + if len(val) == 0 { + return []uint{}, nil + } + ss := strings.Split(val, ",") + out := make([]uint, len(ss)) + for i, d := range ss { + u, err := strconv.ParseUint(d, 10, 0) + if err != nil { + return nil, err + } + out[i] = uint(u) + } + return out, nil +} + +// GetUintSlice returns the []uint value of a flag with the given name. +func (f *FlagSet) GetUintSlice(name string) ([]uint, error) { + val, err := f.getFlagType(name, "uintSlice", uintSliceConv) + if err != nil { + return []uint{}, err + } + return val.([]uint), nil +} + +// UintSliceVar defines a uintSlice flag with specified name, default value, and usage string. +// The argument p points to a []uint variable in which to store the value of the flag. +func (f *FlagSet) UintSliceVar(p *[]uint, name string, value []uint, usage string) { + f.VarP(newUintSliceValue(value, p), name, "", usage) +} + +// UintSliceVarP is like UintSliceVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) UintSliceVarP(p *[]uint, name, shorthand string, value []uint, usage string) { + f.VarP(newUintSliceValue(value, p), name, shorthand, usage) +} + +// UintSliceVar defines a uint[] flag with specified name, default value, and usage string. +// The argument p points to a uint[] variable in which to store the value of the flag. +func UintSliceVar(p *[]uint, name string, value []uint, usage string) { + CommandLine.VarP(newUintSliceValue(value, p), name, "", usage) +} + +// UintSliceVarP is like the UintSliceVar, but accepts a shorthand letter that can be used after a single dash. +func UintSliceVarP(p *[]uint, name, shorthand string, value []uint, usage string) { + CommandLine.VarP(newUintSliceValue(value, p), name, shorthand, usage) +} + +// UintSlice defines a []uint flag with specified name, default value, and usage string. +// The return value is the address of a []uint variable that stores the value of the flag. +func (f *FlagSet) UintSlice(name string, value []uint, usage string) *[]uint { + p := []uint{} + f.UintSliceVarP(&p, name, "", value, usage) + return &p +} + +// UintSliceP is like UintSlice, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) UintSliceP(name, shorthand string, value []uint, usage string) *[]uint { + p := []uint{} + f.UintSliceVarP(&p, name, shorthand, value, usage) + return &p +} + +// UintSlice defines a []uint flag with specified name, default value, and usage string. +// The return value is the address of a []uint variable that stores the value of the flag. +func UintSlice(name string, value []uint, usage string) *[]uint { + return CommandLine.UintSliceP(name, "", value, usage) +} + +// UintSliceP is like UintSlice, but accepts a shorthand letter that can be used after a single dash. +func UintSliceP(name, shorthand string, value []uint, usage string) *[]uint { + return CommandLine.UintSliceP(name, shorthand, value, usage) +} diff --git a/vendor/modules.txt b/vendor/modules.txt index 3d9b3cecb..4b26fbc0d 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -214,6 +214,8 @@ github.com/gophercloud/gophercloud/openstack/utils github.com/gophercloud/gophercloud/pagination # github.com/gorilla/css v1.0.0 github.com/gorilla/css/scanner +# github.com/inconshreveable/mousetrap v1.0.0 +github.com/inconshreveable/mousetrap # github.com/jackc/chunkreader/v2 v2.0.1 github.com/jackc/chunkreader/v2 # github.com/jackc/pgconn v1.10.0 @@ -291,6 +293,15 @@ github.com/openshift-online/ocm-sdk-go/errors github.com/openshift-online/ocm-sdk-go/helpers github.com/openshift-online/ocm-sdk-go/internal github.com/openshift-online/ocm-sdk-go/logging +# github.com/oracle/oci-go-sdk/v54 v54.0.0 +## explicit +github.com/oracle/oci-go-sdk/v54/common +github.com/oracle/oci-go-sdk/v54/common/auth +github.com/oracle/oci-go-sdk/v54/core +github.com/oracle/oci-go-sdk/v54/identity +github.com/oracle/oci-go-sdk/v54/objectstorage +github.com/oracle/oci-go-sdk/v54/objectstorage/transfer +github.com/oracle/oci-go-sdk/v54/workrequests # github.com/pkg/errors v0.9.1 github.com/pkg/errors # github.com/pmezard/go-difflib v1.0.0 @@ -319,6 +330,13 @@ github.com/segmentio/ksuid # github.com/sirupsen/logrus v1.8.1 ## explicit github.com/sirupsen/logrus +# github.com/sony/gobreaker v0.4.2-0.20210216022020-dd874f9dd33b +github.com/sony/gobreaker +# github.com/spf13/cobra v0.0.3 +## explicit +github.com/spf13/cobra +# github.com/spf13/pflag v1.0.1 +github.com/spf13/pflag # github.com/stretchr/testify v1.7.0 ## explicit github.com/stretchr/testify/assert